From c4c73f2a2693338de0153c19bd980f4f7d8ad56a Mon Sep 17 00:00:00 2001 From: "zyx.net" Date: Sun, 2 Apr 2023 18:24:54 +0800 Subject: [PATCH 1/4] =?UTF-8?q?ota=E6=95=B0=E6=8D=AE=E5=AF=BC=E5=85=A5?= =?UTF-8?q?=E6=A8=A1=E6=9D=BF=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/upgradetargetmodel.vue | 29 ++++++++++--------- .../components/basicInformation.vue | 19 ++++++++---- 2 files changed, 28 insertions(+), 20 deletions(-) diff --git a/jero-web/src/views/otamanagement/upgradeactivityrecord/components/upgradetargetmodel.vue b/jero-web/src/views/otamanagement/upgradeactivityrecord/components/upgradetargetmodel.vue index 59f30073b..9fdff1a08 100644 --- a/jero-web/src/views/otamanagement/upgradeactivityrecord/components/upgradetargetmodel.vue +++ b/jero-web/src/views/otamanagement/upgradeactivityrecord/components/upgradetargetmodel.vue @@ -176,7 +176,8 @@ export default { disabled: false, form: { qymc: '安徽江淮汽车集团股份有限公司', - bapc: undefined + bapc: undefined, + cxmb: undefined }, url: { exportData: '/ota/otaBaSjSjmbcx/exportData', @@ -206,7 +207,7 @@ export default { handleModule() { downloadFile('ota/otaBaSjSjmbcx/exportTemplate', '升级目标车型' + '.zip', {}) }, - getData() { + getData(item) { let otaIdT = localStorage.getItem('otaIdT') if (otaIdT == null) { otaIdT = '' @@ -232,15 +233,15 @@ export default { this.form = res.result this.form.otaId='' - // if (this.$route.query.type == 1 && res.result.cxmb == null) { - // this.form.cxmb = this.form.babh + '-' + this.form.bapc + '-' + this.form.cpxh - // } else { - // if (this.$route.query.type == 2 && res.result.cxmb == null) { - // this.form.cxmb = this.form.babh + '-' + this.form.bapc + '-' + this.form.cpxh - // } else { - // this.form.cxmb = res.result.cxmb ? res.result.cxmb : undefined - // } - // } + if (this.$route.query.type == 1 && res.result.cxmb == null && !item) { + this.form.cxmb = this.form.babh + '-' + this.form.bapc + '-' + this.form.cpxh + } else { + if (this.$route.query.type == 2 && res.result.cxmb == null && !item) { + this.form.cxmb = this.form.babh + '-' + this.form.bapc + '-' + this.form.cpxh + } else { + this.form.cxmb = res.result.cxmb ? res.result.cxmb : undefined + } + } if (res.result.dllx1 == null || res.result.dllx1 == "") { this.form.dllx1 = undefined @@ -249,9 +250,9 @@ export default { if (res.result.dllx2 == null || res.result.dllx2 == "") { this.form.dllx2 = undefined } - if (res.result.cxmb == null || res.result.cxmb == "") { - this.form.cxmb = undefined - } + // if (res.result.cxmb == null || res.result.cxmb == "") { + // this.form.cxmb = undefined + // } if (res.result.bapc == null || res.result.bapc == "") { this.form.bapc = undefined } diff --git a/jero-web/src/views/otamanagement/vehicleinformation/components/basicInformation.vue b/jero-web/src/views/otamanagement/vehicleinformation/components/basicInformation.vue index 15b86d0c6..69c67a94f 100644 --- a/jero-web/src/views/otamanagement/vehicleinformation/components/basicInformation.vue +++ b/jero-web/src/views/otamanagement/vehicleinformation/components/basicInformation.vue @@ -241,6 +241,7 @@ import { message } from 'ant-design-vue' formInline:{}, projectNameList:[], formRules:[], + flag:'', url: { exportData: '/ota/otaBaCxJbxx/exportData', importZipUrl: '/ota/otaBaCxJbxx/importData?otaId=' + localStorage.getItem('otaId'),//导入 @@ -310,7 +311,7 @@ import { message } from 'ant-design-vue' } }) }, - getData(){ + getData(item){ let otaIdT=localStorage.getItem('otaIdT') if(otaIdT==null){ otaIdT='' @@ -332,10 +333,10 @@ import { message } from 'ant-design-vue' this.form.txzd=res.result.txzd this.form.cdotasj=res.result.cdotasj this.form.id=res.result.id - if(this.$route.query.type == 1 && res.result.cxmb == null){ + if(this.$route.query.type == 1 && res.result.cxmb == null && !item){ this.form.cxmb = this.form.djbh+'-'+ this.form.ggpc+'-'+this.form.cpxh }else { - if(this.$route.query.type == 2 && res.result.cxmb == null){ + if(this.$route.query.type == 2 && res.result.cxmb == null && !item){ this.form.cxmb = this.form.djbh+'-'+ this.form.ggpc+'-'+this.form.cpxh }else{ this.form.cxmb = res.result.cxmb ? res.result.cxmb : undefined @@ -370,6 +371,9 @@ import { message } from 'ant-design-vue' if(valid){ this.save() setTimeout(()=>{ + if(this.flag == 1){ + return + } this.$emit('basicInformationForm') },1000) @@ -385,11 +389,14 @@ import { message } from 'ant-design-vue' otaId='' } postAction('/ota/otaBaCxJbxx/add',{ otaId:otaId,...this.form}).then( res => { - if(res.code == 200){ + if(res.success){ localStorage.setItem('otaId', res.result.otaId) - this.$message.success(this.$t('SavedSuccessfully')) + this.$message.success(res.message) this.getData() - } + }else{ + this.$message.warning(res.message) + this.flag = 1 + } }) } }) From 68123779cf924dbb6eaeaf0137aca2fdc929bef8 Mon Sep 17 00:00:00 2001 From: "zyx.net" Date: Sun, 2 Apr 2023 18:38:15 +0800 Subject: [PATCH 2/4] =?UTF-8?q?=E5=AF=BC=E5=85=A5=E6=88=90=E5=8A=9F?= =?UTF-8?q?=E5=8A=A0=E6=8F=90=E7=A4=BA=E8=AF=AD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/components/ImportFileData/index.vue | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/jero-web/src/components/ImportFileData/index.vue b/jero-web/src/components/ImportFileData/index.vue index 23e53b99c..d2126df9b 100644 --- a/jero-web/src/components/ImportFileData/index.vue +++ b/jero-web/src/components/ImportFileData/index.vue @@ -120,6 +120,25 @@ }) } else { if (this.isTrue) { + let {message} = info.file.response + let {name} = info.file + let content = [] + if (message) { + message = message.split('
') + message.forEach(res => { + if (res) { + content.push( < div > {res} < /div>) + } + }) + } + this.$warning({ + title: name, + content: ( + < div > + {content} + < /div> + ) + }) if(info.file.response.result != null && info.file.response.result.otaId){ localStorage.setItem('otaId', info.file.response.result.otaId) } From 72d21e3606073f08ac0f75fba3c333902d81e930 Mon Sep 17 00:00:00 2001 From: "zyx.net" Date: Sun, 2 Apr 2023 18:52:41 +0800 Subject: [PATCH 3/4] =?UTF-8?q?=E5=8E=BB=E6=8E=89=E8=BD=A6=E7=AB=AFOTA?= =?UTF-8?q?=E5=8D=87=E7=BA=A7=E5=8A=9F=E8=83=BD=E6=A8=A1=E5=9D=97=E9=BB=98?= =?UTF-8?q?=E8=AE=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../vehicleinformation/components/recordparameters.vue | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/jero-web/src/views/otamanagement/vehicleinformation/components/recordparameters.vue b/jero-web/src/views/otamanagement/vehicleinformation/components/recordparameters.vue index 8b14c8175..40ce2ea96 100644 --- a/jero-web/src/views/otamanagement/vehicleinformation/components/recordparameters.vue +++ b/jero-web/src/views/otamanagement/vehicleinformation/components/recordparameters.vue @@ -766,7 +766,7 @@ export default { queryParam: {}, dataSourceList: [ { - bjmc:'车端OTA升级功能模块' + bjmc:'' } ], columns: [ @@ -878,7 +878,7 @@ export default { if(res.result.kzq.length == 0){ this.dataSourceList=[ { - bjmc:'车端OTA升级功能模块' + bjmc:'' } ] }else{ @@ -981,7 +981,7 @@ export default { }, addlineAtBot(){ let obj={} - obj.bjmc='车端OTA升级功能模块' + obj.bjmc='' this.dataSourceList.push(obj) this.$forceUpdate() }, From 3adec5dd80b44b828277037e186a6881910db7a3 Mon Sep 17 00:00:00 2001 From: "zyx.net" Date: Sun, 2 Apr 2023 19:17:09 +0800 Subject: [PATCH 4/4] =?UTF-8?q?=E5=8D=87=E7=BA=A7=E8=BD=A6=E5=9E=8BOTAId?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/upgradetargetmodel.vue | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/jero-web/src/views/otamanagement/upgradeactivityrecord/components/upgradetargetmodel.vue b/jero-web/src/views/otamanagement/upgradeactivityrecord/components/upgradetargetmodel.vue index 9fdff1a08..19e6f6876 100644 --- a/jero-web/src/views/otamanagement/upgradeactivityrecord/components/upgradetargetmodel.vue +++ b/jero-web/src/views/otamanagement/upgradeactivityrecord/components/upgradetargetmodel.vue @@ -266,14 +266,15 @@ export default { this.$refs.ruleForm.validate(valid => { if (valid) { let otaId = localStorage.getItem('otaId') - if (otaId == null|| otaId == undefined) { - otaId = '' - } + if (otaId == null || otaId == undefined) { + otaId = '' + } this.selectListPc.map(item => { if (item.id == this.form.bapc) { this.form.bapc = item.ggpc } }) + this.form.otaId = otaId postAction('/ota/otaBaSjSjmbcx/add', { otaId: otaId, ...this.form }).then(res => { if (res.code == 200) { localStorage.setItem('otaId', res.result.otaId)