From d53d5c89eac2d8f3ce6de1b9a9373d304b3790ad Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=AE=8B=E4=BC=9F=E4=BD=B3?= <2797716443@qq.com> Date: Wed, 25 Aug 2021 14:49:54 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B8=85=E5=8D=95=E6=B5=81=E7=A8=8B=E4=BF=AE?= =?UTF-8?q?=E6=94=B9bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../pages/creatProcess/bzqdfb/step1.vue | 50 ++++++++++++------- 1 file changed, 32 insertions(+), 18 deletions(-) diff --git a/src/pages/processCenter/pages/creatProcess/bzqdfb/step1.vue b/src/pages/processCenter/pages/creatProcess/bzqdfb/step1.vue index 8864b3131..a391d8d4e 100644 --- a/src/pages/processCenter/pages/creatProcess/bzqdfb/step1.vue +++ b/src/pages/processCenter/pages/creatProcess/bzqdfb/step1.vue @@ -131,20 +131,20 @@ @@ -822,14 +822,14 @@ export default { code: "", //标准号 standName: "", //标准名称 issueTime: "", //发布日期 - XCXSSRQ: "", //新车型实施日期 - ZCCSSRQ: "", //在产车实施日期 + xcxssrqgj: "", //新车型实施日期 + zccssrqgj: "", //在产车实施日期 textStatus: "", //文本状态 id: "" }] }, choiceForm: {}, //选择标准清单列表 - // countryOptions: [], //适用区域下拉框数据 + countryOptions: [], //国家地区 standStateOptions: [], standardTypeOptions: [ { @@ -963,7 +963,22 @@ export default { }, { _this: this }, res => { - this.sarAccessListDatas = res.data.records; + let arr = res.data.records; + //国家地区字段转换 + arr.forEach(item => { + if (item.countryArea !== null || item.countryArea !== "") { + let k = (item.countryArea || "").split(',') + for (let i in this.countryOptions) { + for (let m = 0; m < k.length; m++) { + if (this.countryOptions[i].value === k[m]) { + k[m] = this.countryOptions[i].label + } + item.countryAreaShow = k.join(',') + } + } + } + }) + this.sarAccessListDatas = arr; this.total = res.data.total; }, e => { }); @@ -1292,15 +1307,14 @@ export default { } this.dataList = res.data.records; this.dataList.forEach(item => { - if (item.xcxssrqgj === null){ - this.$set(item, "XCXSSRQ", ''); - this.$set(item, "ZCCSSRQ", ''); - }else{ - this.$set(item, "XCXSSRQ", item.xcxssrqgj); - this.$set(item, "ZCCSSRQ", item.zccssrqgj); - } + if(item.xcxssrqgj === 'undefined'){ + item.xcxssrqgj = '' + } + if(item.zccssrqgj === 'undefined'){ + item.zccssrqgj = '' + } }) - this.listForm.dataList = res.data.records; + this.listForm.dataList = this.dataList; let formId = []; this.dataList.map(item => { formId.push(item.id); @@ -1402,7 +1416,7 @@ export default { _this: this }, res => { this.energyKindOptions = res.data.ENERGYTYPES //适用车型 - this.countryOptions = res.data.COUNTRY; + this.countryOptions = res.data.COUNTRY; //国家/地区 this.standStateOptions = res.data.WBZTCLASS; // 文本状态 this.setMap(this.standStateOptions); });