From fdd5c0737d285fdf55dadd3d34aab1ead2d27940 Mon Sep 17 00:00:00 2001 From: whycq <10027870+whycq@user.noreply.gitee.com> Date: 星期六, 16 三月 2024 13:05:45 +0800 Subject: [PATCH] # --- pages/project/jmAGV/floorOne.vue | 117 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++- 1 files changed, 115 insertions(+), 2 deletions(-) diff --git a/pages/project/jmAGV/floorOne.vue b/pages/project/jmAGV/floorOne.vue index 10817db..a94ba37 100644 --- a/pages/project/jmAGV/floorOne.vue +++ b/pages/project/jmAGV/floorOne.vue @@ -11,6 +11,7 @@ <view class="zcard"> <view class="zcard-flex"> <view class="button-nk" style="background-color: brown;" @click="click('right')">涓嬫灦</view> + <view class="button-nk" style="background-color: brown;" @click="putOut('out2')">浠撳簱-婊℃墭鐩�(鍑哄簱)</view> </view> </view> @@ -29,6 +30,33 @@ <view class="popup3-input-title">{{tipsTitle}}</view> <view class="button-nk" @click="goUp(2)">2涓�</view> <view class="button-nk" @click="goUp(4)">4涓�</view> + </view> + </uni-popup> + </view> + + <view> + <uni-popup ref="inputPopup" type="dialog"> + <view class="popup3"> + <view class="popup3-input-title">{{tipsTitle}}</view> + <view class="popup3-input-box2" :class="item.chose" + v-if="!meterShow" v-for="item in emptyMatList" @click="chose(item.matnr)"> + <view> + {{item.maktx}} + </view> + </view> + <view class="popup3-input-box" v-if="meterShow"> + <text>{{desc}}:</text> + <view style="margin-left: 3rpx;"> + <input type="text" v-model="code"/> + </view> + </view> + <view class="popup3-input-box" v-if="meterShow"> + <text>绫虫暟:</text> + <view style="margin-left: 3rpx;"> + <input type="text" v-model="meter"/> + </view> + </view> + <view class="button-nk" @click="confirm(2)">纭畾</view> </view> </uni-popup> </view> @@ -56,7 +84,12 @@ btnTitle: '', type: '', tipsTitle: '', - item: {} + item: {}, + meterShow: false, + code: '', + emptyMatList: '', + meter: '' + } }, @@ -72,6 +105,38 @@ uni.redirectTo({ url: '/pages/project/jmAGV/home' }) + }, + // 婊$増鍑哄簱 + putOut(type) { + this.type = type + this.inputPopup() + }, + inputPopup() { + if (this.type == 'out1') { + this.tipsTitle = '绌烘墭鐩樺嚭搴�' + this.desc = '鐗╂枡鐮�' + this.meterShow = false + let that = this + uni.request({ + url: `${that.baseUrl}/agv/getEmptyMat`, + header: { 'token': uni.getStorageSync('token') }, + method: 'GET', + success(res) { + res = res.data + if (res.code === 200) { + res.data['chose'] = '' + that.emptyMatList = res.data + + } + } + }) + } else { + this.tipsTitle = '婊℃墭鐩樺嚭搴�' + this.desc = '璁㈠崟鍙�' + this.meterShow = true + this.$refs.inputPopup.open('center') + } + this.$refs.inputPopup.open('center') }, click(type) { if (type == 'left') { @@ -100,6 +165,22 @@ anfme: num } this.webServer(data) + }, + confirm() { + let data = {} + data = { + originLocal: '11-Q1', + targetLocal: '11-Q1', + type: this.type, + orderNo: this.code, + meter: this.meter + } + this.webServer(data) + setTimeout(()=>{ + this.$refs.inputPopup.close() + this.code = '' + this.meter = '' + },300) }, // 鎵�鏈夋湇鍔� webServer(data) { @@ -148,7 +229,7 @@ margin: 10rpx 0rpx; /* padding: 20rpx 70rpx; */ /* background-color: azure; */ - min-width: 150rpx; + min-width: 350rpx; /* margin: 0 auto; */ height: 50rpx; text-align: center; @@ -202,4 +283,36 @@ inset -2px -2px 2px rgba(255, 255, 255, .7), -2px -2px 2px rgba(0, 0, 0, .4); } + .popup3 { + background-color: #eee; + max-height: 80vw; + width: 50vw; + padding: 0 10vw; + display: flex; + flex-direction: column; + justify-content: space-around; + border-radius: 10rpx; + color: #565656; + } + .popup3-input-title { + text-align: center; + margin: 10rpx; + font-size: 18px; + font-weight: bold; + } + .popup3-input-box { + display: flex; + border: 1px solid #cecece; + border-radius: 5rpx; + padding: 2rpx 10rpx; + margin: 20rpx; + } + .popup3-input-box2 { + display: flex; + border: 1px solid #cecece; + border-radius: 5rpx; + padding: 2rpx 10rpx; + margin: 10rpx; + background-color: #FFF; + } </style> -- Gitblit v1.9.1