From f756e12e7197defd8a13d705f772634ff6b60631 Mon Sep 17 00:00:00 2001 From: xiepeng Date: Fri, 10 May 2024 17:53:18 +0800 Subject: [PATCH] =?UTF-8?q?BUG=E4=BC=98=E5=8C=96=20=E8=A1=8C=E8=BD=A6=20?= =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E6=89=BF=E8=AF=BA=E9=80=89=E9=A1=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../driving-item-check-list.vue | 14 +-- .../driving-item-detail.vue | 61 ++++++++-- .../driving-inspections/driving-item-list.vue | 106 ++++++++++++++---- 3 files changed, 137 insertions(+), 44 deletions(-) diff --git a/pages/application/driving-inspections/driving-item-check-list.vue b/pages/application/driving-inspections/driving-item-check-list.vue index fec0125..90e5de4 100644 --- a/pages/application/driving-inspections/driving-item-check-list.vue +++ b/pages/application/driving-inspections/driving-item-check-list.vue @@ -61,7 +61,7 @@ - + @@ -83,7 +83,7 @@ - + 实时照片 *照片说明:车辆正前方、左右两侧45°角及车尾部拍照 @@ -629,8 +629,6 @@ formData.WAYBILLSTATUS = 1 } else if (this.CHECKTYPE_NAME == "收车后") { formData.WAYBILLSTATUS = 2 - }else if (this.CHECKTYPE_NAME == "待承诺"){ - formData.WAYBILLSTATUS = 3 } formData.WAYBILLREGISTRATION_ID = this.WAYBILLREGISTRATION_ID console.log(JSON.stringify(this.list)) @@ -681,12 +679,8 @@ return item.filePath }).join(",") formData.checklist = JSON.stringify(this.promiseList) - if (this.CHECKTYPE_NAME == "出车前" || this.CHECKTYPE_NAME == "行车中") { - formData.WAYBILLSTATUS = 1 - } else if (this.CHECKTYPE_NAME == "收车后") { - formData.WAYBILLSTATUS = 2 - }else if (this.CHECKTYPE_NAME == "待承诺"){ - formData.WAYBILLSTATUS = 3 + if (this.CHECKTYPE_NAME == "待承诺"){ + formData.WAYBILLSTATUS = 0 } formData.WAYBILLREGISTRATION_ID = this.WAYBILLREGISTRATION_ID console.log(JSON.stringify(this.list)) diff --git a/pages/application/driving-inspections/driving-item-detail.vue b/pages/application/driving-inspections/driving-item-detail.vue index 2dd311b..99970f7 100644 --- a/pages/application/driving-inspections/driving-item-detail.vue +++ b/pages/application/driving-inspections/driving-item-detail.vue @@ -97,7 +97,7 @@ - + 排查项 - + + + 行车安全问询: + + + + 承诺项: + + + {{ item2.INQUIRYCONTENT }} + + + 承诺说明: + + + {{ item2.REMARK?item2.REMARK:'无' }} + + + 是否合格: + + {{item2.STATUS === '0'? "合格":item2.STATUS === '1'?"不合格": "不涉及"}} + + + + + 检查人签字 + + + + + {{item1.SIGN_TIME}} + + + + + + + {{item.CHECKTYPE_NAME}}检查: @@ -129,11 +167,15 @@ 出车说明: {{item2.REMARK?item2.REMARK:'无'}} - + + 是否合格: + + {{item2.STATUS === '0'? "合格":"不合格"}} + - - + + 检查图片 @@ -160,11 +202,8 @@ - - - @@ -187,6 +226,7 @@ hs: [], files: [], list:[], + list2:[], commitmentList:[], videoList: [], checkList: [], @@ -238,7 +278,8 @@ _this.pd = res.data.pd; //参数map _this.commitmentList = res.data.commitmentList; //参数map _this.list = res.data.pd.varList - + _this.list2 = res.data.pd.varList2 + console.log(_this.list2) } else if ("exception" == data.result) { uni.showToast({ title: '错误', diff --git a/pages/application/driving-inspections/driving-item-list.vue b/pages/application/driving-inspections/driving-item-list.vue index e1cf023..0c9319c 100644 --- a/pages/application/driving-inspections/driving-item-list.vue +++ b/pages/application/driving-inspections/driving-item-list.vue @@ -13,7 +13,7 @@ 'CHECKTYPE_NAME':item.CHECKTYPE_NAME, 'WAYBILLREGISTRATION_ID':WAYBILLREGISTRATION_ID,index})"> - + @@ -104,35 +104,93 @@ }, //跳转事件 goToList(e) { - const index = e.index - const WAYBILLSTATUS = this.pd.WAYBILLSTATUS - if((this.pd.WAYBILLSTATUS === '1' || this.pd.WAYBILLSTATUS === '2' || this.pd.IsExist != '0') && index === 1){ - uni.showModal({ - title: '提示', - cancelText: '确认', - confirmText: '取消', - content:'您已经完成出车前检查,无需再次检查', - }); - return; - }else if((this.pd.WAYBILLSTATUS === '2' || this.pd.IsExist == '1' || this.pd.IsExist == '0') && index === 2){ - if(this.pd.WAYBILLSTATUS === '0') { + const index = e.index + console.log(this.pd) + if ((this.pd.WAYBILLSTATUS === '3' || this.pd.IsExist == '0') && index === 1) { + uni.showModal({ + title: '提示', + cancelText: '确认', + confirmText: '取消', + content: '未进行出车前安全承诺,无法进行此操作', + }); + return; + }else if ((this.pd.WAYBILLSTATUS === '0' || this.pd.IsExist == '0') && index === 2) { + uni.showModal({ + title: '提示', + cancelText: '确认', + confirmText: '取消', + content: '未进行出车前检查,无法进行此操作', + }); + return; + }else if ((this.pd.WAYBILLSTATUS === '0' || this.pd.WAYBILLSTATUS === '1' || this.pd.WAYBILLSTATUS === '2') && index === 0) { + uni.showModal({ + title: '提示', + cancelText: '确认', + confirmText: '取消', + content: '您已经完成出车前安全承诺,无需再次承诺', + }); + return; + }else if ((this.pd.WAYBILLSTATUS === '1' || this.pd.WAYBILLSTATUS === '2' || this.pd.WAYBILLSTATUS === '2') && index === 1) { + uni.showModal({ + title: '提示', + cancelText: '确认', + confirmText: '取消', + content: '您已经完成出车前检查,无需再次检查', + }); + return; + }else if ((this.pd.WAYBILLSTATUS === '2') && index === 2) { + uni.showModal({ + title: '提示', + cancelText: '确认', + confirmText: '取消', + content: '您已经完成行车中检查,无需再次检查', + }); + return; + }else if ((this.pd.WAYBILLSTATUS === '0') && index === 3) { + uni.showModal({ + title: '提示', + cancelText: '确认', + confirmText: '取消', + content: '您未进行行车中检查,请按顺序检查', + }); + return; + }else if ((this.pd.WAYBILLSTATUS === '3') && index === 3) { + uni.showModal({ + title: '提示', + cancelText: '确认', + confirmText: '取消', + content: '您未进行行车中检查,请按顺序检查', + }); + return; + } + + /* if ((this.pd.WAYBILLSTATUS === '2' || this.pd.WAYBILLSTATUS === '3' || this.pd.IsExist != '0') && index === 1) { + uni.showModal({ + title: '提示', + cancelText: '确认', + confirmText: '取消', + content: '您已经完成出车前检查,无需再次检查', + }); + return; + } else if ((this.pd.WAYBILLSTATUS === '2' || this.pd.IsExist == '1' || this.pd.IsExist == '0') && index === 2) { + if (this.pd.WAYBILLSTATUS === '0') { uni.showModal({ title: '提示', - content:'未进行出车前检查,无法进行此操作', + content: '未进行出车前检查,无法进行此操作', showCancel: false, confirmText: '确认' }); } - return - }else if((this.pd.WAYBILLSTATUS === '2' || this.pd.IsExist == '2' || this.pd.IsExist == '0') && index === 3){ - uni.showModal({ - title: '提示', - cancelText: '确认', - confirmText: '取消', - content:'您未进行行车中检查,请按顺序检查', - }); - return; - } + return + } else if ((this.pd.WAYBILLSTATUS === '2' || this.pd.IsExist == '2' || this.pd.IsExist == '0') && index === 3) { + uni.showModal({ + title: '提示', + cancelText: '确认', + confirmText: '取消', + content: '您未进行行车中检查,请按顺序检查', + }); + return; + }*/ uni.navigateTo({ url: '/pages/application/driving-inspections/driving-item-check-list?CHECKTYPE_ID=' + e.CHECKTYPE_ID + '&CHECKTYPE_NAME=' + e.CHECKTYPE_NAME + '&WAYBILLREGISTRATION_ID=' + e.WAYBILLREGISTRATION_ID