From a1c569d40b5d1d6571a197467a41fd3421c393ce Mon Sep 17 00:00:00 2001
From: doum <doum>
Date: 星期一, 15 九月 2025 09:10:49 +0800
Subject: [PATCH] Merge remote-tracking branch 'origin/master'

---
 small-program/pages/freight/freight.vue |   39 ++++++++++++++++++++++++---------------
 1 files changed, 24 insertions(+), 15 deletions(-)

diff --git a/small-program/pages/freight/freight.vue b/small-program/pages/freight/freight.vue
index 9951efe..d0f17e9 100644
--- a/small-program/pages/freight/freight.vue
+++ b/small-program/pages/freight/freight.vue
@@ -91,7 +91,7 @@
 					<view class="list-item-row">
 						<view class="list-item-row-label">杩愯緭閲嶉噺/鏁伴噺<b>*</b></view>
 						<view class="list-item-row-val">
-							<input type="text" style="flex: 3;" v-model="form.transportNum" placeholder="璇疯緭鍏�" />
+							<input type="digit" style="flex: 3;" v-model="form.transportNum" placeholder="璇疯緭鍏�" />
 							<!-- <view @click="show4 = true" style="width: 100rpx; flex-shrink: 0; display: flex; align-items: center; justify-content: flex-end;">
 								<text>{{form.transportUnit}}</text>
 								<u-icon name="arrow-down" color="#111111" size="16"></u-icon>
@@ -101,29 +101,30 @@
 						</view>
 						 
 					</view>
-					<view class="list-item-row" v-if="viewStatus">
+					<view class="list-item-row" >
 						<view class="list-item-row-label">闇�姹傝ˉ鍏�</view>
 						<view class="list-item-row-val">
 							<textarea cols="30" v-model="form.supplement" rows="10" placeholder="璇疯緭鍏�" maxlength="200"></textarea>
 						</view>
 					</view>
-					<view class="list-item-row" v-if="viewStatus">
+					<view class="list-item-row" >
 						<view class="list-item-row-label">鍥剧墖</view>
 						<view class="list-item-row-upload">
-							<view class="upload-item" v-for="(item, index) in form.multifileList" :key="index">
+							<view class="upload-item" v-for="(item, index) in form.multifileList" :key="index" @click="preview(index, form.multifileList)">
 								<image :src="item.url || item.fileurlFull" mode="widthFix"></image>
-								<image class="upload-item-dele" @click="form.multifileList.splice(index, 1)" src="/static/icon/ic_delete1@2x.png" mode="widthFix"></image>
+								<image class="upload-item-dele" @click.stop="form.multifileList.splice(index, 1)" src="/static/icon/ic_delete1@2x.png" mode="widthFix"></image>
 							</view>
 							<view class="upload-item" @click="uploadImg">
 								<u-icon name="plus" color="#999999" size="24"></u-icon>
 								<text>鐐瑰嚮涓婁紶</text>
 							</view>
+							<view style="width: 215rpx; height: 0;"></view>
 						</view>
 					</view>
-					<view class="list-item-zk" @click="viewStatus = !viewStatus">
+					<!-- <view class="list-item-zk" @click="viewStatus = !viewStatus">
 						<text>{{viewStatus ? '鏀惰捣' : '琛ュ厖闇�姹�'}}</text>
 						<u-icon :name="viewStatus ? 'arrow-up' : 'arrow-down'" color="#00BC12" size="16"></u-icon>
-					</view>
+					</view> -->
 				</view>
 				<view class="list-item">
 					<view class="list-item-label">
@@ -136,21 +137,21 @@
 					<view class="list-item-row" v-if="form.carType==0">
 						<view class="list-item-row-label">鐢ㄨ溅澶╂暟</view>
 						<view class="list-item-row-val">
-							<input type="number" v-model="form.totalDays" disabled placeholder="" />
+							<input type="digit" v-model="form.totalDays" disabled placeholder="" />
 							<text>澶�</text>
 						</view>
 					</view>
 					<view class="list-item-row" v-if="form.carType==1">
 						<view class="list-item-row-label">鐢ㄨ溅娆℃暟<b>*</b></view>
 						<view class="list-item-row-val">
-							<input type="number" v-model="form.priceNum1"   placeholder="璇疯緭鍏�" />
+							<input type="digit" v-model="form.priceNum1"  @input="getPrice"  placeholder="璇疯緭鍏�" />
 							<text>娆�</text>
 						</view>
 					</view>
 					<view class="list-item-row">
 						<view class="list-item-row-label">璐圭敤鏍囧噯<b>*</b></view>
 						<view class="list-item-row-val">
-							<input type="digit" @blur="getPrice"  v-model="form.price" placeholder="璇疯緭鍏�" />
+							<input type="digit" @input="getPrice"  v-model="form.price" placeholder="璇疯緭鍏�" />
 							<text>{{form.priceUnit}}</text>
 						</view>
 					</view>
@@ -307,6 +308,7 @@
 					} else if (news === 1) {
 						this.form.priceUnit = '鍏�/娆�'
 					}
+					this.getPrice()
 				}
 			}
 		},
@@ -354,7 +356,11 @@
 			this.getCategoryLists()
 		},
 		methods: {
-			 handleInputPrice(e) {
+			preview(current, arr) {
+				let urls = arr.map(item => item.url || item.fileurlFull)
+				uni.previewImage({ current, urls })
+			},
+			handleInputPrice(e) {
 				 try{
 					 this.form.price = Number(this.form.price).toFixed(3) 
 				 }catch(e){
@@ -488,8 +494,9 @@
 					this.$u.api.getTotal({
 						price: Number(this.form.price).toFixed(2) * 100,
 						priceUnit: this.form.priceUnit,
-						priceNum1: this.form.priceNum1,
+						priceNum1: this.form.carType!=1?this.form.totalDays:this.form.priceNum1,
 						priceNum2: this.form.priceNum2,
+						carType:this.form.carType ,
 						type: 1
 					}).then(res => {
 						if (res.code === 200) {
@@ -541,6 +548,7 @@
 				let time = this.form.startDate == this.form.endDate ? 1 : 0
 				this.form.totalDays = e.length - time;
 				this.show2 = false
+				this.getPrice()
 			},
 			addAddr() {
 				this.form.wayInfoDTOList.push({
@@ -929,21 +937,22 @@
 						width: 100%;
 						display: flex;
 						align-items: center;
+						justify-content: space-between;
 						flex-wrap: wrap;
 						padding: 30rpx 0;
 						box-sizing: border-box;
 						.upload-item {
-							width: 156rpx;
-							height: 156rpx;
+							width: 215rpx;
+							height: 215rpx;
 							display: flex;
 							align-items: center;
 							flex-direction: column;
 							justify-content: center;
 							background: #F8F9FB;
 							border-radius: 8rpx;
-							margin-right: 20rpx;
 							border: 2rpx solid #EEEEEE;
 							position: relative;
+							margin-bottom: 15rpx;
 							&:last-child {
 								margin: 0 !important;
 							}

--
Gitblit v1.9.3