From 81b3c20184fe89b4c8e9bdbe45276748778a1d95 Mon Sep 17 00:00:00 2001 From: 819527061@qq.com <123456> Date: 星期五, 08 三月 2024 15:40:34 +0800 Subject: [PATCH] 添加注释 --- pages/driver-page/driver-index/SelfDelivery/SelfDelivery.vue | 96 +++++++++++++++++++++++++----------------------- 1 files changed, 50 insertions(+), 46 deletions(-) diff --git a/pages/driver-page/driver-index/SelfDelivery/SelfDelivery.vue b/pages/driver-page/driver-index/SelfDelivery/SelfDelivery.vue index b508a7d..0ca8047 100644 --- a/pages/driver-page/driver-index/SelfDelivery/SelfDelivery.vue +++ b/pages/driver-page/driver-index/SelfDelivery/SelfDelivery.vue @@ -42,30 +42,32 @@ </view> </view> </view> - <!-- 閫夋嫨鍙戣繍鏃堕棿 --> - <view class="send-date"> - <view class="send-date_label"> - 鍙戣繍鏃堕棿 + <view class="bottom-block"> + <!-- 閫夋嫨鍙戣繍鏃堕棿 --> + <view class="send-date"> + <view class="send-date_label"> + 鍙戣繍鏃堕棿 + </view> + <uni-datetime-picker type="date" + :clear-icon="false" + v-model="sendDate" + :start="sendDateStart" + :end="sendDateEnd" /> </view> - <uni-datetime-picker type="date" - :clear-icon="false" - v-model="sendDate" - :start="sendDateStart" - :end="sendDateEnd" /> - </view> - <!-- 瀹㈡埛鍚嶇О --> - <view class="customer-name"> - <view class="customer-name_label"> - 閫夋嫨瀹㈡埛 - </view> - <view class="customer-name_block" - @click="selfDeliver"> - <input class="customer-name_block-input" - type="text" - placeholder="璇烽�夋嫨瀹㈡埛" - v-model="customerName" - @focus="selfDeliver" - ref="selectCustomer" /> + <!-- 瀹㈡埛鍚嶇О --> + <view class="customer-name"> + <view class="customer-name_label"> + 閫夋嫨瀹㈡埛 + </view> + <view class="customer-name_block" + @click="selfDeliver"> + <input class="customer-name_block-input" + type="text" + placeholder="璇烽�夋嫨瀹㈡埛" + v-model="customerName" + @focus="selfDeliver" + ref="selectCustomer" /> + </view> </view> </view> <!-- 鎻愪氦 --> @@ -209,7 +211,10 @@ text: v.productName } }) - this.productName = this.productNameList[0].value + this.productName = Array.isArray(this.productNameList) && this.productNameList.lenght !== 0 ? + this.productNameList[0].value : '' + }).then(() => { + this.getShipToList() }) }, // 鏍规嵁閮ㄩ棬鑾峰彇鐓ゅ満鍚嶇О @@ -221,8 +226,13 @@ text: v.name } }) - this.filedId = this.filedNameList.length !== 0 ? this.filedNameList[0].value : '' - this.filedName = this.filedNameList.length !== 0 ? this.filedNameList[0].text : '' + if (Array.isArray(this.filedNameList) && this.filedNameList.length === 1) { + this.filedId = this.filedNameList[0].value + this.filedName = this.filedNameList[0].text + } else if (Array.isArray(this.filedNameList) && this.filedNameList.length > 1) { + this.filedId = '' + this.filedName = '' + } }) }, filedChange(e) { @@ -235,9 +245,6 @@ }, selfDeliver() { this.selfDeliverShow = true - this.$nextTick(() => { - this.$refs.selectCustomer.blur() - }) }, selfDeliverClose() { this.selfDeliverShow = false @@ -254,15 +261,15 @@ let form = { carNo: uni.getStorageSync('carNo'), coalName: this.productName, - deptId: this.deptId, - deptName: this.deptName, - filedId: this.filedId, - filedName: this.filedName, + deptId: this.deptId, //閮ㄩ棬Id + deptName: this.deptName, //閮ㄩ棬鍚嶇О + filedId: this.filedId, //鐓ゅ満Id + filedName: this.filedName, //鐓ゅ満鍚嶇О orderType: "澶栬喘", - sendDate: this.sendDate, - xsUserId1: uni.getStorageSync('userId'), - isPretendDischar: 1, - isSpecial: 1, + sendDate: this.sendDate, //鍙戣繍鏃堕棿 + xsUserId1: uni.getStorageSync('userId'), //鐢ㄦ埛id + isPretendDischar: 1, //鏄惁鑳借鍗� 1宸茬粡纭瑁呭嵏 0涓嶉渶瑕佽鍗� + isSpecial: 1, //鏄惁鏄壒浜у搧 1鐗规畩浜у搧 0涓嶆槸鐗逛娇浜у搧 customerId: this.customerId, customerName: this.customerName } @@ -309,22 +316,16 @@ align-items: center; } - .slot-content { - width: 100%; - height: vww(150); - @include flex; - flex-direction: column; - } .main { width: 100%; + color: #232323; .product-info { width: 96%; height: vww(250); margin: vww(8); margin-top: vww(20); - background: #ffffff; box-shadow: 0rpx 0rpx 14rpx 0rpx rgba(73, 120, 240, 0.14), 0rpx 7rpx 45rpx 0rpx rgba(73, 120, 240, 0.12); border-radius: 20rpx; position: relative; @@ -361,9 +362,12 @@ } } + .bottom-block { + height: vww(200); + } + .send-date, .customer-name { - height: vww(40); margin: vww(40) vww(20); position: relative; @@ -463,4 +467,4 @@ } } } -</style> \ No newline at end of file +</style> -- Gitblit v1.9.1