From b16c287633764ba8b4b6d3de34d49d4f51a3e156 Mon Sep 17 00:00:00 2001 From: fit2-zhao Date: Fri, 6 May 2022 16:26:56 +0800 Subject: [PATCH] =?UTF-8?q?refactor(=E6=8E=A5=E5=8F=A3=E6=B5=8B=E8=AF=95):?= =?UTF-8?q?=20=E4=BC=98=E5=8C=96=E5=A4=9A=E6=95=B0=E6=8D=AE=E6=BA=90?= =?UTF-8?q?=E5=88=87=E6=8D=A2=EF=BC=8C=E5=BD=93=E5=A4=9A=E6=AC=A1=E5=88=87?= =?UTF-8?q?=E6=8D=A2=E5=90=8E=E5=86=8D=E5=88=87=E5=9B=9E=E5=8E=9F=E7=8E=AF?= =?UTF-8?q?=E5=A2=83=E5=88=99=E6=98=BE=E7=A4=BA=E5=8E=9F=E5=A7=8B=E6=95=B0?= =?UTF-8?q?=E6=8D=AE=E6=BA=90?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../automation/scenario/EditApiScenario.vue | 5 + .../scenario/common/JDBCProcessorContent.vue | 3 + .../api/definition/components/ApiConfig.vue | 628 +++++++++--------- .../components/case/ApiCaseItem.vue | 19 + .../components/case/ApiCaseList.vue | 19 +- .../request/database/BasisParameters.vue | 4 + .../definition/components/step/JmxStep.vue | 2 + 7 files changed, 374 insertions(+), 306 deletions(-) diff --git a/frontend/src/business/components/api/automation/scenario/EditApiScenario.vue b/frontend/src/business/components/api/automation/scenario/EditApiScenario.vue index 93e68859a7..271de706d7 100644 --- a/frontend/src/business/components/api/automation/scenario/EditApiScenario.vue +++ b/frontend/src/business/components/api/automation/scenario/EditApiScenario.vue @@ -1667,6 +1667,11 @@ export default { dataProcessing(stepArray) { if (stepArray) { for (let i in stepArray) { + let typeArray = ["JDBCPostProcessor", "JDBCSampler", "JDBCPreProcessor"] + if (typeArray.indexOf(stepArray[i].type) !== -1) { + stepArray[i].originalDataSourceId = stepArray[i].dataSourceId; + stepArray[i].originalEnvironmentId = stepArray[i].environmentId; + } if (!stepArray[i].hashTree) { stepArray[i].hashTree = []; } diff --git a/frontend/src/business/components/api/automation/scenario/common/JDBCProcessorContent.vue b/frontend/src/business/components/api/automation/scenario/common/JDBCProcessorContent.vue index 498365587d..5f1e7b3d96 100644 --- a/frontend/src/business/components/api/automation/scenario/common/JDBCProcessorContent.vue +++ b/frontend/src/business/components/api/automation/scenario/common/JDBCProcessorContent.vue @@ -226,6 +226,9 @@ export default { envId = this.request.refEevMap.get(id); } } + if(envId === this.request.originalEnvironmentId && this.request.originalDataSourceId) { + this.request.dataSourceId = this.request.originalDataSourceId; + } let targetDataSourceName = ""; let currentEnvironment = {}; this.result = this.$get('/api/environment/list/' + id, response => { diff --git a/frontend/src/business/components/api/definition/components/ApiConfig.vue b/frontend/src/business/components/api/definition/components/ApiConfig.vue index 2c5d77a2a2..2977b65330 100644 --- a/frontend/src/business/components/api/definition/components/ApiConfig.vue +++ b/frontend/src/business/components/api/definition/components/ApiConfig.vue @@ -32,333 +32,353 @@