From cf583980d5516009f1e80bf64be814d1f3c083a9 Mon Sep 17 00:00:00 2001
From: 快乐的昕的电脑 <快乐的昕的电脑@DESKTOP-C2BQPQU>
Date: 星期五, 10 十月 2025 16:14:42 +0800
Subject: [PATCH] 送检逻辑更新

---
 components/machine.vue |   55 ++++++++++++++++++++++++++++++++++++++++++++++++-------
 1 files changed, 48 insertions(+), 7 deletions(-)

diff --git a/components/machine.vue b/components/machine.vue
index 2820f9f..b9a1731 100644
--- a/components/machine.vue
+++ b/components/machine.vue
@@ -5,12 +5,13 @@
 			<button class="refresh-btn" @click="refresh">鍒锋柊</button>
 		</view>
 		<!-- 涓棿鐘舵�侀儴鍒嗭紝涓婁笅缁撴瀯 -->
+		<!--
 		<view class="middle-section">
 			<view class="item" style="height: 100px;">
-				<h4>璇存槑:澶氬伐鍗曟ā寮忔椂璋冩満閫佹鏄粺涓�鐨�</h4>
+				<h4>璇存槑:璋冩満寮�濮嬫椂闂撮渶瑕佹墜鍔ㄧ‘璁�</h4>
 			</view>
 			<view class="item" v-if="!maStartTime">
-				<button class="btn-blue" @click="setStartTime">璋冩満寮�濮嬶紙=鎹㈡ā瀹屾垚锛�</button>
+				<button class="btn-blue" @click="setMaStartTime">璋冩満寮�濮嬶紙=鎹㈡ā瀹屾垚锛�</button>
 				<input class="txt-inp" v-model="maStartTime" placeholder="鐐瑰嚮鎸夐挳甯﹀嚭鏃堕棿" disabled="true" />
 			</view>
 			<view class="item" v-else>
@@ -30,12 +31,46 @@
 				<input class="txt-inp" v-model="maEndTime" placeholder="棣栨棣栨纭閫氳繃鍐欏叆" disabled="true" />
 			</view>
 		</view>
+		-->
+		<!-- 涓棿鐘舵�侀儴鍒嗭紝涓婁笅缁撴瀯 -->
+		<view class="middle-section">
+			<view class="item" style="height: 100px;">
+				<h4>璇存槑:璋冩満寮�濮嬫椂闂撮渶瑕佹墜鍔ㄧ‘璁�</h4>
+			</view>
+			<view class="item">
+				<!-- 璋冩満寮�濮嬫寜閽紝maStartTime鏈夊�兼椂绂佺敤 -->
+				<button :class="maStartTime ? 'btn-disabled' : 'btn-blue'"
+						:disabled="!!maStartTime"
+						@click="!maStartTime && setMaStartTime">
+					璋冩満寮�濮嬶紙=鎹㈡ā瀹屾垚锛�
+				</button>
+				<input class="txt-inp" v-model="maStartTime" placeholder="鐐瑰嚮鎸夐挳甯﹀嚭鏃堕棿" disabled="true" />
+			</view>
+			<view class="item">
+				<!-- 閫佹鍛煎彨鎸夐挳锛宮aShoutTime鏈夊�兼椂绂佺敤 -->
+				<button :class="maShoutTime ? 'btn-disabled' : 'btn-blue'"
+						:disabled="!!maShoutTime"
+						@click="!maShoutTime && stateCheck(1)">
+					閫佹鍛煎彨锛堢偣鍑绘寜閽畖娓呴浂鏈哄彴闈㈡澘鏁帮級
+				</button>
+				<input class="txt-inp" v-model="maShoutTime" placeholder="鐐瑰嚮鎸夐挳甯﹀嚭鏃堕棿" disabled="true" />
+			</view>
+			<view class="item">
+				<!-- 璋冩満瀹屾垚鎸夐挳锛宮aEndTime鏈夊�兼椂绂佺敤 -->
+				<button :class="maEndTime ? 'btn-disabled' : 'btn-blue'"
+						:disabled="!!maEndTime"
+						@click="!maEndTime && setMaEndTime">
+					璋冩満瀹屾垚锛�=妫�楠岄�氳繃锛�
+				</button>
+				<input class="txt-inp" v-model="maEndTime" placeholder="棣栨棣栨纭閫氳繃鍐欏叆" disabled="true" />
+			</view>
+		</view>
 
 		<!-- 搴曢儴淇濆瓨/鍙栨秷鎸夐挳 -->
 		<view class="bottom-section">
 			<button class="save-btn" v-if="!maEndTime" @click="save">淇濆瓨骞剁敓鏁�</button>
 			<!-- <button class="save-btn" @click="save">淇濆瓨骞剁敓鏁�</button> -->
-			<button class="btn-disabled" v-else  >淇濆瓨骞剁敓鏁�</button>
+			<button class="btn-disabled" v-else>淇濆瓨骞剁敓鏁�</button>
 			<button class="cancel-btn" @click="cancel">鍙栨秷</button>
 		</view>
 
@@ -89,7 +124,6 @@
 			// 	}
 			// }
 
-
 			if (!this.orderId && !this.orderNo) {
 				return;
 			}
@@ -97,9 +131,12 @@
 			this.findByOrderId();
 		},
 		methods: {
-            setStartTime() {
-                this.maStartTime = this.$getDate('yyyy-mm-dd hh24:mi:ss');
-            },
+			setMaStartTime() {
+				this.maStartTime = this.$getDate('yyyy-mm-dd hh24:mi:ss');
+			},
+			setMaEndTime() {
+				this.maEndTime = this.$getDate('yyyy-mm-dd hh24:mi:ss');
+			},
 			refresh() {
 				this.findByOrderId(); // This will reload the data for the current order
 			},
@@ -112,7 +149,9 @@
 				this.$post({
 					url: "/MesOrderSta/ChangeMachineTime",
 					data: {
+						maStartTime: this.maStartTime, // 鏂板璋冩満鏃堕棿
 						maShoutTime: this.maShoutTime,
+						maEndTime: this.maEndTime, // 鏂板璋冩満瀹屾垚鏃堕棿
 						id: this.statusForm.id,
 						orderId: this.orderId,
 						machineNo: this.machineNo,
@@ -130,6 +169,8 @@
 			},
 			cancel() {
 				this.maShoutTime = this.statusForm.maShoutTime;
+				this.maStartTime = this.statusForm.maStartTime;
+				this.maEndTime = this.statusForm.maEndTime;
 			},
 			stateCheck(item) {
 				switch (item) {

--
Gitblit v1.9.3