From e2eed011f756eff3726fa4bb4c67685d74d07226 Mon Sep 17 00:00:00 2001 From: fit2-zhao Date: Wed, 20 Jan 2021 15:11:41 +0800 Subject: [PATCH] =?UTF-8?q?style(=E6=8E=A5=E5=8F=A3=E8=87=AA=E5=8A=A8?= =?UTF-8?q?=E5=8C=96):=20=E6=8E=A5=E5=8F=A3=E6=AD=A5=E9=AA=A4=E6=A0=B7?= =?UTF-8?q?=E5=BC=8F=E7=BB=9F=E4=B8=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../scenario/component/ComponentConfig.vue | 16 ++++++++++++---- .../scenario/component/Jsr233Processor.vue | 7 ++++--- .../api/definition/components/step/JmxStep.vue | 4 ++-- 3 files changed, 18 insertions(+), 9 deletions(-) diff --git a/frontend/src/business/components/api/automation/scenario/component/ComponentConfig.vue b/frontend/src/business/components/api/automation/scenario/component/ComponentConfig.vue index 4eee593ba1..970fbb023a 100644 --- a/frontend/src/business/components/api/automation/scenario/component/ComponentConfig.vue +++ b/frontend/src/business/components/api/automation/scenario/component/ComponentConfig.vue @@ -1,7 +1,7 @@ @@ -32,6 +32,8 @@ data() { return { title: this.$t('api_test.automation.customize_script'), + titleColor: "", + backgroundColor: "", } }, computed: { @@ -79,25 +81,31 @@ getComponent(type) { if (type === ELEMENT_TYPE.JSR223PreProcessor) { this.title = this.$t('api_test.definition.request.pre_script'); + this.titleColor = "#B8741A"; + this.backgroundColor = "#F9F1EA"; return "MsJsr233Processor"; } else if (type === ELEMENT_TYPE.JSR223PostProcessor) { this.title = this.$t('api_test.definition.request.post_script'); + this.titleColor = "#783887"; + this.backgroundColor = "#F2ECF3"; return "MsJsr233Processor"; } else { this.title = this.$t('api_test.automation.customize_script'); + this.titleColor = "#7B4D12"; + this.backgroundColor = "#F1EEE9"; return "MsJsr233Processor"; } }, remove(row, node) { - this.$emit('remove',row,node); + this.$emit('remove', row, node); }, copyRow(row, node) { - this.$emit('copyRow',row,node); + this.$emit('copyRow', row, node); }, suggestClick(node) { - this.$emit('suggestClick',node); + this.$emit('suggestClick', node); }, } } diff --git a/frontend/src/business/components/api/automation/scenario/component/Jsr233Processor.vue b/frontend/src/business/components/api/automation/scenario/component/Jsr233Processor.vue index f6d83926d9..30c27f856a 100644 --- a/frontend/src/business/components/api/automation/scenario/component/Jsr233Processor.vue +++ b/frontend/src/business/components/api/automation/scenario/component/Jsr233Processor.vue @@ -4,8 +4,8 @@ @remove="remove" :data="jsr223ProcessorData" :draggable="draggable" - color="#B8741A" - background-color="#F9F1EA" + :color="color" + :background-color="backgroundColor" :title="title"> @@ -111,7 +111,8 @@ false }, title: String, - styleType: String, + color: String, + backgroundColor: String, node: {}, }, watch: { diff --git a/frontend/src/business/components/api/definition/components/step/JmxStep.vue b/frontend/src/business/components/api/definition/components/step/JmxStep.vue index 45dca71282..dfad0f4643 100644 --- a/frontend/src/business/components/api/definition/components/step/JmxStep.vue +++ b/frontend/src/business/components/api/definition/components/step/JmxStep.vue @@ -9,10 +9,10 @@
+ :jsr223-processor="row" color="#B8741A" background-color="#F9F1EA"/> + :jsr223-processor="row" color="#783887" background-color="#F2ECF3"/>