From 96779c7d44c325f7580899a5a6d3ae42fcbc592d Mon Sep 17 00:00:00 2001 From: shiziyuan9527 Date: Fri, 17 Mar 2023 18:23:07 +0800 Subject: [PATCH] =?UTF-8?q?fix(=E6=B5=8B=E8=AF=95=E8=B7=9F=E8=B8=AA):=20?= =?UTF-8?q?=E5=A4=8D=E5=88=B6=E6=B5=8B=E8=AF=95=E8=AE=A1=E5=88=92=E6=80=A7?= =?UTF-8?q?=E8=83=BD=E7=94=A8=E4=BE=8B=E4=BF=AE=E6=94=B9=E9=85=8D=E7=BD=AE?= =?UTF-8?q?=E8=B5=84=E6=BA=90=E6=B1=A0=E6=B2=A1=E6=98=BE=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --bug=1024599 --user=李玉号 【测试跟踪】复制测试计划-性能用例-点击修改配置-资源池没显示 https://www.tapd.cn/55049933/s/1352457 --- .../metersphere/plan/service/TestPlanLoadCaseService.java | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/performance-test/backend/src/main/java/io/metersphere/plan/service/TestPlanLoadCaseService.java b/performance-test/backend/src/main/java/io/metersphere/plan/service/TestPlanLoadCaseService.java index 1c82a5d2eb..f9d9fc6a3b 100644 --- a/performance-test/backend/src/main/java/io/metersphere/plan/service/TestPlanLoadCaseService.java +++ b/performance-test/backend/src/main/java/io/metersphere/plan/service/TestPlanLoadCaseService.java @@ -479,11 +479,11 @@ public class TestPlanLoadCaseService { try (SqlSession sqlSession = sqlSessionFactory.openSession(ExecutorType.BATCH)) { TestPlanLoadCaseExample example = new TestPlanLoadCaseExample(); example.createCriteria().andTestPlanIdEqualTo(sourcePlanId); - List loadCases = testPlanLoadCaseMapper.selectByExample(example); + List loadCases = testPlanLoadCaseMapper.selectByExampleWithBLOBs(example); TestPlanLoadCaseMapper mapper = sqlSession.getMapper(TestPlanLoadCaseMapper.class); if (!org.apache.commons.collections.CollectionUtils.isEmpty(loadCases)) { Long nextLoadOrder = ServiceUtils.getNextOrder(targetPlanId, extTestPlanLoadCaseMapper::getLastOrder); - for (TestPlanLoadCase loadCase : loadCases) { + for (TestPlanLoadCaseWithBLOBs loadCase : loadCases) { TestPlanLoadCaseWithBLOBs load = new TestPlanLoadCaseWithBLOBs(); load.setId(UUID.randomUUID().toString()); load.setTestPlanId(targetPlanId); @@ -492,6 +492,9 @@ public class TestPlanLoadCaseService { load.setUpdateTime(System.currentTimeMillis()); load.setCreateUser(SessionUtils.getUserId()); load.setOrder(nextLoadOrder); + load.setTestResourcePoolId(loadCase.getTestResourcePoolId()); + load.setLoadConfiguration(loadCase.getLoadConfiguration()); + load.setAdvancedConfiguration(loadCase.getAdvancedConfiguration()); mapper.insert(load); nextLoadOrder += 5000; }