From b2eb55d03f7ab117614d7c2197b579fddafb9b87 Mon Sep 17 00:00:00 2001 From: shiziyuan9527 Date: Mon, 22 Mar 2021 20:36:47 +0800 Subject: [PATCH 01/35] =?UTF-8?q?fix(=E7=B3=BB=E7=BB=9F=E8=AE=BE=E7=BD=AE)?= =?UTF-8?q?:=20=E4=BF=AE=E5=A4=8D=E6=B5=8B=E8=AF=95=E8=B5=84=E6=BA=90?= =?UTF-8?q?=E6=B1=A0=E9=87=8D=E5=90=8D=E6=A3=80=E6=9F=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../java/io/metersphere/service/TestResourcePoolService.java | 1 + 1 file changed, 1 insertion(+) diff --git a/backend/src/main/java/io/metersphere/service/TestResourcePoolService.java b/backend/src/main/java/io/metersphere/service/TestResourcePoolService.java index bca5686ebd..aabc1146c7 100644 --- a/backend/src/main/java/io/metersphere/service/TestResourcePoolService.java +++ b/backend/src/main/java/io/metersphere/service/TestResourcePoolService.java @@ -74,6 +74,7 @@ public class TestResourcePoolService { if (StringUtils.isNotBlank(testResourcePoolDTO.getId())) { criteria.andIdNotEqualTo(testResourcePoolDTO.getId()); } + criteria.andStatusNotEqualTo(DELETE.name()); if (testResourcePoolMapper.countByExample(example) > 0) { MSException.throwException(Translator.get("test_resource_pool_name_already_exists")); From 2fb76d69e8294ea6d5f911bd8d6e25f1709d785b Mon Sep 17 00:00:00 2001 From: shiziyuan9527 Date: Mon, 22 Mar 2021 21:14:56 +0800 Subject: [PATCH 02/35] =?UTF-8?q?fix:=20=E4=BF=AE=E5=A4=8D=E8=A1=A8?= =?UTF-8?q?=E6=A0=BC=E6=A0=B7=E5=BC=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- frontend/src/common/css/main.css | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/frontend/src/common/css/main.css b/frontend/src/common/css/main.css index 54f0383933..0bda463e1a 100644 --- a/frontend/src/common/css/main.css +++ b/frontend/src/common/css/main.css @@ -65,7 +65,7 @@ html,body { border-right: 0 !important; } -.adjust-table th { +.adjust-table th:not([class*="el-table-column--selection"]) { border-right-color: white !important; } From 6fe910114458bbb598ac26d63308a89041aa2d5b Mon Sep 17 00:00:00 2001 From: shiziyuan9527 Date: Mon, 22 Mar 2021 21:24:50 +0800 Subject: [PATCH 03/35] =?UTF-8?q?fix(=E6=B5=8B=E8=AF=95=E8=AE=A1=E5=88=92)?= =?UTF-8?q?:=20=E5=8E=BB=E9=99=A4=E6=89=A7=E8=A1=8C=E9=A1=B5=E9=9D=A2?= =?UTF-8?q?=E6=97=A0=E7=94=A8=E7=9A=84=E5=AD=97=E6=AE=B5=E5=B1=95=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../functional/FunctionalTestCaseEdit.vue | 15 ++------------- 1 file changed, 2 insertions(+), 13 deletions(-) diff --git a/frontend/src/business/components/track/plan/view/comonents/functional/FunctionalTestCaseEdit.vue b/frontend/src/business/components/track/plan/view/comonents/functional/FunctionalTestCaseEdit.vue index 8ee1ab81ad..da8facdcb8 100644 --- a/frontend/src/business/components/track/plan/view/comonents/functional/FunctionalTestCaseEdit.vue +++ b/frontend/src/business/components/track/plan/view/comonents/functional/FunctionalTestCaseEdit.vue @@ -48,10 +48,8 @@ {{ testCase.priority }} - {{ $t('test_track.case.case_type') }}: - {{ $t('commons.functional') }} - {{ $t('commons.performance') }} - {{ $t('commons.api') }} + {{ $t('test_track.case.module') }}: + {{ testCase.nodePath }} - - {{ $t('test_track.case.method') }}: - {{ $t('test_track.case.manual') }} - {{ $t('test_track.case.auto') }} - - - {{ $t('test_track.case.module') }}: - {{ testCase.nodePath }} - {{ $t('test_track.plan.plan_project') }}: {{ testCase.projectName }} From b3c6e17cf7e34fe74f73fb5b47763f8ee4a9faa7 Mon Sep 17 00:00:00 2001 From: chenjianxing Date: Mon, 22 Mar 2021 21:57:12 +0800 Subject: [PATCH 04/35] =?UTF-8?q?fix:=20=E8=84=91=E5=9B=BEbug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../testcase/TestCaseMinderEditRequest.java | 1 + .../track/service/TestCaseService.java | 6 ++++++ frontend/package.json | 2 +- .../track/common/minder/TestCaseMinder.vue | 17 ++++++++++------- 4 files changed, 18 insertions(+), 8 deletions(-) diff --git a/backend/src/main/java/io/metersphere/track/request/testcase/TestCaseMinderEditRequest.java b/backend/src/main/java/io/metersphere/track/request/testcase/TestCaseMinderEditRequest.java index d3b43a66ae..ad6cd78cc7 100644 --- a/backend/src/main/java/io/metersphere/track/request/testcase/TestCaseMinderEditRequest.java +++ b/backend/src/main/java/io/metersphere/track/request/testcase/TestCaseMinderEditRequest.java @@ -10,5 +10,6 @@ import java.util.List; @Setter public class TestCaseMinderEditRequest { private String projectId; + private List ids; List data; } diff --git a/backend/src/main/java/io/metersphere/track/service/TestCaseService.java b/backend/src/main/java/io/metersphere/track/service/TestCaseService.java index 937bb20ae0..4956b8c653 100644 --- a/backend/src/main/java/io/metersphere/track/service/TestCaseService.java +++ b/backend/src/main/java/io/metersphere/track/service/TestCaseService.java @@ -780,6 +780,12 @@ public class TestCaseService { editTestCase(item); } }); + List ids = request.getIds(); + if (CollectionUtils.isNotEmpty(ids)) { + TestCaseBatchRequest deleteRequest = new TestCaseBatchRequest(); + deleteRequest.setIds(ids); + deleteTestCaseBath(deleteRequest); + } } public List getTestCaseByProjectId(String projectId) { diff --git a/frontend/package.json b/frontend/package.json index 6dc8af31e0..c688f436de 100644 --- a/frontend/package.json +++ b/frontend/package.json @@ -49,7 +49,7 @@ "xml-js": "^1.6.11", "yan-progress": "^1.0.3", "jsonpath": "^1.1.0", - "vue-minder-editor-plus": "^1.0.18", + "vue-minder-editor-plus": "^1.0.19", "jsencrypt": "^3.1.0" }, "devDependencies": { diff --git a/frontend/src/business/components/track/common/minder/TestCaseMinder.vue b/frontend/src/business/components/track/common/minder/TestCaseMinder.vue index e9c189a7fa..c6121feaf7 100644 --- a/frontend/src/business/components/track/common/minder/TestCaseMinder.vue +++ b/frontend/src/business/components/track/common/minder/TestCaseMinder.vue @@ -49,26 +49,29 @@ name: "TestCaseMinder", }, save(data) { let saveCases = []; - this.buildSaveCase(data.root, saveCases, undefined); + let deleteCases = []; + this.buildSaveCase(data.root, saveCases, deleteCases, undefined); let param = { projectId: this.projectId, - data: saveCases + data: saveCases, + ids: deleteCases.map(item => item.id) } this.result = this.$post('/test/case/minder/edit', param, () => { this.$success(this.$t('commons.save_success')); }); }, - buildSaveCase(root, saveCases, parent) { + buildSaveCase(root, saveCases, deleteCases, parent) { let data = root.data; if (data.resource && data.resource.indexOf(this.$t('api_test.definition.request.case')) > -1) { - if (root.parent) { - console.log(root.parent); - } this._buildSaveCase(root, saveCases, parent); } else { + let deleteChild = data.deleteChild; + if (deleteChild && deleteChild.length > 0) { + deleteCases.push(...deleteChild); + } if (root.children) { root.children.forEach((childNode) => { - this.buildSaveCase(childNode, saveCases, root.data); + this.buildSaveCase(childNode, saveCases, deleteCases, root.data); }) } } From 9b87e41ec62b400e846ae38225073dff55bd896b Mon Sep 17 00:00:00 2001 From: Ambitiousliga <73278880+Ambitiousliga@users.noreply.github.com> Date: Mon, 22 Mar 2021 21:59:05 +0800 Subject: [PATCH 05/35] =?UTF-8?q?fix(=E6=B5=8B=E8=AF=95=E8=B7=9F=E8=B8=AA)?= =?UTF-8?q?:=E5=85=B3=E8=81=94=E7=94=A8=E4=BE=8B=E5=90=8E=E5=A2=9E?= =?UTF-8?q?=E5=8A=A0=E2=80=9C=E8=B4=A3=E4=BB=BB=E4=BA=BA=E2=80=9D=E5=AD=97?= =?UTF-8?q?=E6=AE=B5=EF=BC=8C=E4=BE=BF=E4=BA=8E=E8=AF=86=E5=88=AB=E7=94=A8?= =?UTF-8?q?=E4=BE=8B=E5=8E=9F=E6=9C=AC=E7=9A=84=E8=B4=A3=E4=BB=BB=E4=BA=BA?= =?UTF-8?q?=E3=80=82=20(#1684)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: 黎龙鑫 --- .../base/mapper/ext/ExtTestPlanTestCaseMapper.xml | 8 +++++++- .../business/components/common/model/JsonData.js | 1 + .../track/case/components/TestCaseEdit.vue | 1 - .../functional/FunctionalTestCaseList.vue | 14 ++++++++++++++ 4 files changed, 22 insertions(+), 2 deletions(-) diff --git a/backend/src/main/java/io/metersphere/base/mapper/ext/ExtTestPlanTestCaseMapper.xml b/backend/src/main/java/io/metersphere/base/mapper/ext/ExtTestPlanTestCaseMapper.xml index 4d85aac3e1..454782792f 100644 --- a/backend/src/main/java/io/metersphere/base/mapper/ext/ExtTestPlanTestCaseMapper.xml +++ b/backend/src/main/java/io/metersphere/base/mapper/ext/ExtTestPlanTestCaseMapper.xml @@ -137,7 +137,7 @@