From 54494bb39958585da5a1edd95fa7f7f6a0adf7d0 Mon Sep 17 00:00:00 2001 From: qq787203167 <787203167@qq.com> Date: Tue, 1 Mar 2022 16:33:32 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E6=A0=87=E5=87=86=E9=80=89?= =?UTF-8?q?=E6=8B=A9=E7=9A=84=E5=9B=9E=E6=98=BE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- jero-web/src/components/Standardselection/index.vue | 10 ++++------ jero-web/src/components/libraryAddForm/index.vue | 6 +++--- 2 files changed, 7 insertions(+), 9 deletions(-) diff --git a/jero-web/src/components/Standardselection/index.vue b/jero-web/src/components/Standardselection/index.vue index 951eccf69..7daf147bf 100644 --- a/jero-web/src/components/Standardselection/index.vue +++ b/jero-web/src/components/Standardselection/index.vue @@ -60,7 +60,7 @@ components: { currencySearch }, - props: ['query', 'value', 'replace_standard_id'], + props: ['query', 'value', 'standard'], computed: { isDisabled() { if (this.query.db_field_name === 'replaced_standard') { @@ -110,7 +110,7 @@ standardClick() { this.visible = true this.queryParam = {} - this.replacePage(this.replace_standard_id) + this.replacePage() }, replacePage() { let query = { @@ -125,9 +125,7 @@ if (res.success) { this.dataList = res.result.records this.total = res.result.total - if (this.replace_standard_id) { - this.selectedRowKeys = this.replace_standard_id.split(',') - } + this.selectedRowKeys = this.standard[this.query.db_field_name + '_id'] ? this.standard[this.query.db_field_name + '_id'].split(',') : [] } else { this.dataList = [] } @@ -144,7 +142,7 @@ replace_standard_id.push(res.id) }) this.$emit('input', content.join(',')) - this.$emit('change', replace_standard_id.join(',')) + this.$emit('change',this.query.db_field_name,replace_standard_id.join(',')) this.visible = false }, indexclick(event) { diff --git a/jero-web/src/components/libraryAddForm/index.vue b/jero-web/src/components/libraryAddForm/index.vue index 2e8393dc5..e5e50e971 100644 --- a/jero-web/src/components/libraryAddForm/index.vue +++ b/jero-web/src/components/libraryAddForm/index.vue @@ -158,7 +158,7 @@ @@ -486,8 +486,8 @@ this.type = 'add' this.getForm() }, - StandardselectionChange(id) { - this.formInline.replace_standard_id = id + StandardselectionChange(value, id) { + this.formInline[value + '_id'] = id } } }