From f5d9fc10d155aed63fdf91217380610faa60f9e0 Mon Sep 17 00:00:00 2001 From: qingyiay <2386314947@qq.com> Date: 星期五, 14 七月 2023 15:04:36 +0800 Subject: [PATCH] 转发页面修改 --- pages/public-page/forward/forward.vue | 24 ++++++++++++------------ 1 files changed, 12 insertions(+), 12 deletions(-) diff --git a/pages/public-page/forward/forward.vue b/pages/public-page/forward/forward.vue index 515db6d..8ea8e96 100644 --- a/pages/public-page/forward/forward.vue +++ b/pages/public-page/forward/forward.vue @@ -158,10 +158,10 @@ return { id: item.id, orderPlanId: item.orderPlanId, - name: item.xsUserName === null ? item.fleetName : item.xsUserName, + name: item.xsUserName ? item.xsUserName : item.fleetName, carNum: item.carNum, - xsUserId: item.xsUserId === null ? 0 : item.xsUserId, - fleetId: item.fleetId === null ? 0 : item.fleetId, + xsUserId: item.xsUserId ? item.xsUserId : 0, + fleetId: item.fleetId ? item.fleetId : 0, checkboxValue1: '', vid: `${new Date().getTime()}${index}${item.id}` }; @@ -173,8 +173,8 @@ orderPlanId: item.orderPlanId, name: item.fleetName, carNum: item.carNum, - xsUserId: item.xsUserId === null ? 0 : item.xsUserId, - fleetId: item.fleetId === null ? 0 : item.fleetId, + xsUserId: item.xsUserId ? 0 : item.xsUserId, + fleetId: item.fleetId ? 0 : item.fleetId, checkboxValue1: '', vid: `${new Date().getTime()}${index}${item.id}` }; @@ -247,10 +247,10 @@ return uni.getStorageSync('roleType'); }, text() { - return `宸查鍙�${this.cars2}寮犳彁鐓ゅ崟,鍓╀綑${this.carNumSurplus1}寮犳彁鐓ゅ崟`; + return `宸查鍙�${this.cars2}寮犻�氱煡鍗�,鍓╀綑${this.carNumSurplus1}寮犻�氱煡鍗昤; }, text1() { - return `宸叉嫢鏈�${this.carNum}寮犳彁鐓ゅ崟,鍓╀綑${this.carNumSurplusHuodai}寮犳彁鐓ゅ崟`; + return `宸叉嫢鏈�${this.carNum}寮犻�氱煡鍗�,鍓╀綑${this.carNumSurplusHuodai}寮犻�氱煡鍗昤; } }, methods: { @@ -372,12 +372,12 @@ } }); }, - // 璁$畻鎻愮叅鍗曟暟閲忥紝娣诲姞鎴栧垹闄ゆ椂璋冪敤 + // 璁$畻閫氱煡鍗曟暟閲忥紝娣诲姞鎴栧垹闄ゆ椂璋冪敤 calculate(arr) { let total = arr.reduce((prev, cur) => { return cur.carNum + prev; }, 0); - console.log(total, '鎻愮叅鍗曚竴鍏辩殑鏁版嵁'); + console.log(total, '閫氱煡鍗曚竴鍏辩殑鏁版嵁'); if (this.roleType == 1) { if (Number(this.cars2) >= total) { this.carNumSurplus1 = Number(this.cars2) - total; @@ -385,7 +385,7 @@ this.whetherClick1 = false; } else { this.carNumSurplus1 = 0; - this.$u.toast('鍓╀綑鎻愮叅鍗曟暟閲忎笉瓒�'); + this.$u.toast('鍓╀綑閫氱煡鍗曟暟閲忎笉瓒�'); this.whetherClick = true; this.whetherClick1 = true; } @@ -397,7 +397,7 @@ this.whetherClick1 = false; } else { this.carNumSurplusHuodai = 0; - this.$u.toast('鍓╀綑鎻愮叅鍗曟暟閲忎笉瓒�'); + this.$u.toast('鍓╀綑閫氱煡鍗曟暟閲忎笉瓒�'); this.whetherClick = true; this.whetherClick1 = true; } @@ -413,7 +413,7 @@ that.calculate(that.jhOrderPlanForwardList); if (that.roleType == 1) { if (that.jhOrderPlanForwardList[index].carNum < Number(that - .carNumSurplus1)) { + .carNumSurplus1)) { that.$set(that.jhOrderPlanForwardList[index], 'checkboxValue1', ''); that.jhOrderPlanForwardList.forEach((v, i) => { if (index != i) { -- Gitblit v1.9.1