From 029dd92e96bec1ca325e99f154c8a2188919e8d5 Mon Sep 17 00:00:00 2001 From: qingyiay <2386314947@qq.com> Date: 星期一, 26 六月 2023 08:49:56 +0800 Subject: [PATCH] 增加验质功能 --- pages/driver-page/driver-index/bill-of-lading-details/weighingDevice/weighingDevice.vue | 34 +++++++++++++--------------------- 1 files changed, 13 insertions(+), 21 deletions(-) diff --git a/pages/driver-page/driver-index/bill-of-lading-details/weighingDevice/weighingDevice.vue b/pages/driver-page/driver-index/bill-of-lading-details/weighingDevice/weighingDevice.vue index 75b1b71..739eb25 100644 --- a/pages/driver-page/driver-index/bill-of-lading-details/weighingDevice/weighingDevice.vue +++ b/pages/driver-page/driver-index/bill-of-lading-details/weighingDevice/weighingDevice.vue @@ -142,17 +142,17 @@ </view> <view class="main-information"> <view class="prefix">鐨噸:</view> - <view class="suffix">{{ temporaryWeighObj.skin == 0 ? weighList.skin : temporaryWeighObj.skin }} + <view class="suffix">{{ showWeigh.skin||"" }} </view> </view> <view class="main-information"> <view class="prefix">姣涢噸:</view> - <view class="suffix">{{ temporaryWeighObj.hair == 0 ? weighList.hair : temporaryWeighObj.hair }} + <view class="suffix">{{showWeigh.hair||""}} </view> </view> <view class="main-information"> <view class="prefix">鍑�閲�:</view> - <view class="suffix">{{ temporaryWeighObj.clean == 0 ? weighList.clean : temporaryWeighObj.clean }} + <view class="suffix">{{ showWeigh.clean||"" }} </view> </view> <view class="main-information"> @@ -305,13 +305,6 @@ } }, // 鐩戝惉閲嶉噺鍙樺寲 - // globalweigh: { - // handler(v) { - // this.weighData.weigh = this.realTimeWeigh = v; - // console.log(this.realTimeWeigh, '鐪熷疄閲嶉噺鏀瑰彉浜�'); - // }, - // deep: true - // }, globalweigh(newV) { this.weighData.weigh = this.realTimeWeigh = newV; console.log(this.realTimeWeigh, '鐪熷疄閲嶉噺鏀瑰彉浜�'); @@ -336,13 +329,6 @@ // 鍔犲噺鐓ゆ寜閽鐢ㄤ笌鍚� addAndSubtractCoalDisabled() { return this.realTimeWeigh == 0; - // if (this.weighList.orderType == '澶栭攢' || this.weighList.orderType == '鍐呴攢' || this.weighList.orderType == '杞嚭') { - // if (this.weighList.hair == 0) { - // return true; - // } else if (this.weighList.hair != 0) { - // return false; - // } - // } }, // 鏄惁鏀剧┖鎸夐挳绂佺敤 isEvacuation() { @@ -350,27 +336,31 @@ '杞嚭') { return (this.weighList.skin === 0 ? this.temporaryWeighObj.skin : this.weighList.skin) == this .temporaryWeighObj.hair; - // return this.weighList.skin == this.temporaryWeighObj.hair || this.temporaryWeighObj.skin == this - // .temporaryWeighObj.hair; } if (this.weighList.orderType == '澶栬喘' || this.weighList.orderType == '鍐呰喘' || this.weighList.orderType == '杞叆') { return (this.weighList.hair === 0 ? this.temporaryWeighObj.skin : this.weighList.hair) == this .temporaryWeighObj.hair; - // return this.weighList.hair == this.temporaryWeighObj.skin || this.temporaryWeighObj.skin == this - // .temporaryWeighObj.hair; } }, sideline() { return this.weighList.orderType == '鍐呰喘' || this.weighList.orderType == '杞叆'; + }, + showWeigh() { + return this.weighList.tmTaskCoalItems ? (this.weighList.tmTaskCoalItems[0] ? this + .weighList.tmTaskCoalItems[0] : {}) : {} } }, methods: { ...mapMutations(['changeweighHouseCode', 'changeisLogin']), init() { + uni.showLoading({ + title: '鍔犺浇涓�' + }) // 鑾峰彇绉伴噸淇℃伅 this.$reqGet('weighList', { id: this.takeCoalId }).then(res => { console.log(res, '鑾峰彇绉伴噸淇℃伅'); + uni.hideLoading() if (res.code == 0) { this.weighList = res.data; this.weighData.deptId = res.data.deptId; @@ -460,6 +450,8 @@ this.isConfirmWeighLoading = false; }, 1000); console.log(res, '鍔犲噺鐓�'); + } else { + this.$u.toast('鎿嶄綔澶辫触锛岃绋嶅�欓噸璇�'); } }); }, -- Gitblit v1.9.1