From aaf22492d0a31aedd43e0996c91b36983ab0217c Mon Sep 17 00:00:00 2001 From: dengbf Date: Mon, 9 Jun 2025 14:25:40 +0800 Subject: [PATCH] =?UTF-8?q?[=E5=85=B3=E8=81=94]=20#[1439774500421632]?= =?UTF-8?q?=E4=B8=80=E9=94=AE=E5=8F=91=E5=B8=83=E4=BD=9C=E4=B8=9A=EF=BC=9A?= =?UTF-8?q?=E5=AE=9E=E4=BE=8B=E7=AD=9B=E9=80=89=E5=A2=9E=E5=8A=A0=E6=90=9C?= =?UTF-8?q?=E7=B4=A2IP=20http://192.168.0.96:8090/demo/rdm.html#/story-det?= =?UTF-8?q?ail/939050947543040/939050947543042/1439774500421632?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../publishing/module/instance-setting.vue | 43 ++++++++++++++----- 1 file changed, 33 insertions(+), 10 deletions(-) diff --git a/src/views/pages/deploy/job/publishing/module/instance-setting.vue b/src/views/pages/deploy/job/publishing/module/instance-setting.vue index 17417325..c54dfa93 100644 --- a/src/views/pages/deploy/job/publishing/module/instance-setting.vue +++ b/src/views/pages/deploy/job/publishing/module/instance-setting.vue @@ -25,6 +25,17 @@ + + + + + + +
+
{{ $t('term.deploy.moduleenvnotinstance', {modulename: module.name, envname: envName}) }}
import('@/resources/components/TsCard/TsCard.vue'), - MoreInstanceDialog: () => import('./more-instance-dialog.vue') + MoreInstanceDialog: () => import('./more-instance-dialog.vue'), + InputSearcher: () => import('@/resources/components/InputSearcher/InputSearcher.vue') }, props: { disabled: { @@ -107,7 +120,9 @@ export default { isShowMoreDialog: false, tableData: {}, currentPage: 1, - instanceList: [] + instanceList: [], + keyword: '', + isHaveInitData: false //是否有初始数据 }; }, beforeCreate() {}, @@ -125,6 +140,7 @@ export default { methods: { initData() { this.instanceList = []; + this.isHaveInitData = false; if (this.module.instanceList && this.module.instanceList.length) { this.instanceList = this.module.instanceList.map(m => { return { @@ -142,19 +158,26 @@ export default { envId: this.envId, appModuleId: this.module.id, currentPage: currentPage || this.currentPage, - pageSize: 100 + pageSize: 100, + keyword: this.keyword }; currentPage && (this.currentPage = currentPage); this.$api.deploy.env.getInstanceList(data).then(res => { if (res.Status == 'OK') { this.tableData = res.Return; - if (isFirst && this.$utils.isEmpty(this.instanceList)) { - this.instanceList = this.tableData.tbodyList.map(m => { - return { - ...m, - isChecked: true - }; - }); + if (isFirst) { + if (!this.$utils.isEmpty(this.tableData.tbodyList)) { + this.isHaveInitData = true; + } + + if (this.$utils.isEmpty(this.instanceList)) { + this.instanceList = this.tableData.tbodyList.map(m => { + return { + ...m, + isChecked: true + }; + }); + } } this.tableData.tbodyList.forEach(i => { if (this.instanceList.find(ins => ins.id === i.id)) { -- Gitee