| | |
| | | "navigationBarTitleText" : "订单组托", |
| | | "enablePullDownRefresh" : false |
| | | } |
| | | }, |
| | | { |
| | | "path" : "pages/WCS/wcsButton", |
| | | "style" : |
| | | { |
| | | "navigationBarTitleText" : "WCS按钮" |
| | | } |
| | | } |
| | | ], |
| | | "globalStyle": { |
New file |
| | |
| | | <template> |
| | | <view> |
| | | <scroll-view scroll-y class="page"> |
| | | <view class="tag-list"> |
| | | <picker mode="selector" :range="list" @change="onChange($event)"> |
| | | <view class="picker"> |
| | | {{sta}} 叠盘机 |
| | | </view> |
| | | </picker> |
| | | |
| | | </view> |
| | | <view class="tag-list"> |
| | | <button type="primary" @click="stackBack">空板回退</button> |
| | | </view> |
| | | <view class="tag-list"> |
| | | <button type="primary" @click="stackOut">叠盘出库</button> |
| | | </view> |
| | | <view class="tag-list"> |
| | | <button type="primary" @click="stackOut2">叠满入库</button> |
| | | </view> |
| | | |
| | | </scroll-view> |
| | | </view> |
| | | |
| | | </template> |
| | | |
| | | <script> |
| | | export default { |
| | | data() { |
| | | return { |
| | | wcsbaseUrl:'', |
| | | list:["114","103"], |
| | | sta:'103', |
| | | msgType: 'success', |
| | | messageText: '', |
| | | title: '', |
| | | content: '', |
| | | } |
| | | }, |
| | | onShow() { |
| | | this.wcsbaseUrl = uni.getStorageSync('wcsBaseUrl'); |
| | | }, |
| | | methods: { |
| | | onChange(e) { |
| | | this.sta = this.list[e.detail.value]; |
| | | }, |
| | | stackBack(){ |
| | | var that = this |
| | | uni.showModal({ |
| | | title:'提示', |
| | | content: that.sta+'站确认执行空板回退吗?', |
| | | success: (res) => { |
| | | if (res.confirm) { |
| | | uni.request({ |
| | | url: that.wcsbaseUrl + '/console/stackBack', |
| | | data: JSON.stringify({ |
| | | devpNo: that.sta |
| | | }), |
| | | method: 'POST', |
| | | header: { |
| | | 'token': uni.getStorageSync('token') |
| | | }, |
| | | success(result) { |
| | | var res = result.data |
| | | if (res.code === 200) { |
| | | uni.showToast({ |
| | | title:'操作成功', |
| | | icon:'success', |
| | | duration:2000 |
| | | }) |
| | | } else if (res.code == 403) { |
| | | that.messageText = res.msg |
| | | that.messageToggle('error') |
| | | setTimeout(() => { |
| | | uni.reLaunch({ |
| | | url: '../login/login' |
| | | }); |
| | | }, 1000); |
| | | } else { |
| | | uni.showToast({ |
| | | title:'操作失败', |
| | | icon:'error', |
| | | duration:2000 |
| | | }) |
| | | } |
| | | } |
| | | }); |
| | | } else if (res.cancel) { |
| | | } |
| | | } |
| | | }) |
| | | }, |
| | | stackOut(){ |
| | | var that = this |
| | | var devpNo = that.sta == '103'?'123':'122' |
| | | uni.showModal({ |
| | | title:'提示', |
| | | content: that.sta+'站确认执行叠盘出库吗?', |
| | | success: (res) => { |
| | | if (res.confirm) { |
| | | uni.request({ |
| | | url: that.wcsbaseUrl + '/console/stackOut', |
| | | data: JSON.stringify({ |
| | | devpNo: devpNo |
| | | }), |
| | | method: 'POST', |
| | | header: { |
| | | 'token': uni.getStorageSync('token') |
| | | }, |
| | | success(result) { |
| | | var res = result.data |
| | | if (res.code === 200) { |
| | | uni.showToast({ |
| | | title:'操作成功', |
| | | icon:'success', |
| | | duration:2000 |
| | | }) |
| | | } else if (res.code == 403) { |
| | | that.messageText = res.msg |
| | | that.messageToggle('error') |
| | | setTimeout(() => { |
| | | uni.reLaunch({ |
| | | url: '../login/login' |
| | | }); |
| | | }, 1000); |
| | | } else { |
| | | uni.showToast({ |
| | | title:'操作失败', |
| | | icon:'error', |
| | | duration:2000 |
| | | }) |
| | | } |
| | | } |
| | | }); |
| | | } else if (res.cancel) { |
| | | } |
| | | } |
| | | }) |
| | | }, |
| | | stackOut2(){ |
| | | var that = this |
| | | var devpNo = that.sta == '103'?'104':'115' |
| | | uni.showModal({ |
| | | title:'提示', |
| | | content: that.sta+'站确认执行叠满入库吗?', |
| | | success: (res) => { |
| | | if (res.confirm) { |
| | | uni.request({ |
| | | url: that.wcsbaseUrl + '/console/stackOut', |
| | | data: JSON.stringify({ |
| | | devpNo: devpNo |
| | | }), |
| | | method: 'POST', |
| | | header: { |
| | | 'token': uni.getStorageSync('token') |
| | | }, |
| | | success(result) { |
| | | var res = result.data |
| | | if (res.code === 200) { |
| | | uni.showToast({ |
| | | title:'操作成功', |
| | | icon:'success', |
| | | duration:2000 |
| | | }) |
| | | } else if (res.code == 403) { |
| | | that.messageText = res.msg |
| | | that.messageToggle('error') |
| | | setTimeout(() => { |
| | | uni.reLaunch({ |
| | | url: '../login/login' |
| | | }); |
| | | }, 1000); |
| | | } else { |
| | | uni.showToast({ |
| | | title:'操作失败', |
| | | icon:'error', |
| | | duration:2000 |
| | | }) |
| | | } |
| | | } |
| | | }); |
| | | } else if (res.cancel) { |
| | | } |
| | | } |
| | | }) |
| | | }, |
| | | } |
| | | } |
| | | </script> |
| | | |
| | | <style> |
| | | .tag-list { |
| | | width: 94%; |
| | | min-height: 30px; |
| | | margin: 10px auto; |
| | | background-color: #FFF; |
| | | border-radius: 5px; |
| | | box-shadow: 0 5upx 20upx rgba(0, 0, 0, 0.2); |
| | | } |
| | | .picker { |
| | | border-radius: 5px; |
| | | padding: 10px; |
| | | background-color: #fff; |
| | | text-align: center; |
| | | } |
| | | </style> |
| | |
| | | url: '/pakin/pakin' |
| | | }, |
| | | { |
| | | title: '拣料站到站', |
| | | name: 'leftover', |
| | | title: 'WCS按钮', |
| | | name: 'wcsButton', |
| | | color: 'orange', |
| | | cuIcon: 'pullup', |
| | | url: '/pakin/leftovers' |
| | | url: '/WCS/wcsButton' |
| | | }, |
| | | // { |
| | | // title: '再次拣料', |
| | |
| | | <!-- logo --> |
| | | <view class="logo"> |
| | | <view class="logo-box"> |
| | | <image src="../../static/img/logo.png" mode="aspectFit"></image> |
| | | <image src="../../static/img/zy_logo.png" mode="aspectFit"></image> |
| | | </view> |
| | | </view> |
| | | <view class="content"> |
| | |
| | | <view class="popup-item-left">项目:</view> |
| | | <view class="popup-item-right"><input type="text" v-model="url.project"></view> |
| | | </view> |
| | | <view class="popup-item"> |
| | | <view class="popup-item-left">WCSIP:</view> |
| | | <view class="popup-item-right"><input type="text" v-model="url.wcsIp"></view> |
| | | </view> |
| | | <view class="popup-item"> |
| | | <view class="popup-item-left">WCS端口:</view> |
| | | <view class="popup-item-right"><input type="text" v-model="url.wcsPort"></view> |
| | | </view> |
| | | <view class="popup-item"> |
| | | <view class="popup-item-left">WCS项目:</view> |
| | | <view class="popup-item-right"><input type="text" v-model="url.wcsProject"></view> |
| | | </view> |
| | | <view class="btn"> |
| | | <view class="btn-left" @click="close">取消</view> |
| | | <view class="btn-right" @click="settingConfirm">确认</view> |
| | |
| | | project: '' |
| | | }, |
| | | baseUrl: '', |
| | | wcsBaseUrl: '', |
| | | user: { |
| | | userName: '', |
| | | password: '', |
| | |
| | | // 保存ip |
| | | settingConfirm() { |
| | | this.baseUrl = "http://" + this.url.ip + ':' + this.url.port + '/' + this.url.project |
| | | this.wcsBaseUrl = "http://" + this.url.wcsIp + ':' + this.url.wcsPort + '/' + this.url.wcsProject |
| | | uni.setStorageSync('baseUrl', this.baseUrl); |
| | | uni.setStorageSync('wcsBaseUrl',this.wcsBaseUrl) |
| | | uni.setStorageSync('url', this.url); |
| | | this.$refs.inputDialog.close() |
| | | }, |
| | |
| | | font-size: 14px; |
| | | } |
| | | .popup-item-left { |
| | | width: 16vw; |
| | | width: 18vw; |
| | | padding-right: 20rpx; |
| | | text-align: right; |
| | | color: #606266; |