From e07ce3a07199dbdf6013484e395134306c600293 Mon Sep 17 00:00:00 2001 From: lideqin <694785430@qq.com> Date: Thu, 4 Jul 2024 10:06:05 +0800 Subject: [PATCH] =?UTF-8?q?[update]=20=E5=B8=82=E5=9C=BA=E6=B3=95=E8=A7=84?= =?UTF-8?q?=E6=B8=85=E5=8D=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../MarketRegulationsFormPage.vue | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) diff --git a/src/views/standardRegulationLibrary/marketRegulationsList/MarketRegulationsFormPage.vue b/src/views/standardRegulationLibrary/marketRegulationsList/MarketRegulationsFormPage.vue index f4a1128..c39925a 100644 --- a/src/views/standardRegulationLibrary/marketRegulationsList/MarketRegulationsFormPage.vue +++ b/src/views/standardRegulationLibrary/marketRegulationsList/MarketRegulationsFormPage.vue @@ -512,13 +512,16 @@ export default { getMarketRegulationListById(param).then(res => { if (res.success) { this.model = Object.assign({}, res.result) - const uid = uidGenerator() - this.dataSource = JSON.parse(JSON.stringify(this.model.lists.map(item => { - return { ...item, uid } - }))) - this.dataList = JSON.parse(JSON.stringify(this.model.lists.map(item => { - return { ...item, uid } - }))) + if (this.model.manifest.country) { + this.model.manifest.country = this.model.manifest.country.split(',').map(item => { + return { value: item } + }) + } + for (const item of this.model.lists) { + const uid = uidGenerator() + this.dataSource.push({ ...item, uid }) + this.dataList.push({ ...item, uid }) + } this.$nextTick(() => { this.form.setFieldsValue(pick(this.model.manifest, 'country', 'manifestNo', 'customName', 'drivePosition', 'securityLevel', 'manifestDesc', 'file')) })