From 21fe243d0c41cebab29163a8243d172fcaa41847 Mon Sep 17 00:00:00 2001 From: dengbf Date: Wed, 3 Sep 2025 18:09:09 +0800 Subject: [PATCH 01/21] =?UTF-8?q?-=20[=E5=85=B3=E8=81=94]=20#[150081782202?= =?UTF-8?q?3680]=E8=87=AA=E5=8A=A8=E5=8C=96=E7=BB=84=E5=90=88=E5=B7=A5?= =?UTF-8?q?=E5=85=B7=E2=80=9C=E5=85=A8=E5=B1=80=E2=80=9C=E3=80=81=E2=80=9C?= =?UTF-8?q?=E9=98=B6=E6=AE=B5=E7=BB=84=E2=80=9D=E5=92=8C=E2=80=9C=E9=98=B6?= =?UTF-8?q?=E6=AE=B5=E2=80=9D=E9=83=BD=E6=94=AF=E6=8C=81=E9=80=89=E6=8B=A9?= =?UTF-8?q?=E6=89=A7=E8=A1=8C=E7=9B=AE=E6=A0=87=E6=94=AF=E6=8C=81=E2=80=9C?= =?UTF-8?q?=E5=89=8D=E7=BD=AE=E8=BF=87=E6=BB=A4=E5=99=A8=E2=80=9D=20http:/?= =?UTF-8?q?/192.168.0.96:8090/demo/rdm.html#/story-detail/939050947543040/?= =?UTF-8?q?939050947543042/1500817822023680?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../CombineSearcher/CombineSearcher.vue | 8 +- .../common/addTarget/add-filters.vue | 1 + .../components/common/addTarget/add-node.vue | 1 + .../common/addTarget/addtargetmixin.js | 4 + .../common/addTarget/target-detail.vue | 7 +- .../common/executionMode/filters.vue | 27 + .../detail/actionDetail/condition-search.vue | 526 ++++++++++++++++++ .../detail/actionDetail/execute-setting.vue | 47 +- .../pages/cmdb/asset/advanced-mode-search.vue | 8 +- 9 files changed, 610 insertions(+), 19 deletions(-) create mode 100644 src/views/pages/autoexec/detail/actionDetail/condition-search.vue diff --git a/src/resources/components/CombineSearcher/CombineSearcher.vue b/src/resources/components/CombineSearcher/CombineSearcher.vue index 75b947c8..04835fab 100644 --- a/src/resources/components/CombineSearcher/CombineSearcher.vue +++ b/src/resources/components/CombineSearcher/CombineSearcher.vue @@ -130,7 +130,7 @@
- +
@@ -227,6 +227,12 @@ export default { // 底部是否显示高级模式文案 type: Boolean, default: false + }, + searchText: { + type: String, + default() { + return this.$t('page.search'); + } } }, data() { diff --git a/src/views/pages/autoexec/components/common/addTarget/add-filters.vue b/src/views/pages/autoexec/components/common/addTarget/add-filters.vue index 6134f3e1..1de329ac 100644 --- a/src/views/pages/autoexec/components/common/addTarget/add-filters.vue +++ b/src/views/pages/autoexec/components/common/addTarget/add-filters.vue @@ -6,6 +6,7 @@ :canEdit="canEdit" :defaultValue="searchVal" :defaultSearchValue="defaultSearchValue" + :preCondition="preCondition" > diff --git a/src/views/pages/autoexec/components/common/addTarget/add-node.vue b/src/views/pages/autoexec/components/common/addTarget/add-node.vue index 7d7e6594..b7e1a1de 100644 --- a/src/views/pages/autoexec/components/common/addTarget/add-node.vue +++ b/src/views/pages/autoexec/components/common/addTarget/add-node.vue @@ -29,6 +29,7 @@ style="width:100%;display: inline-block;" :defaultValue="defaultSearchValue" :defaultSearchValue="defaultSearchValue" + :preCondition="preCondition" @changeValue="changeValue" @advancedModeSearch="(value) => advancedModeSearch(value, 1, 10)" > diff --git a/src/views/pages/autoexec/components/common/addTarget/addtargetmixin.js b/src/views/pages/autoexec/components/common/addTarget/addtargetmixin.js index f6c86cf6..930ba222 100644 --- a/src/views/pages/autoexec/components/common/addTarget/addtargetmixin.js +++ b/src/views/pages/autoexec/components/common/addTarget/addtargetmixin.js @@ -12,6 +12,10 @@ export default { defaultSearchValue: { //默认搜索条件,不可改变 type: Object, default: null + }, + preCondition: { //前置过滤条件 + type: Object, + default: null } }, data() { diff --git a/src/views/pages/autoexec/components/common/addTarget/target-detail.vue b/src/views/pages/autoexec/components/common/addTarget/target-detail.vue index 129ae7e2..6e5dd26a 100644 --- a/src/views/pages/autoexec/components/common/addTarget/target-detail.vue +++ b/src/views/pages/autoexec/components/common/addTarget/target-detail.vue @@ -1,4 +1,3 @@ - +
@@ -57,18 +69,10 @@ :type="settingConfig.whenToSpecify" :required="true" :labelWidth="113" + :preCondition="preCondition" >
-
-
- -
-
import('@/resources/plugins/TsForm/TsForm'), TargetDetail: () => import('@/views/pages/autoexec/components/common/addTarget/target-detail'), ExecutionModeParam: () => import('@/views/pages/autoexec/components/common/executionMode/param'), - Filters: () => import('@/views/pages/autoexec/components/common/executionMode/filters'), TargetValid: () => import('@/views/pages/autoexec/components/common/targetView/target-valid.vue'), ExecuteuserSetting: () => import('./executeuser-setting.vue'), RunnerGroupSetting: () => import('./runnergroup-setting.vue'), - RunnerGroupTagSetting: () => import('./runnergrouptag-setting.vue') + RunnerGroupTagSetting: () => import('./runnergrouptag-setting.vue'), + ConditionSearch: () => import('./condition-search.vue') }, filters: {}, props: { @@ -207,6 +211,12 @@ export default { dataList: this.$utils.getRoundCountList(), labelWidth: '113' }, + preCondition: { + type: 'slot', + label: '前置过滤器', + labelWidth: '113', + desc: '' + }, whenToSpecify: { type: 'radio', label: this.$t('term.autoexec.choosethetime'), @@ -229,12 +239,13 @@ export default { roundCount: null, parallelCount: null, whenToSpecify: 'runtime', + preCondition: null, executeNodeConfig: {} }, isValid: false, resultList: [], nodeTypeParamList: [], //可选的节点参数 - runtimeFilter: {} + preCondition: null }; }, beforeCreate() {}, @@ -266,9 +277,7 @@ export default { this.$set(this.form.parallelCount, 'isHidden', false); } }); - if (this.settingConfig.whenToSpecify == 'runtime') { - this.runtimeFilter = this.settingConfig.executeNodeConfig.filter || {}; - } + this.preCondition = this.$utils.deepClone(this.settingConfig['preCondition']); } this.loadingShow = false; }, @@ -291,7 +300,12 @@ export default { this.$set(this.settingConfig, 'executeUser', this.$refs.executeUser.save()); this.$set(this.settingConfig, 'runnerGroup', this.$refs.runnerGroup.save()); this.$set(this.settingConfig, 'runnerGroupTag', this.$refs.runnerGroupTag.save()); + if (!this.$utils.isEmpty(this.preCondition)) { + this.$set(this.settingConfig, 'preCondition', this.preCondition); + } + this.settingConfig.executeNodeConfig = {}; + if (this.settingConfig.whenToSpecify == 'now') { this.validSetting(true); } else if (this.settingConfig.whenToSpecify == 'runtime') { @@ -389,6 +403,9 @@ export default { this.$set(this.form.parallelCount, 'isHidden', false); } }); + }, + changePreConditionValue(val) { + this.preCondition = val; } }, computed: {}, diff --git a/src/views/pages/cmdb/asset/advanced-mode-search.vue b/src/views/pages/cmdb/asset/advanced-mode-search.vue index 5c2c5c1b..389fa91b 100644 --- a/src/views/pages/cmdb/asset/advanced-mode-search.vue +++ b/src/views/pages/cmdb/asset/advanced-mode-search.vue @@ -188,7 +188,7 @@
- +
@@ -245,6 +245,12 @@ export default { // 搜索条件列表 type: Array, default: () => { return []; } + }, + searchText: { + type: String, + default() { + return this.$t('page.search'); + } } }, data() { -- Gitee From 9e640d1db6c090b2075ff74c0412dd83ec4ac0eb Mon Sep 17 00:00:00 2001 From: dengbf Date: Wed, 3 Sep 2025 18:32:43 +0800 Subject: [PATCH 02/21] =?UTF-8?q?-=20[=E5=85=B3=E8=81=94]=20#[150081782202?= =?UTF-8?q?3680]=E8=87=AA=E5=8A=A8=E5=8C=96=E7=BB=84=E5=90=88=E5=B7=A5?= =?UTF-8?q?=E5=85=B7=E2=80=9C=E5=85=A8=E5=B1=80=E2=80=9C=E3=80=81=E2=80=9C?= =?UTF-8?q?=E9=98=B6=E6=AE=B5=E7=BB=84=E2=80=9D=E5=92=8C=E2=80=9C=E9=98=B6?= =?UTF-8?q?=E6=AE=B5=E2=80=9D=E9=83=BD=E6=94=AF=E6=8C=81=E9=80=89=E6=8B=A9?= =?UTF-8?q?=E6=89=A7=E8=A1=8C=E7=9B=AE=E6=A0=87=E6=94=AF=E6=8C=81=E2=80=9C?= =?UTF-8?q?=E5=89=8D=E7=BD=AE=E8=BF=87=E6=BB=A4=E5=99=A8=E2=80=9D=20http:/?= =?UTF-8?q?/192.168.0.96:8090/demo/rdm.html#/story-detail/939050947543040/?= =?UTF-8?q?939050947543042/1500817822023680?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/common/addTarget/add-input.vue | 3 +++ .../components/common/addTarget/add-node.vue | 14 +++++++++++++- .../detail/actionDetail/execute-setting.vue | 1 - 3 files changed, 16 insertions(+), 2 deletions(-) diff --git a/src/views/pages/autoexec/components/common/addTarget/add-input.vue b/src/views/pages/autoexec/components/common/addTarget/add-input.vue index 329598a5..ac8a717d 100644 --- a/src/views/pages/autoexec/components/common/addTarget/add-input.vue +++ b/src/views/pages/autoexec/components/common/addTarget/add-input.vue @@ -213,6 +213,9 @@ export default { inputNodeList: list, cmdbGroupType: this.opType }; + if (!this.$utils.isEmpty(this.preCondition)) { + data.preCondition = this.preCondition; + } this.isLoading = true; return this.$api.autoexec.action.validinputnodelist(data).then(res => { if (res.Status == 'OK') { diff --git a/src/views/pages/autoexec/components/common/addTarget/add-node.vue b/src/views/pages/autoexec/components/common/addTarget/add-node.vue index b7e1a1de..e85d4aaa 100644 --- a/src/views/pages/autoexec/components/common/addTarget/add-node.vue +++ b/src/views/pages/autoexec/components/common/addTarget/add-node.vue @@ -29,7 +29,6 @@ style="width:100%;display: inline-block;" :defaultValue="defaultSearchValue" :defaultSearchValue="defaultSearchValue" - :preCondition="preCondition" @changeValue="changeValue" @advancedModeSearch="(value) => advancedModeSearch(value, 1, 10)" > @@ -181,6 +180,9 @@ export default { ...this.searchVal, ...this.defaultSearchValue }; + if (!this.$utils.isEmpty(this.preCondition)) { + data.preCondition = this.preCondition; + } this.$api.autoexec.action.getNodeList(data).then(res => { if (res.Status == 'OK') { this.tableData = res.Return; @@ -260,6 +262,9 @@ export default { ...this.defaultSearchValue, ...searchVal }; + if (!this.$utils.isEmpty(this.preCondition)) { + params.preCondition = this.preCondition; + } this.loadingShow = true; this.$api.autoexec.action.searchResourceCustomList(params).then(res => { if (res.Status == 'OK') { @@ -304,6 +309,13 @@ export default { }, deep: true, immediate: true + }, + preCondition: { + handler(val) { + this.clearAll(); + this.handlePageChange(); + }, + deep: true } } }; diff --git a/src/views/pages/autoexec/detail/actionDetail/execute-setting.vue b/src/views/pages/autoexec/detail/actionDetail/execute-setting.vue index 955939f6..e4455fd6 100644 --- a/src/views/pages/autoexec/detail/actionDetail/execute-setting.vue +++ b/src/views/pages/autoexec/detail/actionDetail/execute-setting.vue @@ -305,7 +305,6 @@ export default { } this.settingConfig.executeNodeConfig = {}; - if (this.settingConfig.whenToSpecify == 'now') { this.validSetting(true); } else if (this.settingConfig.whenToSpecify == 'runtime') { -- Gitee From 3094675e87e795ed8df08d722e91e8d8c73f905a Mon Sep 17 00:00:00 2001 From: dengbf Date: Wed, 3 Sep 2025 18:46:41 +0800 Subject: [PATCH 03/21] =?UTF-8?q?-=20[=E5=85=B3=E8=81=94]=20#[150081782202?= =?UTF-8?q?3680]=E8=87=AA=E5=8A=A8=E5=8C=96=E7=BB=84=E5=90=88=E5=B7=A5?= =?UTF-8?q?=E5=85=B7=E2=80=9C=E5=85=A8=E5=B1=80=E2=80=9C=E3=80=81=E2=80=9C?= =?UTF-8?q?=E9=98=B6=E6=AE=B5=E7=BB=84=E2=80=9D=E5=92=8C=E2=80=9C=E9=98=B6?= =?UTF-8?q?=E6=AE=B5=E2=80=9D=E9=83=BD=E6=94=AF=E6=8C=81=E9=80=89=E6=8B=A9?= =?UTF-8?q?=E6=89=A7=E8=A1=8C=E7=9B=AE=E6=A0=87=E6=94=AF=E6=8C=81=E2=80=9C?= =?UTF-8?q?=E5=89=8D=E7=BD=AE=E8=BF=87=E6=BB=A4=E5=99=A8=E2=80=9D=20http:/?= =?UTF-8?q?/192.168.0.96:8090/demo/rdm.html#/story-detail/939050947543040/?= =?UTF-8?q?939050947543042/1500817822023680?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../detail/actionDetail/execute-setting.vue | 3 +- .../actionDetail/step/edit/step-edit.vue | 29 ++++++++++++++++--- 2 files changed, 26 insertions(+), 6 deletions(-) diff --git a/src/views/pages/autoexec/detail/actionDetail/execute-setting.vue b/src/views/pages/autoexec/detail/actionDetail/execute-setting.vue index e4455fd6..cc9af19d 100644 --- a/src/views/pages/autoexec/detail/actionDetail/execute-setting.vue +++ b/src/views/pages/autoexec/detail/actionDetail/execute-setting.vue @@ -214,8 +214,7 @@ export default { preCondition: { type: 'slot', label: '前置过滤器', - labelWidth: '113', - desc: '' + labelWidth: '113' }, whenToSpecify: { type: 'radio', diff --git a/src/views/pages/autoexec/detail/actionDetail/step/edit/step-edit.vue b/src/views/pages/autoexec/detail/actionDetail/step/edit/step-edit.vue index 8ea62f24..da178c70 100644 --- a/src/views/pages/autoexec/detail/actionDetail/step/edit/step-edit.vue +++ b/src/views/pages/autoexec/detail/actionDetail/step/edit/step-edit.vue @@ -80,6 +80,15 @@ :runtimeParamList="runtimeParamList" > +
@@ -172,7 +182,8 @@ export default { TsFormSwitch: () => import('@/resources/plugins/TsForm/TsFormSwitch'), ExecuteuserSetting: () => import('@/views/pages/autoexec/detail/actionDetail/executeuser-setting.vue'), RunnerGroupSetting: () => import('@/views/pages/autoexec/detail/actionDetail/runnergroup-setting.vue'), - RunnerGroupTagSetting: () => import('@/views/pages/autoexec/detail/actionDetail/runnergrouptag-setting.vue') + RunnerGroupTagSetting: () => import('@/views/pages/autoexec/detail/actionDetail/runnergrouptag-setting.vue'), + ConditionSearch: () => import('@/views/pages/autoexec/detail/actionDetail/condition-search.vue') }, filters: {}, props: { @@ -299,6 +310,10 @@ export default { label: this.$t('term.autoexec.parall'), desc: this.$t('term.autoexec.paralldesc'), dataList: this.$utils.getRoundCountList() + }, + preCondition: { + type: 'slot', + label: '前置过滤器' } }, executeConfig: { @@ -311,7 +326,8 @@ export default { executeNodeConfig: {}, isPresetRunnerGroup: 0, runnerGroup: null, - runnerGroupTag: null + runnerGroupTag: null, + preCondition: null }, isValid: false, // 校验执行目标 @@ -324,7 +340,8 @@ export default { mappingMode: 'constant', value: '', text: '' - } + }, + preCondition: null }; }, beforeCreate() {}, @@ -341,6 +358,7 @@ export default { this.executeConfig[key] = this.config.config.executeConfig[key]; } }); + this.preCondition = this.$utils.deepClone(this.executeConfig.preCondition); if (!this.$utils.isEmpty(this.executeConfig.runnerGroup) || !this.$utils.isEmpty(this.executeConfig.runnerGroupTag)) { this.$set(this.executeConfig, 'isPresetRunnerGroup', 1); } @@ -395,7 +413,7 @@ export default { } else { this.executeConfig.parallelCount = null; } - + this.executeConfig.preCondition = !this.$utils.isEmpty(this.preCondition) ? this.preCondition : null; if (this.$refs.form.valid()) { let editConfig = this.$utils.deepClone(this.editConfig); if (editConfig.policy && (!this.groupConfig || this.groupConfig.policy != 'grayScale' || (this.editConfig.execMode && this.editConfig.execMode != 'runner' && this.editConfig.execMode != 'sqlfile'))) { @@ -521,6 +539,9 @@ export default { this.$set(this.executeForm.parallelCount, 'isHidden', false); } }); + }, + changePreConditionValue(val) { + this.preCondition = val; } }, computed: {}, -- Gitee From 81a5fbabc554760326a2309a175c1fabc0c520eb Mon Sep 17 00:00:00 2001 From: dengbf Date: Thu, 4 Sep 2025 11:42:36 +0800 Subject: [PATCH 04/21] =?UTF-8?q?-=20[=E5=85=B3=E8=81=94]=20#[150081782202?= =?UTF-8?q?3680]=E8=87=AA=E5=8A=A8=E5=8C=96=E7=BB=84=E5=90=88=E5=B7=A5?= =?UTF-8?q?=E5=85=B7=E2=80=9C=E5=85=A8=E5=B1=80=E2=80=9C=E3=80=81=E2=80=9C?= =?UTF-8?q?=E9=98=B6=E6=AE=B5=E7=BB=84=E2=80=9D=E5=92=8C=E2=80=9C=E9=98=B6?= =?UTF-8?q?=E6=AE=B5=E2=80=9D=E9=83=BD=E6=94=AF=E6=8C=81=E9=80=89=E6=8B=A9?= =?UTF-8?q?=E6=89=A7=E8=A1=8C=E7=9B=AE=E6=A0=87=E6=94=AF=E6=8C=81=E2=80=9C?= =?UTF-8?q?=E5=89=8D=E7=BD=AE=E8=BF=87=E6=BB=A4=E5=99=A8=E2=80=9D=20http:/?= =?UTF-8?q?/192.168.0.96:8090/demo/rdm.html#/story-detail/939050947543040/?= =?UTF-8?q?939050947543042/1500817822023680?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../detail/actionDetail/condition-search.vue | 4 +- .../detail/actionDetail/step-group.vue | 63 ++++++++++++++----- .../actionDetail/step/edit/step-edit.vue | 7 ++- 3 files changed, 54 insertions(+), 20 deletions(-) diff --git a/src/views/pages/autoexec/detail/actionDetail/condition-search.vue b/src/views/pages/autoexec/detail/actionDetail/condition-search.vue index 1c07715a..a8d0aaa5 100644 --- a/src/views/pages/autoexec/detail/actionDetail/condition-search.vue +++ b/src/views/pages/autoexec/detail/actionDetail/condition-search.vue @@ -488,10 +488,10 @@ export default { handler(val) { this.isSimpleMode = true; // 重置简单模式,防止编辑执行目标时,模式回显不正确问题 if (val) { - if (val && val.hasOwnProperty('conditionGroupList')) { + if (val && val.hasOwnProperty('conditionGroupList') && !this.$utils.isEmpty(val.conditionGroupList) && !this.$utils.isSame(val, this.complexSearchVal)) { this.complexSearchVal = this.$utils.deepClone(val); this.isSimpleMode = !this.isSimpleMode; - } else { + } else if (!this.$utils.isSame(val, this.searchVal)) { this.searchVal = this.$utils.deepClone(val); } } diff --git a/src/views/pages/autoexec/detail/actionDetail/step-group.vue b/src/views/pages/autoexec/detail/actionDetail/step-group.vue index 05617862..82676807 100644 --- a/src/views/pages/autoexec/detail/actionDetail/step-group.vue +++ b/src/views/pages/autoexec/detail/actionDetail/step-group.vue @@ -5,7 +5,7 @@
{{ $t('term.autoexec.stagegroup') }}
{{ currentGroupConfig.sort + 1 }}
- +
@@ -313,8 +314,7 @@ export default { }, preCondition: { type: 'slot', - label: '前置过滤器', - desc: '如果为空时,继承全局过滤器' + label: '前置过滤器' } }, executeConfig: { -- Gitee From 23a1d4b87e64eb01a67188723f6ac9f551a7afd5 Mon Sep 17 00:00:00 2001 From: dengbf Date: Thu, 4 Sep 2025 14:49:51 +0800 Subject: [PATCH 06/21] =?UTF-8?q?-=20[=E5=85=B3=E8=81=94]=20#[150081782202?= =?UTF-8?q?3680]=E8=87=AA=E5=8A=A8=E5=8C=96=E7=BB=84=E5=90=88=E5=B7=A5?= =?UTF-8?q?=E5=85=B7=E2=80=9C=E5=85=A8=E5=B1=80=E2=80=9C=E3=80=81=E2=80=9C?= =?UTF-8?q?=E9=98=B6=E6=AE=B5=E7=BB=84=E2=80=9D=E5=92=8C=E2=80=9C=E9=98=B6?= =?UTF-8?q?=E6=AE=B5=E2=80=9D=E9=83=BD=E6=94=AF=E6=8C=81=E9=80=89=E6=8B=A9?= =?UTF-8?q?=E6=89=A7=E8=A1=8C=E7=9B=AE=E6=A0=87=E6=94=AF=E6=8C=81=E2=80=9C?= =?UTF-8?q?=E5=89=8D=E7=BD=AE=E8=BF=87=E6=BB=A4=E5=99=A8=E2=80=9D=20http:/?= =?UTF-8?q?/192.168.0.96:8090/demo/rdm.html#/story-detail/939050947543040/?= =?UTF-8?q?939050947543042/1500817822023680?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/pages/autoexec/detail/action-detail.vue | 2 ++ .../pages/autoexec/detail/actionDetail/step-group.vue | 7 ++++--- .../detail/actionDetail/step/edit/step-edit.vue | 11 ++++++----- .../autoexec/detail/actionDetail/step/step-list.vue | 4 +++- 4 files changed, 15 insertions(+), 9 deletions(-) diff --git a/src/views/pages/autoexec/detail/action-detail.vue b/src/views/pages/autoexec/detail/action-detail.vue index f4ab4d1a..ebca4b64 100644 --- a/src/views/pages/autoexec/detail/action-detail.vue +++ b/src/views/pages/autoexec/detail/action-detail.vue @@ -126,6 +126,7 @@ :canEdit="effectiveEditable && operationType == 'combop' ? true : false" :execModeList="execModeList" :runtimeParamList="runtimeParamList" + :globalPreCondition="executeConfig.preCondition" @updateSort="updateSort" @change="changeSelectStep" > @@ -187,6 +188,7 @@ :currentGroupConfig="currentGroupConfig" :runtimeParamList="runtimeParamList" :canEdit="effectiveEditable && operationType == 'combop' ? true : false" + :globalPreCondition="executeConfig.preCondition" @save="saveCurrentGroupConfig" >
diff --git a/src/views/pages/autoexec/detail/actionDetail/step-group.vue b/src/views/pages/autoexec/detail/actionDetail/step-group.vue index e3781f4b..907da1c7 100644 --- a/src/views/pages/autoexec/detail/actionDetail/step-group.vue +++ b/src/views/pages/autoexec/detail/actionDetail/step-group.vue @@ -177,7 +177,7 @@ ref="targetDetail" :canEdit="canEdit" :config="executeConfig.executeNodeConfig" - :preCondition="executeConfig.preCondition" + :preCondition="executeConfig.preCondition || globalPreCondition" :isAddParam="true" :labelWidth="100" > @@ -264,7 +264,8 @@ export default { id: [Number, String], canEdit: Boolean, currentGroupConfig: Object, - runtimeParamList: Array //运行参数 + runtimeParamList: Array, //运行参数 + globalPreCondition: Object //全局前置过滤器 }, data() { let _this = this; @@ -548,7 +549,7 @@ export default { }); }, changePreConditionValue(val) { - this.$set(this.executeConfig, 'preCondition', val); + this.$set(this.executeConfig, 'preCondition', !this.$utils.isEmpty(val) ? val : null); } }, computed: { diff --git a/src/views/pages/autoexec/detail/actionDetail/step/edit/step-edit.vue b/src/views/pages/autoexec/detail/actionDetail/step/edit/step-edit.vue index d888b371..f3ec4ef6 100644 --- a/src/views/pages/autoexec/detail/actionDetail/step/edit/step-edit.vue +++ b/src/views/pages/autoexec/detail/actionDetail/step/edit/step-edit.vue @@ -102,7 +102,7 @@ :isAddPrenode="prevStepList.length > 0 ? true : false" :prevStepList="prevStepList" :runtimeParamList="runtimeParamList" - :preCondition="preCondition" + :preCondition="preCondition || globalPreCondition" > @@ -215,7 +215,8 @@ export default { type: Array, default: () => [] }, - runtimeParamList: Array + runtimeParamList: Array, + globalPreCondition: Object //全局前置过滤器 }, data() { let _this = this; @@ -359,7 +360,7 @@ export default { this.executeConfig[key] = this.config.config.executeConfig[key]; } }); - this.preCondition = this.$utils.deepClone(this.executeConfig.preCondition); + this.preCondition = !this.$utils.isEmpty(this.globalPreCondition) ? this.$utils.deepClone(this.executeConfig.preCondition) : null; if (!this.$utils.isEmpty(this.executeConfig.runnerGroup) || !this.$utils.isEmpty(this.executeConfig.runnerGroupTag)) { this.$set(this.executeConfig, 'isPresetRunnerGroup', 1); } @@ -541,8 +542,8 @@ export default { } }); }, - changePreConditionValue(val) { - this.preCondition = val; + changePreConditionValue(val) { + this.preCondition = !this.$utils.isEmpty(val) ? val : null; } }, computed: {}, diff --git a/src/views/pages/autoexec/detail/actionDetail/step/step-list.vue b/src/views/pages/autoexec/detail/actionDetail/step/step-list.vue index aeabacb0..98804203 100644 --- a/src/views/pages/autoexec/detail/actionDetail/step/step-list.vue +++ b/src/views/pages/autoexec/detail/actionDetail/step/step-list.vue @@ -98,6 +98,7 @@ :groupConfig="groupConfig" :prevStepList="getPrev(editConfig, stepList)" :runtimeParamList="runtimeParamList" + :globalPreCondition="globalPreCondition" @close="close" > @@ -145,7 +146,8 @@ export default { type: Array }, scrollLeft: Number, - runtimeParamList: Array + runtimeParamList: Array, + globalPreCondition: Object //全局前置条件 }, data() { return { -- Gitee From b2abde2944e2e826f85679b508c5e2856f5bcb68 Mon Sep 17 00:00:00 2001 From: dengbf Date: Thu, 4 Sep 2025 19:00:45 +0800 Subject: [PATCH 07/21] =?UTF-8?q?-=20[=E5=85=B3=E8=81=94]=20#[150081782202?= =?UTF-8?q?3680]=E8=87=AA=E5=8A=A8=E5=8C=96=E7=BB=84=E5=90=88=E5=B7=A5?= =?UTF-8?q?=E5=85=B7=E2=80=9C=E5=85=A8=E5=B1=80=E2=80=9C=E3=80=81=E2=80=9C?= =?UTF-8?q?=E9=98=B6=E6=AE=B5=E7=BB=84=E2=80=9D=E5=92=8C=E2=80=9C=E9=98=B6?= =?UTF-8?q?=E6=AE=B5=E2=80=9D=E9=83=BD=E6=94=AF=E6=8C=81=E9=80=89=E6=8B=A9?= =?UTF-8?q?=E6=89=A7=E8=A1=8C=E7=9B=AE=E6=A0=87=E6=94=AF=E6=8C=81=E2=80=9C?= =?UTF-8?q?=E5=89=8D=E7=BD=AE=E8=BF=87=E6=BB=A4=E5=99=A8=E2=80=9D=20http:/?= =?UTF-8?q?/192.168.0.96:8090/demo/rdm.html#/story-detail/939050947543040/?= =?UTF-8?q?939050947543042/1500817822023680?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/common/filter-search.vue | 150 +++++------------- .../common/targetView/target-filter.vue | 21 ++- .../components/common/targetView/target.vue | 11 +- .../detail/actionDetail/condition-search.vue | 150 +++++------------- .../detail/actionDetail/execute-setting.vue | 3 - .../detail/actionDetail/step-group.vue | 15 +- .../actionDetail/step/edit/step-edit.vue | 3 +- .../pages/autoexec/detail/runner-detail.vue | 16 +- .../detail/runnerDetail/add-target.vue | 95 +++++++---- 9 files changed, 192 insertions(+), 272 deletions(-) diff --git a/src/views/pages/autoexec/components/common/filter-search.vue b/src/views/pages/autoexec/components/common/filter-search.vue index 90af3f47..92122e74 100644 --- a/src/views/pages/autoexec/components/common/filter-search.vue +++ b/src/views/pages/autoexec/components/common/filter-search.vue @@ -195,18 +195,6 @@ export default { disabledUuidList: [], // 复杂模式,禁用的搜索条件 disabledGroupUuidList: [], searchList: [ - { - name: 'typeIdList', - type: 'tree', - label: this.$t('term.cmdb.citype'), - search: true, - transfer: true, - multiple: true, - textName: 'label', - valueName: 'id', - url: '/api/rest/resourcecenter/resourcetype/tree', - validateList: [{name: 'required', message: ''}] - }, { name: 'appSystemIdList', type: 'select', @@ -249,48 +237,33 @@ export default { validateList: [{name: 'required', message: ''}] }, { - name: 'protocolIdList', + name: 'inspectStatusList', type: 'select', - label: this.$t('page.protocol'), + label: this.$t('term.autoexec.inspectstatus'), search: true, transfer: true, defaultValue: [], - rootName: 'tbodyList', multiple: true, - dealDataByUrl: 'getProtocolDataList', className: 'block-span', - dynamicUrl: '/api/rest/resourcecenter/account/protocol/search', + params: { + 'enumClass': 'neatlogic.framework.common.constvalue.InspectStatus' + }, + url: '/api/rest/universal/enum/get', validateList: [{name: 'required', message: ''}] }, { - name: 'tagIdList', - type: 'select', - label: this.$t('page.tag'), - search: true, - textName: 'name', - transfer: true, - valueName: 'id', - defaultValue: [], - rootName: 'tbodyList', - multiple: true, - dynamicUrl: '/api/rest/resourcecenter/tag/list/forselect', - validateList: [{name: 'required', message: ''}] + name: 'ip', + type: 'input', + label: this.$t('page.ip'), + validateList: [{name: 'required', message: ''}], + maxlength: 256 }, { - name: 'stateIdList', - type: 'select', - label: this.$t('term.autoexec.assetstatus'), - search: true, - transfer: true, - defaultValue: [], - multiple: true, - className: 'block-span', - url: '/api/rest/resourcecenter/state/list/forselect', - params: { needPage: false }, - rootName: 'tbodyList', - textName: 'name', - valueName: 'id', - validateList: [{name: 'required', message: ''}] + name: 'name', + type: 'input', + label: this.$t('page.name'), + validateList: [{name: 'required', message: ''}], + maxlength: 256 }, { name: 'vendorIdList', @@ -310,95 +283,50 @@ export default { validateList: [{name: 'required', message: ''}] }, { - name: 'inspectStatusList', + name: 'tagIdList', type: 'select', - label: this.$t('term.autoexec.inspectstatus'), + label: this.$t('page.tag'), search: true, + textName: 'name', transfer: true, + valueName: 'id', defaultValue: [], + rootName: 'tbodyList', multiple: true, - className: 'block-span', - params: { - 'enumClass': 'neatlogic.framework.common.constvalue.InspectStatus' - }, - url: '/api/rest/universal/enum/get', - validateList: [{name: 'required', message: ''}] - }, - { - name: 'port', - type: 'input', - label: this.$t('page.port'), - validateList: [{name: 'required', message: ''}], - maxlength: 256 - }, - { - name: 'ip', - type: 'input', - label: this.$t('page.ip'), - validateList: [{name: 'required', message: ''}], - maxlength: 256 - }, - { - name: 'name', - type: 'input', - label: this.$t('page.name'), - validateList: [{name: 'required', message: ''}], - maxlength: 256 - }, - { - name: 'description', - type: 'input', - label: this.$t('page.description'), - validateList: [{name: 'required', message: ''}], - maxlength: 256 - }, - { - name: 'networkArea', - type: 'input', - label: this.$t('page.networkarea'), - validateList: [{name: 'required', message: ''}], - maxlength: 256 - }, - { - name: 'maintenanceWindow', - type: 'datetimerange', - label: this.$t('term.autoexec.maintenanceperiod'), - format: 'yyyy-MM-dd HH:mm', + dynamicUrl: '/api/rest/resourcecenter/tag/list/forselect', validateList: [{name: 'required', message: ''}] }, { - name: 'ownerList', + name: 'protocolIdList', type: 'select', - label: this.$t('page.owner'), + label: this.$t('page.protocol'), search: true, transfer: true, - multiple: true, - dynamicUrl: '/api/rest/user/search/forselect', + defaultValue: [], rootName: 'tbodyList', - textName: 'userName', - valueName: 'uuid', - params: { - needPage: true - }, + multiple: true, + dealDataByUrl: 'getProtocolDataList', + className: 'block-span', + dynamicUrl: '/api/rest/resourcecenter/account/protocol/search', validateList: [{name: 'required', message: ''}] }, { - name: 'bgList', + name: 'stateIdList', type: 'select', - label: this.$t('term.autoexec.subordinatedepartment'), + label: this.$t('term.autoexec.assetstatus'), search: true, transfer: true, + defaultValue: [], multiple: true, - dynamicUrl: '/api/rest/team/search', - rootName: 'teamList', + className: 'block-span', + url: '/api/rest/resourcecenter/state/list/forselect', + params: { needPage: false }, + rootName: 'tbodyList', textName: 'name', - valueName: 'uuid', - params: { - needPage: true, - level: 'department' - }, + valueName: 'id', validateList: [{name: 'required', message: ''}] - }] + } + ] }; }, beforeCreate() {}, diff --git a/src/views/pages/autoexec/components/common/targetView/target-filter.vue b/src/views/pages/autoexec/components/common/targetView/target-filter.vue index 2866cca4..25c53725 100644 --- a/src/views/pages/autoexec/components/common/targetView/target-filter.vue +++ b/src/views/pages/autoexec/components/common/targetView/target-filter.vue @@ -1,6 +1,20 @@ @@ -257,7 +258,7 @@ export default { TargetView: () => import('@/views/pages/autoexec/components/common/targetView/target.vue'), TargetValid: () => import('@/views/pages/autoexec/components/common/targetView/target-valid.vue'), ExecuteuserSetting: () => import('./executeuser-setting.vue'), - ConditionSearch: () => import('@/views/pages/autoexec/detail/actionDetail/condition-search.vue') + FilterSearch: () => import('@/views/pages/autoexec/components/common/filter-search.vue') }, filters: { }, diff --git a/src/views/pages/autoexec/detail/actionDetail/step/edit/step-edit.vue b/src/views/pages/autoexec/detail/actionDetail/step/edit/step-edit.vue index a19e8df1..f99fddc2 100644 --- a/src/views/pages/autoexec/detail/actionDetail/step/edit/step-edit.vue +++ b/src/views/pages/autoexec/detail/actionDetail/step/edit/step-edit.vue @@ -81,13 +81,14 @@ > @@ -185,7 +186,7 @@ export default { ExecuteuserSetting: () => import('@/views/pages/autoexec/detail/actionDetail/executeuser-setting.vue'), RunnerGroupSetting: () => import('@/views/pages/autoexec/detail/actionDetail/runnergroup-setting.vue'), RunnerGroupTagSetting: () => import('@/views/pages/autoexec/detail/actionDetail/runnergrouptag-setting.vue'), - ConditionSearch: () => import('@/views/pages/autoexec/detail/actionDetail/condition-search.vue') + FilterSearch: () => import('@/views/pages/autoexec/components/common/filter-search.vue') }, filters: {}, props: { diff --git a/src/views/pages/autoexec/detail/runner-detail.vue b/src/views/pages/autoexec/detail/runner-detail.vue index 2ffa0ee7..6a76ecf5 100644 --- a/src/views/pages/autoexec/detail/runner-detail.vue +++ b/src/views/pages/autoexec/detail/runner-detail.vue @@ -153,16 +153,16 @@ {{ $t('term.autoexec.executetarget') }}
- + >
@@ -303,7 +303,7 @@ export default { ExecuteuserSetting: () => import('@/views/pages/autoexec/detail/actionDetail/executeuser-setting.vue'), RunnerGroupSetting: () => import('@/views/pages/autoexec/detail/actionDetail/runnergroup-setting.vue'), RunnerGroupTagSetting: () => import('@/views/pages/autoexec/detail/actionDetail/runnergrouptag-setting.vue'), - ConditionSearch: () => import('@/views/pages/autoexec/detail/actionDetail/condition-search.vue') + FilterSearch: () => import('@/views/pages/autoexec/components/common/filter-search.vue') }, filters: {}, props: { @@ -450,7 +450,8 @@ export default { value: 'roundCount' } ], - parallelPolicy: 'parallel' + parallelPolicy: 'parallel', + preCondition: null }; }, beforeCreate() {}, @@ -591,6 +592,9 @@ export default { this.scenarioList = this.dataConfig.config.scenarioList; } this.getSelectStepList(this.scenarioId); + if (this.dataConfig.config.executeConfig && !this.$utils.isEmpty(this.dataConfig.config.executeConfig.preCondition)) { + this.preCondition = this.dataConfig.config.executeConfig.preCondition; + } }) .finally(res => { this.loading = false; diff --git a/src/views/pages/autoexec/detail/runnerDetail/add-target.vue b/src/views/pages/autoexec/detail/runnerDetail/add-target.vue index 7ca219cd..d21dc262 100644 --- a/src/views/pages/autoexec/detail/runnerDetail/add-target.vue +++ b/src/views/pages/autoexec/detail/runnerDetail/add-target.vue @@ -89,11 +89,11 @@ :labelWidth="100" labelPosition="left" > - + > import('@/views/pages/autoexec/components/common/executionMode/filters.vue'), TargetView: () => import('@/views/pages/autoexec/components/common/targetView/target.vue'), TargetValid: () => import('@/views/pages/autoexec/components/common/targetView/target-valid.vue'), - ConditionSearch: () => import('@/views/pages/autoexec/detail/actionDetail/condition-search.vue'), + FilterSearch: () => import('@/views/pages/autoexec/components/common/filter-search.vue'), TsFormItem: () => import('@/resources/plugins/TsForm/TsFormItem') }, filters: {}, diff --git a/src/views/pages/autoexec/quick-service/catalog/service.vue b/src/views/pages/autoexec/quick-service/catalog/service.vue index bfcdb65f..0ac0f914 100644 --- a/src/views/pages/autoexec/quick-service/catalog/service.vue +++ b/src/views/pages/autoexec/quick-service/catalog/service.vue @@ -284,6 +284,13 @@ {{ $t('term.autoexec.executetarget') }}
+ + +
@@ -503,7 +511,8 @@ export default { ExecuteuserSetting: () => import('@/views/pages/autoexec/detail/actionDetail/executeuser-setting.vue'), RunnerGroupSetting: () => import('@/views/pages/autoexec/detail/actionDetail/runnergroup-setting.vue'), RunnerGroupTagSetting: () => import('@/views/pages/autoexec/detail/actionDetail/runnergrouptag-setting.vue'), - ExpiredReasonAlert: () => import('../service-catalog/expired-reason-alert'), // 服务失效原因提示列表 + ExpiredReasonAlert: () => import('../service-catalog/expired-reason-alert'), // + FilterSearch: () => import('@/views/pages/autoexec/components/common/filter-search.vue'), ...Component }, mixins: [catalogmixin], @@ -795,7 +804,8 @@ export default { transfer: true, desc: this.$t('term.autoexec.paralldesc'), disabled: false - } + }, + preCondition: null }; }, beforeCreate() {}, @@ -1307,6 +1317,9 @@ export default { this.executeUser.value = this.executeUser && this.executeUser.value ? this.executeUser.value : executeConfig['executeUser'] ? executeConfig['executeUser']['value'] : ''; this.protocol.value = this.protocol && this.protocol.value ? this.protocol.value : executeConfig['protocolId']; } + if (!this.$utils.isEmpty(executeConfig.preCondition)) { + this.preCondition = executeConfig.preCondition; + } } }) .finally(() => { -- Gitee From 647876687a5d65e7bd4f588dbe14e66b6873f5d3 Mon Sep 17 00:00:00 2001 From: dengbf Date: Fri, 5 Sep 2025 16:33:05 +0800 Subject: [PATCH 09/21] =?UTF-8?q?-=20[=E5=85=B3=E8=81=94]=20#[150081782202?= =?UTF-8?q?3680]=E8=87=AA=E5=8A=A8=E5=8C=96=E7=BB=84=E5=90=88=E5=B7=A5?= =?UTF-8?q?=E5=85=B7=E2=80=9C=E5=85=A8=E5=B1=80=E2=80=9C=E3=80=81=E2=80=9C?= =?UTF-8?q?=E9=98=B6=E6=AE=B5=E7=BB=84=E2=80=9D=E5=92=8C=E2=80=9C=E9=98=B6?= =?UTF-8?q?=E6=AE=B5=E2=80=9D=E9=83=BD=E6=94=AF=E6=8C=81=E9=80=89=E6=8B=A9?= =?UTF-8?q?=E6=89=A7=E8=A1=8C=E7=9B=AE=E6=A0=87=E6=94=AF=E6=8C=81=E2=80=9C?= =?UTF-8?q?=E5=89=8D=E7=BD=AE=E8=BF=87=E6=BB=A4=E5=99=A8=E2=80=9D=20http:/?= =?UTF-8?q?/192.168.0.96:8090/demo/rdm.html#/story-detail/939050947543040/?= =?UTF-8?q?939050947543042/1500817822023680?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/resources/assets/languages/term/en.json | 5 ++++- src/resources/assets/languages/term/zh.json | 5 ++++- .../CombineSearcher/CombineSearcher.vue | 3 +-- .../common/targetView/target-filter.vue | 4 ++-- .../detail/actionDetail/execute-setting.vue | 2 +- .../detail/actionDetail/step-group.vue | 10 ++++----- .../actionDetail/step/edit/step-edit.vue | 4 ++-- .../pages/autoexec/detail/runner-detail.vue | 12 +++++------ .../detail/runnerDetail/add-target.vue | 10 ++++----- .../quick-service/catalog/service.vue | 2 +- .../service-catalog/no-form-service-edit.vue | 11 ++++++++++ .../service-catalog/other-params.vue | 10 +++++++++ .../pages/cmdb/asset/advanced-mode-search.vue | 3 +-- .../components/createjob/createjob-config.vue | 7 +++---- .../createjob/params/execute-param.vue | 21 +++++++++++++------ 15 files changed, 71 insertions(+), 38 deletions(-) diff --git a/src/resources/assets/languages/term/en.json b/src/resources/assets/languages/term/en.json index f0d56b61..819d5696 100644 --- a/src/resources/assets/languages/term/en.json +++ b/src/resources/assets/languages/term/en.json @@ -914,7 +914,10 @@ "parall": "Concurrent quantity", "paralldesc": "Execute the execution targets in order of concurrency.", "jobrecord": "Automated job recording", - "jobcount": "Number of automated tasks" + "jobcount": "Number of automated tasks", + "precondition": "pre-filter", + "globalprecondition": "Global pre filter", + "preconditiontip": "If empty, inherit the global pre filter" }, "framework": { "roleauth": "Authorize immediately after creating the role", diff --git a/src/resources/assets/languages/term/zh.json b/src/resources/assets/languages/term/zh.json index de31e51c..579552f3 100644 --- a/src/resources/assets/languages/term/zh.json +++ b/src/resources/assets/languages/term/zh.json @@ -914,7 +914,10 @@ "parall": "并发数量", "paralldesc": "将执行目标按并发数量先后执行。", "jobrecord": "自动化作业记录", - "jobcount": "自动化作业数" + "jobcount": "自动化作业数", + "precondition": "前置过滤器", + "globalprecondition": "全局前置过滤器", + "preconditiontip": "如果为空时,继承全局前置过滤器" }, "framework": { "roleauth": "创建完角色立即授权", diff --git a/src/resources/components/CombineSearcher/CombineSearcher.vue b/src/resources/components/CombineSearcher/CombineSearcher.vue index 04835fab..01f1aad0 100644 --- a/src/resources/components/CombineSearcher/CombineSearcher.vue +++ b/src/resources/components/CombineSearcher/CombineSearcher.vue @@ -7,7 +7,7 @@ :key="tindex" :name="tindex" :fade="false" - class="tag-item-text border-color radius-sm overflow bg-op" + class="tag-item-text border-base radius-sm overflow bg-op" > {{ getLabel(tindex) }} : @@ -745,7 +745,6 @@ export default { display: none; } .tag-item-text{ - border: 1px dashed; padding: 0 16px; line-height: 30px; display: inline-block; diff --git a/src/views/pages/autoexec/components/common/targetView/target-filter.vue b/src/views/pages/autoexec/components/common/targetView/target-filter.vue index 25c53725..e8100731 100644 --- a/src/views/pages/autoexec/components/common/targetView/target-filter.vue +++ b/src/views/pages/autoexec/components/common/targetView/target-filter.vue @@ -1,14 +1,14 @@
@@ -317,7 +317,7 @@ export default { }, preCondition: { type: 'slot', - label: '前置过滤器' + label: this.$t('term.autoexec.precondition') } }, executeConfig: { diff --git a/src/views/pages/autoexec/detail/runner-detail.vue b/src/views/pages/autoexec/detail/runner-detail.vue index 6a76ecf5..8e2769e6 100644 --- a/src/views/pages/autoexec/detail/runner-detail.vue +++ b/src/views/pages/autoexec/detail/runner-detail.vue @@ -60,7 +60,7 @@
@@ -74,7 +74,7 @@
@@ -88,7 +88,7 @@
@@ -154,8 +154,8 @@
@@ -85,8 +85,8 @@ {{ $t('term.autoexec.executetarget') }}
- +
+ + + @@ -278,6 +288,7 @@ export default { ExpiredReasonAlert: () => import('@/views/pages/autoexec/quick-service/service-catalog/expired-reason-alert'), // 服务失效原因提示列表 RunnerGroupSetting: () => import('@/views/pages/autoexec/detail/actionDetail/runnergroup-setting.vue'), RunnerGroupTagSetting: () => import('@/views/pages/autoexec/detail/actionDetail/runnergrouptag-setting.vue'), + FilterSearch: () => import('@/views/pages/autoexec/components/common/filter-search.vue'), ...Component }, mixins: [serviceMixin], diff --git a/src/views/pages/autoexec/quick-service/service-catalog/other-params.vue b/src/views/pages/autoexec/quick-service/service-catalog/other-params.vue index 03cdb41f..dc00af33 100644 --- a/src/views/pages/autoexec/quick-service/service-catalog/other-params.vue +++ b/src/views/pages/autoexec/quick-service/service-catalog/other-params.vue @@ -125,6 +125,15 @@
+ + + import('@/views/pages/autoexec/detail/runnerDetail/add-target.vue'), RunnerGroupSetting: () => import('@/views/pages/autoexec/detail/actionDetail/runnergroup-setting.vue'), RunnerGroupTagSetting: () => import('@/views/pages/autoexec/detail/actionDetail/runnergrouptag-setting.vue'), + FilterSearch: () => import('@/views/pages/autoexec/components/common/filter-search.vue'), ...Component }, props: { diff --git a/src/views/pages/cmdb/asset/advanced-mode-search.vue b/src/views/pages/cmdb/asset/advanced-mode-search.vue index 389fa91b..1837d887 100644 --- a/src/views/pages/cmdb/asset/advanced-mode-search.vue +++ b/src/views/pages/cmdb/asset/advanced-mode-search.vue @@ -8,7 +8,7 @@ {{ item.label }} : @@ -927,7 +927,6 @@ export default { white-space: nowrap; overflow: hidden; .tag-item-text{ - border: 1px dashed; padding: 0 16px; line-height: 30px; display: inline-block; diff --git a/src/views/pages/process/flow/flowedit/components/createjob/createjob-config.vue b/src/views/pages/process/flow/flowedit/components/createjob/createjob-config.vue index d4a463d4..57c218bb 100644 --- a/src/views/pages/process/flow/flowedit/components/createjob/createjob-config.vue +++ b/src/views/pages/process/flow/flowedit/components/createjob/createjob-config.vue @@ -318,11 +318,10 @@ export default { isRequired: item.isRequired, key: item.key, mappingMode: item.mappingMode, - name: item.name + name: item.name, + value: item.value }; - if (item.mappingMode === 'constant' || item.mappingMode === 'runtimeparam') { - obj.value = item.value; - } else { + if (item.mappingMode !== 'constant' && item.mappingMode !== 'runtimeparam') { obj.mappingList = [{ mappingMode: '', value: '', diff --git a/src/views/pages/process/flow/flowedit/components/createjob/params/execute-param.vue b/src/views/pages/process/flow/flowedit/components/createjob/params/execute-param.vue index bfbb6e95..77f80da5 100644 --- a/src/views/pages/process/flow/flowedit/components/createjob/params/execute-param.vue +++ b/src/views/pages/process/flow/flowedit/components/createjob/params/execute-param.vue @@ -17,10 +17,19 @@
- +
@@ -362,7 +362,7 @@ export default { this.executeConfig[key] = this.config.config.executeConfig[key]; } }); - this.preCondition = !this.$utils.isEmpty(this.globalPreCondition) ? this.$utils.deepClone(this.executeConfig.preCondition) : null; + this.preCondition = !this.$utils.isEmpty(this.executeConfig.preCondition) ? this.$utils.deepClone(this.executeConfig.preCondition) : null; if (!this.$utils.isEmpty(this.executeConfig.runnerGroup) || !this.$utils.isEmpty(this.executeConfig.runnerGroupTag)) { this.$set(this.executeConfig, 'isPresetRunnerGroup', 1); } @@ -509,7 +509,10 @@ export default { }, async ok() { this.isValid = false; - (this.editConfig.execMode != 'runner') && (await this.validSetting(true)); + if (!this.$refs.targetDetail || (this.$refs.targetDetail && !this.$refs.targetDetail.valid())) { + return; + } + // (this.editConfig.execMode != 'runner') && (await this.validSetting(true)); //废弃接口校验规则 if (this.isValid) { return; } else { -- Gitee From 907f84e4f8393def625f2254f36bc32e9949f203 Mon Sep 17 00:00:00 2001 From: dengbf Date: Mon, 8 Sep 2025 12:26:30 +0800 Subject: [PATCH 12/21] commit --- src/views/pages/autoexec/detail/action-detail.vue | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/views/pages/autoexec/detail/action-detail.vue b/src/views/pages/autoexec/detail/action-detail.vue index ebca4b64..d0134f1f 100644 --- a/src/views/pages/autoexec/detail/action-detail.vue +++ b/src/views/pages/autoexec/detail/action-detail.vue @@ -126,7 +126,7 @@ :canEdit="effectiveEditable && operationType == 'combop' ? true : false" :execModeList="execModeList" :runtimeParamList="runtimeParamList" - :globalPreCondition="executeConfig.preCondition" + :globalPreCondition="executeConfig?executeConfig.preCondition:null" @updateSort="updateSort" @change="changeSelectStep" > @@ -188,7 +188,7 @@ :currentGroupConfig="currentGroupConfig" :runtimeParamList="runtimeParamList" :canEdit="effectiveEditable && operationType == 'combop' ? true : false" - :globalPreCondition="executeConfig.preCondition" + :globalPreCondition="executeConfig?executeConfig.preCondition:null" @save="saveCurrentGroupConfig" >
-- Gitee From 9a77437bb4f5fcf2941354214564d6b61bbf0b78 Mon Sep 17 00:00:00 2001 From: dengbf Date: Mon, 8 Sep 2025 15:49:04 +0800 Subject: [PATCH 13/21] =?UTF-8?q?-=20[=E5=85=B3=E8=81=94]=20#[150081782202?= =?UTF-8?q?3680]=E8=87=AA=E5=8A=A8=E5=8C=96=E7=BB=84=E5=90=88=E5=B7=A5?= =?UTF-8?q?=E5=85=B7=E2=80=9C=E5=85=A8=E5=B1=80=E2=80=9C=E3=80=81=E2=80=9C?= =?UTF-8?q?=E9=98=B6=E6=AE=B5=E7=BB=84=E2=80=9D=E5=92=8C=E2=80=9C=E9=98=B6?= =?UTF-8?q?=E6=AE=B5=E2=80=9D=E9=83=BD=E6=94=AF=E6=8C=81=E9=80=89=E6=8B=A9?= =?UTF-8?q?=E6=89=A7=E8=A1=8C=E7=9B=AE=E6=A0=87=E6=94=AF=E6=8C=81=E2=80=9C?= =?UTF-8?q?=E5=89=8D=E7=BD=AE=E8=BF=87=E6=BB=A4=E5=99=A8=E2=80=9D=20http:/?= =?UTF-8?q?/192.168.0.96:8090/demo/rdm.html#/story-detail/939050947543040/?= =?UTF-8?q?939050947543042/1500817822023680?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../pages/autoexec/detail/runner-detail.vue | 26 +++++++++---------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/src/views/pages/autoexec/detail/runner-detail.vue b/src/views/pages/autoexec/detail/runner-detail.vue index 8e2769e6..6e95766c 100644 --- a/src/views/pages/autoexec/detail/runner-detail.vue +++ b/src/views/pages/autoexec/detail/runner-detail.vue @@ -151,19 +151,19 @@
{{ $t('term.autoexec.executetarget') }} -
- - - + + + +
Date: Mon, 8 Sep 2025 19:08:13 +0800 Subject: [PATCH 14/21] =?UTF-8?q?-=20[=E5=85=B3=E8=81=94]=20#[150081782202?= =?UTF-8?q?3680]=E8=87=AA=E5=8A=A8=E5=8C=96=E7=BB=84=E5=90=88=E5=B7=A5?= =?UTF-8?q?=E5=85=B7=E2=80=9C=E5=85=A8=E5=B1=80=E2=80=9C=E3=80=81=E2=80=9C?= =?UTF-8?q?=E9=98=B6=E6=AE=B5=E7=BB=84=E2=80=9D=E5=92=8C=E2=80=9C=E9=98=B6?= =?UTF-8?q?=E6=AE=B5=E2=80=9D=E9=83=BD=E6=94=AF=E6=8C=81=E9=80=89=E6=8B=A9?= =?UTF-8?q?=E6=89=A7=E8=A1=8C=E7=9B=AE=E6=A0=87=E6=94=AF=E6=8C=81=E2=80=9C?= =?UTF-8?q?=E5=89=8D=E7=BD=AE=E8=BF=87=E6=BB=A4=E5=99=A8=E2=80=9D=20http:/?= =?UTF-8?q?/192.168.0.96:8090/demo/rdm.html#/story-detail/939050947543040/?= =?UTF-8?q?939050947543042/1500817822023680?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../common/executionMode/filters.vue | 2 + .../detail/actionDetail/execute-setting.vue | 17 +-- .../actionDetail/precondition-detail.vue | 125 ++++++++++++++++++ .../detail/actionDetail/step-group.vue | 10 +- .../actionDetail/step/edit/step-edit.vue | 23 ++-- .../pages/autoexec/detail/runner-detail.vue | 9 +- .../quick-service/catalog/service.vue | 9 +- .../service-catalog/no-form-service-edit.vue | 8 +- .../service-catalog/other-params.vue | 10 +- .../createjob/params/execute-param.vue | 8 +- 10 files changed, 168 insertions(+), 53 deletions(-) create mode 100644 src/views/pages/autoexec/detail/actionDetail/precondition-detail.vue diff --git a/src/views/pages/autoexec/components/common/executionMode/filters.vue b/src/views/pages/autoexec/components/common/executionMode/filters.vue index 425a0107..bd0beca8 100644 --- a/src/views/pages/autoexec/components/common/executionMode/filters.vue +++ b/src/views/pages/autoexec/components/common/executionMode/filters.vue @@ -177,6 +177,7 @@ export default { } }, changeValue(val) { + this.$emit('change', val); this.complexModeSearchValue = {}; this.searchVal = this.$utils.deepClone(val); this.getDataList('currentPage', 1); @@ -190,6 +191,7 @@ export default { if (!this.$utils.isEmpty(this.preCondition)) { params.preCondition = this.preCondition; } + this.$emit('change', searchVal); this.$api.autoexec.action.getNodeList(params).then(res => { if (res.Status == 'OK') { this.tableData = res.Return; diff --git a/src/views/pages/autoexec/detail/actionDetail/execute-setting.vue b/src/views/pages/autoexec/detail/actionDetail/execute-setting.vue index e2df6b09..7dc7779a 100644 --- a/src/views/pages/autoexec/detail/actionDetail/execute-setting.vue +++ b/src/views/pages/autoexec/detail/actionDetail/execute-setting.vue @@ -48,14 +48,12 @@ @@ -117,7 +115,7 @@ export default { ExecuteuserSetting: () => import('./executeuser-setting.vue'), RunnerGroupSetting: () => import('./runnergroup-setting.vue'), RunnerGroupTagSetting: () => import('./runnergrouptag-setting.vue'), - FilterSearch: () => import('@/views/pages/autoexec/components/common/filter-search.vue') + PreconditionDetail: () => import('@/views/pages/autoexec/detail/actionDetail/precondition-detail.vue') }, filters: {}, props: { @@ -300,9 +298,7 @@ export default { this.$set(this.settingConfig, 'executeUser', this.$refs.executeUser.save()); this.$set(this.settingConfig, 'runnerGroup', this.$refs.runnerGroup.save()); this.$set(this.settingConfig, 'runnerGroupTag', this.$refs.runnerGroupTag.save()); - if (!this.$utils.isEmpty(this.preCondition)) { - this.$set(this.settingConfig, 'preCondition', this.preCondition); - } + this.$set(this.settingConfig, 'preCondition', !this.$utils.isEmpty(this.preCondition) ? this.preCondition : null); this.settingConfig.executeNodeConfig = {}; if (this.settingConfig.whenToSpecify == 'now') { @@ -401,6 +397,7 @@ export default { }); }, changePreConditionValue(val) { + console.log(val); this.preCondition = val; } }, diff --git a/src/views/pages/autoexec/detail/actionDetail/precondition-detail.vue b/src/views/pages/autoexec/detail/actionDetail/precondition-detail.vue new file mode 100644 index 00000000..f6b9ba84 --- /dev/null +++ b/src/views/pages/autoexec/detail/actionDetail/precondition-detail.vue @@ -0,0 +1,125 @@ + + + diff --git a/src/views/pages/autoexec/detail/actionDetail/step-group.vue b/src/views/pages/autoexec/detail/actionDetail/step-group.vue index 523d6a13..ff70f7b5 100644 --- a/src/views/pages/autoexec/detail/actionDetail/step-group.vue +++ b/src/views/pages/autoexec/detail/actionDetail/step-group.vue @@ -35,11 +35,10 @@ @@ -186,7 +184,7 @@ export default { ExecuteuserSetting: () => import('@/views/pages/autoexec/detail/actionDetail/executeuser-setting.vue'), RunnerGroupSetting: () => import('@/views/pages/autoexec/detail/actionDetail/runnergroup-setting.vue'), RunnerGroupTagSetting: () => import('@/views/pages/autoexec/detail/actionDetail/runnergrouptag-setting.vue'), - FilterSearch: () => import('@/views/pages/autoexec/components/common/filter-search.vue') + PreconditionDetail: () => import('@/views/pages/autoexec/detail/actionDetail/precondition-detail.vue') }, filters: {}, props: { @@ -507,17 +505,12 @@ export default { } }); }, - async ok() { - this.isValid = false; - if (!this.$refs.targetDetail || (this.$refs.targetDetail && !this.$refs.targetDetail.valid())) { + ok() { + if (!this.$utils.isEmpty(this.preCondition) && this.$refs.targetDetail && !this.$refs.targetDetail.valid()) { return; } // (this.editConfig.execMode != 'runner') && (await this.validSetting(true)); //废弃接口校验规则 - if (this.isValid) { - return; - } else { - this.confirmEdit(); - } + this.confirmEdit(); }, saveValid() { //校验完成,保存 this.confirmEdit(); diff --git a/src/views/pages/autoexec/detail/runner-detail.vue b/src/views/pages/autoexec/detail/runner-detail.vue index 6e95766c..603b8a6f 100644 --- a/src/views/pages/autoexec/detail/runner-detail.vue +++ b/src/views/pages/autoexec/detail/runner-detail.vue @@ -157,11 +157,10 @@ :labelWidth="110" labelPosition="left" > - + :canEdit="false" + >
import('@/views/pages/autoexec/detail/actionDetail/executeuser-setting.vue'), RunnerGroupSetting: () => import('@/views/pages/autoexec/detail/actionDetail/runnergroup-setting.vue'), RunnerGroupTagSetting: () => import('@/views/pages/autoexec/detail/actionDetail/runnergrouptag-setting.vue'), - FilterSearch: () => import('@/views/pages/autoexec/components/common/filter-search.vue') + PreconditionDetail: () => import('@/views/pages/autoexec/detail/actionDetail/precondition-detail.vue') }, filters: {}, props: { diff --git a/src/views/pages/autoexec/quick-service/catalog/service.vue b/src/views/pages/autoexec/quick-service/catalog/service.vue index 8267a199..f81cd888 100644 --- a/src/views/pages/autoexec/quick-service/catalog/service.vue +++ b/src/views/pages/autoexec/quick-service/catalog/service.vue @@ -285,11 +285,10 @@
- + :canEdit="false" + >
@@ -512,7 +511,7 @@ export default { RunnerGroupSetting: () => import('@/views/pages/autoexec/detail/actionDetail/runnergroup-setting.vue'), RunnerGroupTagSetting: () => import('@/views/pages/autoexec/detail/actionDetail/runnergrouptag-setting.vue'), ExpiredReasonAlert: () => import('../service-catalog/expired-reason-alert'), // - FilterSearch: () => import('@/views/pages/autoexec/components/common/filter-search.vue'), + PreconditionDetail: () => import('@/views/pages/autoexec/detail/actionDetail/precondition-detail.vue'), ...Component }, mixins: [catalogmixin], diff --git a/src/views/pages/autoexec/quick-service/service-catalog/no-form-service-edit.vue b/src/views/pages/autoexec/quick-service/service-catalog/no-form-service-edit.vue index 9fd2e07e..d5508a03 100644 --- a/src/views/pages/autoexec/quick-service/service-catalog/no-form-service-edit.vue +++ b/src/views/pages/autoexec/quick-service/service-catalog/no-form-service-edit.vue @@ -162,10 +162,10 @@ v-if="executeConfig && executeConfig.preCondition" :label="$t('term.autoexec.precondition')" > - + :canEdit="false" + > import('@/views/pages/autoexec/quick-service/service-catalog/expired-reason-alert'), // 服务失效原因提示列表 RunnerGroupSetting: () => import('@/views/pages/autoexec/detail/actionDetail/runnergroup-setting.vue'), RunnerGroupTagSetting: () => import('@/views/pages/autoexec/detail/actionDetail/runnergrouptag-setting.vue'), - FilterSearch: () => import('@/views/pages/autoexec/components/common/filter-search.vue'), + PreconditionDetail: () => import('@/views/pages/autoexec/detail/actionDetail/precondition-detail.vue'), ...Component }, mixins: [serviceMixin], diff --git a/src/views/pages/autoexec/quick-service/service-catalog/other-params.vue b/src/views/pages/autoexec/quick-service/service-catalog/other-params.vue index dc00af33..98848593 100644 --- a/src/views/pages/autoexec/quick-service/service-catalog/other-params.vue +++ b/src/views/pages/autoexec/quick-service/service-catalog/other-params.vue @@ -129,10 +129,10 @@ v-if="executeConfig && executeConfig.preCondition" :label="$t('term.autoexec.precondition')" > - + import('@/views/pages/autoexec/detail/runnerDetail/add-target.vue'), RunnerGroupSetting: () => import('@/views/pages/autoexec/detail/actionDetail/runnergroup-setting.vue'), RunnerGroupTagSetting: () => import('@/views/pages/autoexec/detail/actionDetail/runnergrouptag-setting.vue'), - FilterSearch: () => import('@/views/pages/autoexec/components/common/filter-search.vue'), + PreconditionDetail: () => import('@/views/pages/autoexec/detail/actionDetail/precondition-detail.vue'), ...Component }, props: { diff --git a/src/views/pages/process/flow/flowedit/components/createjob/params/execute-param.vue b/src/views/pages/process/flow/flowedit/components/createjob/params/execute-param.vue index 77f80da5..a49b45e3 100644 --- a/src/views/pages/process/flow/flowedit/components/createjob/params/execute-param.vue +++ b/src/views/pages/process/flow/flowedit/components/createjob/params/execute-param.vue @@ -23,10 +23,10 @@ :label="item.name" labelPosition="left" > - + :canEdit="false" + > import('@/views/pages/autoexec/form/component/formresoureces/index.vue'), ProtocolReadonly: () => import('./protocol-readonly'), TsFormRadio: () => import('@/resources/plugins/TsForm/TsFormRadio'), - FilterSearch: () => import('@/views/pages/autoexec/components/common/filter-search.vue') + PreconditionDetail: () => import('@/views/pages/autoexec/detail/actionDetail/precondition-detail.vue') }, props: { allFormitemList: Array, -- Gitee From c23be2d4142164fd03b4e107ce5bad41d8076a98 Mon Sep 17 00:00:00 2001 From: dengbf Date: Tue, 9 Sep 2025 14:48:59 +0800 Subject: [PATCH 15/21] =?UTF-8?q?-=20[=E5=85=B3=E8=81=94]=20#[150081782202?= =?UTF-8?q?3680]=E8=87=AA=E5=8A=A8=E5=8C=96=E7=BB=84=E5=90=88=E5=B7=A5?= =?UTF-8?q?=E5=85=B7=E2=80=9C=E5=85=A8=E5=B1=80=E2=80=9C=E3=80=81=E2=80=9C?= =?UTF-8?q?=E9=98=B6=E6=AE=B5=E7=BB=84=E2=80=9D=E5=92=8C=E2=80=9C=E9=98=B6?= =?UTF-8?q?=E6=AE=B5=E2=80=9D=E9=83=BD=E6=94=AF=E6=8C=81=E9=80=89=E6=8B=A9?= =?UTF-8?q?=E6=89=A7=E8=A1=8C=E7=9B=AE=E6=A0=87=E6=94=AF=E6=8C=81=E2=80=9C?= =?UTF-8?q?=E5=89=8D=E7=BD=AE=E8=BF=87=E6=BB=A4=E5=99=A8=E2=80=9D=20http:/?= =?UTF-8?q?/192.168.0.96:8090/demo/rdm.html#/story-detail/939050947543040/?= =?UTF-8?q?939050947543042/1500817822023680?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../pages/autoexec/detail/actionDetail/execute-setting.vue | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/views/pages/autoexec/detail/actionDetail/execute-setting.vue b/src/views/pages/autoexec/detail/actionDetail/execute-setting.vue index 7dc7779a..71d8b119 100644 --- a/src/views/pages/autoexec/detail/actionDetail/execute-setting.vue +++ b/src/views/pages/autoexec/detail/actionDetail/execute-setting.vue @@ -47,11 +47,11 @@