From 6ca60a9811ec5b0bee7193e973659df98c281eea Mon Sep 17 00:00:00 2001 From: donqi Date: Wed, 19 Apr 2023 23:40:19 +0800 Subject: [PATCH] ... --- common/js/request.js | 13 +++++----- pages/my/b-account-bind.vue | 13 ++++++---- pages/order-manage/order-manage.vue | 37 +++++++++++++++++++++++++---- pages/order-manage/serv-detail.vue | 24 ++++++++++++------- 4 files changed, 63 insertions(+), 24 deletions(-) diff --git a/common/js/request.js b/common/js/request.js index 0c881bf..fe35c53 100644 --- a/common/js/request.js +++ b/common/js/request.js @@ -36,22 +36,21 @@ export default { // console.log("停止触发"); // return false; }, - success(res) { + success(res) { + uni.hideLoading(); if (!res || !res.data || res.data.code !== 0) { uni.showToast({ - title: '系统开小差啦T_T,请稍后重试', + title: '系统错误', icon: 'error' }) } }, - fail(err) { + fail(err) { + uni.hideLoading(); uni.showToast({ - title: '系统开小差啦T_T,请稍后重试', + title: '请求失败', icon: 'error' }) - }, - complete(res) { - uni.hideLoading(); } }) }, diff --git a/pages/my/b-account-bind.vue b/pages/my/b-account-bind.vue index 53c57a9..9560deb 100644 --- a/pages/my/b-account-bind.vue +++ b/pages/my/b-account-bind.vue @@ -94,16 +94,18 @@ }, async submit() { if (this.curAccountType === '1') { - if (!this.checkCertify()) { - return; - } if (!this.validData()) { uni.showToast({ icon: 'none', - title: '请完成必填项的填写' + title: '请完成必填项的填写', + duration: 2000 }) return; } + let checkCertifyRes = await this.checkCertify(); + if (!checkCertifyRes) { + return; + } let params = { ...this.formData, workerId: this.curUserInfo.workerId @@ -116,7 +118,8 @@ } else if (res && res.msg) { uni.showToast({ icon: 'none', - title: res.msg + title: res.msg, + duration: 4000 }) } else { uni.showToast({ diff --git a/pages/order-manage/order-manage.vue b/pages/order-manage/order-manage.vue index 6696b80..3b613a2 100644 --- a/pages/order-manage/order-manage.vue +++ b/pages/order-manage/order-manage.vue @@ -301,6 +301,7 @@ + @@ -310,7 +311,9 @@ 师傅反馈结果: - {{afterServiceRecord.workerFeedbackResult === 1 ? '同意' : '拒绝'}} + 拒绝 + 同意 + 重新上门 同意退款金额: @@ -318,7 +321,7 @@ {{afterServiceRecord.refund}} {{order.payMoney}} - + 师傅反馈: 客户原因 师傅原因 @@ -337,9 +340,11 @@ 师傅反馈结果: - {{afterServiceRecord.workerFeedbackResult === 1 ? '同意' : '拒绝'}} + 拒绝 + 同意 + 重新上门 - + 师傅反馈: 客户原因 师傅原因 @@ -402,6 +407,7 @@ + @@ -656,6 +662,7 @@ params.workFinishTimeExisted = true; params.drawCashStatusList = [0,1]; params.orderStatus = null; + params.orderStatusList = [4,5]; } else if (this.tabCur === 5) { // 已完成/子单 params.workFinishTimeExisted = true; @@ -1312,6 +1319,28 @@ duration: 1000 }) } + }, + async revisit() { + let res = await this.$request.editAfterServiceRecord({ + id: this.curOrder.afterServiceRecordList[0].id, + orderDetailId: this.curOrder.orderDetailId, + workerFeedbackResult: 2, + updateBy: 2 + }); + if (res && res.code === 0) { + uni.showToast({ + icon: 'success', + title: '提交成功', + duration: 1000 + }) + this.reloadMasterOrderPage(); + return; + } + uni.showToast({ + icon: 'error', + duration: 1000, + title: '提交失败', + }) } } } diff --git a/pages/order-manage/serv-detail.vue b/pages/order-manage/serv-detail.vue index 266e727..84ed57b 100644 --- a/pages/order-manage/serv-detail.vue +++ b/pages/order-manage/serv-detail.vue @@ -216,13 +216,15 @@ 师傅反馈结果: - {{afterServiceRecord.workerFeedbackResult === 1 ? '同意' : '拒绝'}} + 拒绝 + 同意 + 重新上门 同意退款金额: {{afterServiceRecord.agreedRefund ? afterServiceRecord.agreedRefund : afterServiceRecord.refund}} - + 师傅反馈: 客户原因 师傅原因 @@ -241,9 +243,11 @@ 师傅反馈结果: - {{afterServiceRecord.workerFeedbackResult === 1 ? '同意' : '拒绝'}} + 拒绝 + 同意 + 重新上门 - + 师傅反馈: 客户原因 师傅原因 @@ -432,13 +436,15 @@ 师傅反馈结果: - {{afterServiceRecord.workerFeedbackResult === 1 ? '同意' : '拒绝'}} + 拒绝 + 同意 + 重新上门 同意退款金额: {{afterServiceRecord.agreedRefund ? afterServiceRecord.agreedRefund : afterServiceRecord.refund}} - + 师傅反馈: 客户原因 师傅原因 @@ -457,9 +463,11 @@ 师傅反馈结果: - {{afterServiceRecord.workerFeedbackResult === 1 ? '同意' : '拒绝'}} + 拒绝 + 同意 + 重新上门 - + 师傅反馈: 客户原因 师傅原因