From 2490d3321f6d6f9b5bacf29225387f7c3f89a2b4 Mon Sep 17 00:00:00 2001
From: yangan <yangan0921@163.com>
Date: 星期四, 20 六月 2024 15:47:15 +0800
Subject: [PATCH] feat:司机填写集装箱号

---
 pages/public-page/forward/forward.vue |   60 ++++++++++++++++++++++++++++++++++++++++++++----------------
 1 files changed, 44 insertions(+), 16 deletions(-)

diff --git a/pages/public-page/forward/forward.vue b/pages/public-page/forward/forward.vue
index d3a0cb2..f27b4b9 100644
--- a/pages/public-page/forward/forward.vue
+++ b/pages/public-page/forward/forward.vue
@@ -88,13 +88,21 @@
 					:hairline="false"
 					@click.stop="addForm"
 					:disabled="whetherClick"></u-button></view>
+			<!--鍒嗕韩鏃ヨ鍒�  -->
+			<view 
+			class="AdddBtn"><u-button text="鍒嗕韩鏃ヨ鍒�"
+					:hairline="false"
+					open-type="share"
+					:loading='loading'></u-button></view>
 			<!-- 鎻愪氦鎸夐挳 -->
-			<view class="forwardBtn"><u-button text="鎻愪氦"
+			<view 
+			class="forwardBtn"><u-button text="鎻愪氦"
 					:hairline="false"
 					type="warning"
 					@click.stop="submitForm"
 					:disabled="whetherClick1"
 					:loading='loading'></u-button></view>
+			
 		</view>
 		<!-- 澧炲姞鎸夐挳 -->
 
@@ -160,27 +168,40 @@
 			this.carNumSurplusHuodai = this.forwardSurplus = Number(params.carNumSurplusHuodai || 0);
 			this.orderPlanId = params.orderPlanId;
 			// 鍒ゆ柇鏄惁杞彂瀹屾垚 瀹屾垚鍒欎笉鍙啀娣诲姞
-			if (this.roleType === 1) {
+			if (this.roleType === 1) {  //roleType 1瀹㈡埛
 				this.whetherClick = this.carNumSurplus1 === 0
-			} else if (this.roleType === 2) {
+			} else if (this.roleType === 2) {  //roleType 2璐т唬
 				this.whetherClick = this.forwardSurplus === 0
 			}
 			this.getOrderPlan()
 		},
+		onShareAppMessage(res) {
+		銆�銆�if (res.from === 'button') {// 鏉ヨ嚜椤甸潰鍐呭垎浜寜閽�
+		銆�銆�銆�銆�console.log(res.target)
+		銆�銆�}
+		銆�銆�return {
+		銆�銆�銆�銆�title: '鍒嗕韩鏃ヨ鍒�',
+		銆�銆�銆�銆�path: 'pages/driver-page/delivery-my/delivery-my/delivery-my?'+ `id=${this.orderPlanId}`
+		銆�銆�}
+
+		},
+
+
 		data() {
 			return {
 				forwardSurplus: 0,
 				paramsName: {},
 				huoDaiData: [],
+				isClickFlag:true,// true 鍙互 or false for forward and back to the direction of the car direction (default	 	
 				fleetData: [],
 				// 鏃ヨ鍒抜d
 				orderPlanId: '',
-				jhOrderPlanForwardList: [{
-					orderPlanId: '',
-					name: '',
-					carNum: null,
-					xsUserId: 0,
-					fleetId: 0,
+				jhOrderPlanForwardList: [{  //杞彂瀵硅薄
+					orderPlanId: '',  //鏃ヨ鍒扞d
+					name: '',  //杞﹂槦鎴栬揣浠e悕绉�
+					carNum: null,  //杞彂鏁伴噺
+					xsUserId: 0,  //璐т唬Id
+					fleetId: 0,  //杞﹂槦Id
 					checkboxValue1: '',  //鍏ㄩ儴杞彂
 					isSelected: false
 				}],
@@ -190,9 +211,9 @@
 				selectPopupShow: false,
 				list1: [{ name: '杞﹂槦' }, { name: '璐т唬' }],
 				tabHuoDai: false,
-				carNumSurplus1: '',
+				carNumSurplus1: '',  //鍓╀綑鐨勬彁鐓ゅ崟鏁伴噺锛堣浆鍙戠殑鏁伴噺 - 棰嗗彇鐨勬暟閲忥級
 				tempcarNumSurplus1: '',
-				cars2: '',
+				cars2: '',  //宸茬粡棰嗗彇鐨勮溅鏁�
 				carNum: '',
 				carNumSurplusHuodai: '',
 				formNum: 1,
@@ -362,13 +383,18 @@
 					this.fleetData = res.data;
 				});
 			},
-			// 杞彂
+			// 杞彂瀵硅薄
 			forwardObjectClick(index, name, id) {
+				if(!id){
 				this.selectPopupShow = true;
 				this.index = index;
 				this.originForwardName = name || ''
 				this.isDirectAdd = this.originForwardName !== ''
 				this.forwardId = id
+				}else{
+					return 
+				}
+				
 			},
 			selectPopupClose() {
 				this.selectPopupShow = false;
@@ -410,7 +436,7 @@
 						this.jhOrderPlanForwardList[this.index].xsUserId = item.userId;
 						this.jhOrderPlanForwardList[this.index].name = item.name;
 						this.jhOrderPlanForwardList[this.index].fleetId = 0;
-						this.jhOrderPlanForwardList[this.index].forWardType = 1;
+						this.jhOrderPlanForwardList[this.index].forWardType = 1;  //forWardType 杞彂绫诲瀷 璐т唬1 杞﹂槦2
 					}
 					// }
 				});
@@ -593,6 +619,7 @@
 						return isPass;
 					}
 				});
+				console.log(this.jhOrderPlanForwardList,'jhOderPlan')
 				if (isPass) {
 					this.loading = true;
 					this.$reqPost('forward', this.jhOrderPlanForwardList, 'json').then(res => {
@@ -620,7 +647,7 @@
 				} else {
 					this.tabHuoDai = false;
 				}
-			}
+			},
 		}
 	};
 </script>
@@ -784,11 +811,12 @@
 		}
 
 		.utils-buttonGroup {
-			width: 610rpx;
+			width: 700rpx;
 			@include flex;
+			justify-content: space-between;
 			position: fixed;
 			bottom: vww(30);
-			left: vww(30);
+			left: vww(18);
 			z-index: 3;
 
 			.AdddBtn,

--
Gitblit v1.9.1