From e193d75257a21568a15f99b27a2a48bd7fd815f9 Mon Sep 17 00:00:00 2001
From: 付延余 <f-yanyu@outlook.com>
Date: 星期三, 22 三月 2023 17:59:06 +0800
Subject: [PATCH] 1.磅房详情(完成) 2.入场申请报错(完成) 3.签到(完成) 4.日志(完成) 5.发运计划详情(完成)

---
 pages/driver-page/driver-index/bill-of-lading-details/bill-of-lading-details.vue |  160 +++++++++++++++++++++++++++++++++++++++++++---------
 1 files changed, 131 insertions(+), 29 deletions(-)

diff --git a/pages/driver-page/driver-index/bill-of-lading-details/bill-of-lading-details.vue b/pages/driver-page/driver-index/bill-of-lading-details/bill-of-lading-details.vue
index 01ac4c9..fd0fc70 100644
--- a/pages/driver-page/driver-index/bill-of-lading-details/bill-of-lading-details.vue
+++ b/pages/driver-page/driver-index/bill-of-lading-details/bill-of-lading-details.vue
@@ -1,13 +1,33 @@
 <template>
 	<view class="bill-of-lading-details">
-		<view class="bangDanMessage"><text>纾呭崟淇℃伅</text></view>
-		<view class="timeLine" style="font-size: 16rpx;"><u-text v-for="(item, index) in dayRZ" :key="index" :text="item.taskStatusDes"></u-text></view>
+		<view class="bangDanMessage">
+			<view class="">
+				<u--text align="center" size="35" bold plain text="涓昏壊" :text="'瀹㈡埛锛�' + coalDetailsData.customerName"></u--text>
+				<u--text align="center" size="35" bold plain text="涓昏壊" :text="'鐭垮巶锛�' + coalDetailsData.deptName"></u--text>
+			</view>
+			<view class="">
+				<u--text align="center" size="35" bold plain text="涓昏壊" :text="'鐨噸锛�' + coalDetailsData.skin"></u--text>
+				<u--text align="center" size="35" bold plain text="涓昏壊" :text="'姣涢噸锛�' + coalDetailsData.hair"></u--text>
+				<u--text align="center" size="35" bold plain text="涓昏壊" :text="'鍑�閲嶏細' + coalDetailsData.clean"></u--text>
+			</view>
+			<view class="">
+				<u--text align="center" size="35" bold plain text="涓昏壊" :text="'纾呭崟绫诲瀷锛�' + coalDetailsData.orderTye"></u--text>
+				<u--text align="center" size="35" bold plain text="涓昏壊" :text="'鐘舵�侊細' + coalStatus[coalDetailsData.status]"></u--text>
+			</view>
+			<u--text align="center" size="35" bold plain text="涓昏壊" :text="'鐓ゅ満锛�' + coalDetailsData.filedName"></u--text>
+			<u--text align="center" size="35" bold plain text="涓昏壊" :text="'鍙戣繍鏃堕棿锛�' + coalDetailsData.sendDate"></u--text>
+			<u--text align="center" size="35" bold plain text="涓昏壊" :text="'鎻愮叅鍗曠紪鍙凤細' + coalDetailsData.code"></u--text>
+			<u--text align="center" size="35" bold plain text="涓昏壊" :text="'璁㈠崟缂栧彿锛�' + coalDetailsData.orderCode"></u--text>
+		</view>
+		<view class="timeLine" style="font-size: 16rpx;">
+			<u--text type="primary" size="30" plain text="涓昏壊" v-for="(item, index) in dayRZ" :key="index" :text="item.taskStatusDes"></u--text>
+		</view>
 		<view class="utilsBox">
 			<view class="utils_chil utils_chilTop">
-				<u-button text="绛惧埌" type="primary" @click="arriveClick"></u-button>
-				<u-button text="鍏ュ満鐢宠" type="primary" @click="rcsqClick"></u-button>
-				<u-button text="鏀剧┖" type="primary"></u-button>
-				<u-button text="鍛煎彨瀹㈡湇" type="primary"></u-button>
+				<u-button text="绛惧埌" type="primary" plain @click="arriveClick"></u-button>
+				<u-button text="鍏ュ満鐢宠" type="primary" plain @click="rcsqClick"></u-button>
+				<u-button text="鏀剧┖" type="primary" plain></u-button>
+				<u-button text="鍛煎彨瀹㈡湇" type="primary" plain></u-button>
 			</view>
 			<view class="utils_chil"><u-button text="灞曠ず鎻愮叅鍗�" @click="showCaolPickUpBill" type="primary"></u-button></view>
 			<view class="utils_chil"><u-button text="涓婄璁¢噺" @click="cengZhongClick" type="primary"></u-button></view>
@@ -28,24 +48,67 @@
 		return {
 			orderPlanId: null,
 			yyId: null,
-			dayRZ: []
+			dayRZ: [],
+			coalDetailsData: {}, // 鎻愮叅鍗曡鎯�
+			getWeightHouseObj: {
+				// 鑾峰彇鎵�鍦ㄧ鎴�
+				deptId: '',
+				filedId: '',
+				tmId: '',
+				tmCode: '',
+				carNo: ''
+			},
+			getYuYueDataParams: {
+				deptId: '',
+				filedId: '',
+				sendDate: ''
+			},
+			coalStatus: ['棰嗗彇', '棰勭害', '绛惧埌', '鍏ュ満', '绉扮毊', '绉版瘺', '绂诲満', '鍏ョ鎴�', '鍑虹鎴�', '鍏ョ叅鍦�', '鍑虹叅浠�'] // 鐘舵��
 		};
 	},
 	onShow() {
 		this.init();
 	},
+	computed: {
+		userName() {
+			return uni.getStorageSync('username');
+		},
+		openid() {
+			return uni.getStorageSync('openid');
+		}
+	},
 	methods: {
 		init() {
 			this.coalDayPage();
+			this.getTakeCoal();
 		},
-		// 鏃ュ織鏌ヨ
-		coalDayPage() {
-			this.$reqGet('coalDayPage').then(res => {
+		// 鑾峰彇鎻愮叅鍗曡鎯�
+		getTakeCoal() {
+			this.$reqGet('getTakeCoal', { takeCoalId: this.orderPlanId }).then(res => {
 				if (res.code == 0) {
-					this.dayRZ = res.data.records;
+					this.coalDetailsData = res.data[0];
+					// 鑾峰彇鎵�鍦ㄧ鎴垮弬鏁拌祴鍊�
+					this.getWeightHouseObj.deptId = this.coalDetailsData.deptId;
+					this.getWeightHouseObj.filedId = this.coalDetailsData.filedId;
+					this.getWeightHouseObj.tmId = this.coalDetailsData.id;
+					this.getWeightHouseObj.tmCode = this.coalDetailsData.code;
+					this.getWeightHouseObj.carNo = this.coalDetailsData.carNo;
+					// 鑾峰彇鍏ュ満鐢宠鎿嶄綔鍚庣殑棰勭害鍒楄〃鐨勫弬鏁�
+					this.getYuYueDataParams.deptId = this.coalDetailsData.deptId;
+					this.getYuYueDataParams.filedId = this.coalDetailsData.filedId;
+					this.getYuYueDataParams.sendDate = this.coalDetailsData.sendDate;
 				}
 			});
 		},
+		// 鏃ュ織鏌ヨ
+		coalDayPage() {
+			this.$reqGet('coalDayPage', { id: this.orderPlanId }).then(res => {
+				if (res.code == 0) {
+					this.dayRZ = res.data;
+				}
+			});
+		},
+		// 灞曠ず鎻愮叅鍗曡鎯�
 		showCaolPickUpBill() {
 			uni.navigateTo({
 				url: `/pages/driver-page/driver-index/bill-of-lading-details/coal-pick-up-bill/coal-pick-up-bill?orderPlanId=${this.orderPlanId}`
@@ -53,19 +116,42 @@
 		},
 		// 绛惧埌
 		arriveClick() {
-			this.$reqPost('arrive', { id: this.orderPlanId }, 'params').then(res => {
-				console.log(res, '绛惧埌');
+			uni.navigateTo({
+				url: `/pages/driver-page/driver-index/bill-of-lading-details/punchTheClock/punchTheClock?orderPlanId=${this.orderPlanId}`
 			});
 		},
+		// 鍏ュ満鐢宠
 		rcsqClick() {
 			uni.navigateTo({
-				url: `/pages/driver-page/appointment/appointment?takeCoalId=${this.orderPlanId}&type=鍏ュ満鐢宠&yyId=${this.yyId}`
+				url: `/pages/driver-page/appointment/appointment?type=鍏ュ満鐢宠&takeCoalId=${this.orderPlanId}&yyId=${this.yyId}&filedId=${this.getYuYueDataParams.filedId}&deptId=${
+					this.getYuYueDataParams.deptId
+				}&sendDate=${this.getYuYueDataParams.sendDate}`
 			});
 		},
-		cengZhongClick() {}
-		/**
-		 * @desc 绛夊緟鍙栫叅鍗曟帴鍙�
-		 * */
+		// 鍛煎彨瀹㈡湇
+		callCustomerService() {
+			wx.join1v1Chat({
+				caller: { nickname: this.userName, openid: this.openid },
+				listener: { nickname: '瀹㈡湇', openid: 'orutI5YT0yEvARVngdsTmBpisWmw' }, // 杩欓噷鐨刼penid鏄痜yy鐨勶紝鍏呭綋鍥哄畾鐨勫鏈峯penid
+				backgroundType: 2,
+				roomType: 'voice'
+			});
+		},
+		// 绉伴噸
+		cengZhongClick() {
+			this.$reqGet('getWeighHouse', this.getWeightHouseObj).then(res => {
+				console.log(res, '鑾峰彇纾呮埧');
+				if (res.code == 0) {
+					uni.navigateTo({
+						url: `/pages/driver-page/driver-index/bill-of-lading-details/weighingDevice/weighingDevice?takeCoalId=${this.orderPlanId}&sceneId=${res.data.id}&gateCameraId=${
+							res.data.lastEquipmentId
+						}&gateCameraCode=${res.data.lastEquipmentCode}&weighHouseCode=${res.data.code}`
+					});
+				} else {
+					this.$u.toast('鏈湪纾呮埧锛岃鍓嶅線纾呮埧鍚庡啀璇曪紒锛�');
+				}
+			});
+		}
 	}
 };
 </script>
@@ -77,27 +163,43 @@
 	margin: 0 auto;
 	display: flex;
 	flex-direction: column;
-
 	.bangDanMessage {
-		font-size: vww(20);
-		font-weight: 500;
-		border: vww(1) solid #dddddd;
+		border: vww(2) solid #dddddd;
 		border-radius: vww(20);
 		margin: vww(20);
 		margin-bottom: vww(10);
-		flex: 1;
-		display: flex;
-		flex-direction: row;
-		align-items: center;
-		justify-content: center;
+		height: 40%;
+		box-sizing: border-box;
+		overflow-y: overlay; //琛屼负涓� auto 鐩稿悓锛屼絾鏄粴鍔ㄦ潯缁樺埗鍦ㄥ唴瀹逛箣涓婏紝鑰屼笉鏄崰鎹┖闂淬��
+		.u-text {
+			margin-bottom: vww(5) !important;
+		}
+		view {
+			margin-bottom: vww(5);
+		}
+		view:nth-of-type(1) {
+			display: flex;
+		}
+		view:nth-of-type(2) {
+			display: flex;
+		}
+		view:nth-of-type(3) {
+			display: flex;
+		}
 	}
 	.timeLine {
+		height: 25%;
 		margin: vww(20);
 		margin-top: vww(10);
 		margin-bottom: vww(10);
-		border: vww(1) solid #dddddd;
+		border: vww(2) solid #dddddd;
 		border-radius: vww(20);
-		flex: 2;
+		padding: vww(20);
+		box-sizing: border-box;
+		overflow-y: overlay; //琛屼负涓� auto 鐩稿悓锛屼絾鏄粴鍔ㄦ潯缁樺埗鍦ㄥ唴瀹逛箣涓婏紝鑰屼笉鏄崰鎹┖闂淬��
+		.u-text {
+			margin-bottom: vww(5) !important;
+		}
 	}
 	.utilsBox {
 		padding: vww(20);

--
Gitblit v1.9.1