From 653d7cc01713b1517186de08944d1c8a929ba3ed Mon Sep 17 00:00:00 2001
From: zhou zhou <3272660260@qq.com>
Date: 星期二, 27 一月 2026 08:50:52 +0800
Subject: [PATCH] #匹配站点

---
 pages/emptyTray/inBound.vue |   35 ++++++++++++++++++++++++++++++++---
 1 files changed, 32 insertions(+), 3 deletions(-)

diff --git a/pages/emptyTray/inBound.vue b/pages/emptyTray/inBound.vue
index eaa1675..5664d7e 100644
--- a/pages/emptyTray/inBound.vue
+++ b/pages/emptyTray/inBound.vue
@@ -8,7 +8,7 @@
 			</view>
 			<view class="cu-form-group ">
 				<view class="title">鎺ラ┏绔欑偣</view>
-				<input placeholder="璇锋壂鎻忔帴椹崇珯鐐规潯鐮�" v-model="barcode" ></input>
+				<input placeholder="璇锋壂鎻忔帴椹崇珯鐐规潯鐮�" v-model="agvStationInput" @input="checkAgvStation"></input>
 			</view>
 		</form>
 
@@ -114,6 +114,8 @@
 				list: [],
 				range: [],
 				curCode: '',
+				agvStationInput: '', // AGV绔欑偣杈撳叆鍊�
+				agvStationName: '',
 				buttonPermissions: [] // 鎸夐挳鏉冮檺鍒楄〃
 			}
 		},
@@ -126,6 +128,33 @@
 			console.log('褰撳墠椤甸潰鎸夐挳鏉冮檺:', this.buttonPermissions);
 		},
 		methods: {
+			async checkAgvStation() {
+				const that = this
+				if (this.agvStationInput === '' || this.agvStationInput === null) {
+					uni.showToast({
+						title: '瀹瑰櫒鐮佷负绌�',
+						icon: 'none',
+						position: 'top'
+					})
+					return
+				}
+				const { code, data, msg } = await request('/check/agvStation', {
+					transferStationNo: this.agvStationInput
+				})
+				if (code === 200) {
+					this.agvStationName = data.stationName
+				} else {
+					uni.showToast({
+						title: msg,
+						icon: 'none',
+						position: 'top'
+					})
+					setTimeout(function () {
+						that.agvStationName = ''
+						that.agvStationInput = ''
+					}, 200)
+				}
+			},
 			async search() {
 				const {
 					code,
@@ -185,7 +214,7 @@
 					})
 					return ;
 				}
-				if(this.barcode === '' || this.barcode ===null){
+				if(this.agvStationName === '' || this.agvStationName ===null){
 					uni.showToast({
 						title: "鎺ラ┏绔欑爜涓嶈兘涓虹┖",
 						icon: "none",
@@ -198,7 +227,7 @@
 					msg
 				} = await request('/in/emptyContainer/warehousing',{
 						containerNo: this.container,
-						transferStationNo: this.barcode
+						transferStationNo: this.agvStationName
 					}
 				)
 				if (code === 200) {

--
Gitblit v1.9.1