From b9b004d4a745ecdc7c5b5e8d11c5f180d61c3b3a Mon Sep 17 00:00:00 2001
From: whycq <10027870+whycq@user.noreply.gitee.com>
Date: 星期一, 10 七月 2023 12:51:30 +0800
Subject: [PATCH] #

---
 pages/AGV/AGVPakinOn.vue |    2 
 pages/AGV/AGVStart.vue   |   65 +++++++++++++++++++++++++++++---
 2 files changed, 59 insertions(+), 8 deletions(-)

diff --git a/pages/AGV/AGVPakinOn.vue b/pages/AGV/AGVPakinOn.vue
index f7872c4..9232328 100644
--- a/pages/AGV/AGVPakinOn.vue
+++ b/pages/AGV/AGVPakinOn.vue
@@ -147,7 +147,7 @@
 				token: '',
 				barcode: '',
 				stationCode: '',
-				dataList: [],
+				dataList: [{}],
 				count: 0,
 				rowNum: '',
 				matnr: '',
diff --git a/pages/AGV/AGVStart.vue b/pages/AGV/AGVStart.vue
index 976d6fe..e89dbe3 100644
--- a/pages/AGV/AGVStart.vue
+++ b/pages/AGV/AGVStart.vue
@@ -6,23 +6,32 @@
 				<input type="text" placeholder=" 鎵爜 / 杈撳叆" v-model="barcode" :focus="barcodeFocus"
 					@input="barcodeInput()">
 			</view> -->
-			<view class="item">
+			<!-- <view class="item">
 				<view class="code-decs">鏆傚瓨浣�:</view>
 				<input type="text" placeholder=" 鎵爜 / 杈撳叆" v-model="stationCode" :focus="matFocus" @input="stationCodeInput()">
 				<view class="item-right">
-					<button></button>
+					<button></button> -->
 					<!-- <text style="text-align: right;color: #409EFF;" @click="selectMat()">鎻愬彇+</text> -->
 					<!-- <uni-icons type="right" color="#c1c1c1"></uni-icons> -->
-				</view>
+				<!-- </view>
+			</view> -->
+			<view class="item">
+				<view class="code-decs">妤煎彿:</view>
+				<uni-combox :candidates="floorList" placeholder="璇烽�夋嫨妤煎彿" v-model="floor" @input="getFloor"></uni-combox>
 			</view>
 		</view>
 		<view class="mat-list-title">
-			绔欑偣鍒楄〃
+			<view style="width: 200rpx;"></view>
+			<view style="-webkit-flex: 1;flex: 1;">鍟嗗搧鍒楄〃</view>
+			<view style="width: 200rpx;"><button size="mini" type="primary" @click="getChecked">鎻愬彇</button></view>
 		</view>
 		<scroll-view>
 			<view class="list" v-for="(item,i) in dataList" :key="i">
+				<view class="aside">
+					<checkbox :value="item.matnr" :checked="item.checked" @click="set(i)"/>
+				</view>
 				<view class="list-left" style="display: flex;justify-content: center;">
-					{{item}}
+					{{item.name}}
 				</view>
 				<view class="list-right">
 					<!-- <uni-icons type="compose" color="#9add8b" size="24" @click="revise(item,i)"></uni-icons> -->
@@ -109,7 +118,7 @@
 				token: '',
 				barcode: '',
 				stationCode: '',
-				dataList: [],
+				dataList: [{name:'123'},{name:'456'},{name:'123'},{name:'456'},{name:'123'},{name:'456'},{name:'123'},{name:'456'},{name:'123'},{name:'456'},{name:'123'},{name:'456'},{name:'123'},{name:'456'},{name:'123'},{name:'456'},{name:'123'},{name:'456'}],
 				count: 0,
 				rowNum: '',
 				matnr: '',
@@ -124,6 +133,8 @@
 				matFocus: false,
 				matData: '',
 				removeNum: 0,
+				floorList: [1,2,3],
+				floor: '',
 			}
 		},
 		onLoad() {
@@ -133,6 +144,35 @@
 			this.token = uni.getStorageSync('token');
 		},
 		methods: {
+			getChecked() {
+				var checkedList = []
+				for(var i = 0; i < this.dataList.length; i++) {
+					var t = !this.dataList[i].checked
+					if (this.dataList[i].checked) {
+						checkedList.push(this.dataList[i])
+					}
+				}
+				this.dataList = checkedList
+			},
+			set(e) {
+				var ck = this.dataList[e].checked
+				this.dataList[e].checked = ck ? false:true
+			},
+			getFloor() {
+				let that = this
+				uni.request({
+					url: that.baseUrl + '/mat/auth',
+					data: {
+						matnr: that.matnr
+					},
+					header: {
+						'token': uni.getStorageSync('token')
+					},
+					success(result) {
+				
+					}
+				});
+			},
 			messageToggle(type) {
 				this.msgType1 = type
 				this.$refs.message.open()
@@ -412,6 +452,16 @@
 <style>
 	@import url('../../static/css/wms.css/wms.css');
 
+	.list:first-child {
+		margin-top: 260rpx;
+	}
+	.aside {
+		width: 100rpx;
+		/* background-color: #303133; */
+		display: flex;
+		align-items: center;
+		justify-content: center;
+	}
 	.code {
 		width: 100%;
 		position: fixed;
@@ -450,8 +500,9 @@
 	}
 
 	.mat-list-title {
+		display: flex;
+		align-items: center;
 		height: 80rpx;
-		line-height: 80rpx;
 		width: 100%;
 		background-color: white;
 		position: fixed;

--
Gitblit v1.9.1