| | |
| | | <template> |
| | | <view> |
| | | <view class="code"> |
| | | <view class="code"> |
| | | <view class="item"> |
| | | <view class="code-decs">入库站点:</view> |
| | | <input type="text" placeholder=" 扫码 / 输入" v-model="orgSite" :focus="barcodeFocus"> |
| | | <uni-data-select name='orgSite' v-model="orgSite" :localdata="staList" |
| | | @change="change"></uni-data-select> |
| | | </view> |
| | | <view class="item"> |
| | | <view class="code-decs">托盘码:</view> |
| | | <input type="text" placeholder=" 扫码 / 输入" v-model="barcode" > |
| | | <input type="text" placeholder=" 扫码 / 输入" v-model="barcode"> |
| | | </view> |
| | | <!-- <view class="item"> |
| | | <view class="code-decs">目标库位:</view> |
| | | <input type="text" placeholder=" 扫码 / 输入" v-model="tarSite" > |
| | | </view> --> |
| | | <view class="item"> |
| | | <uni-data-checkbox mode="button" multiple v-model="checkbox2" :localdata="hobby"></uni-data-checkbox> |
| | | <!-- <uni-data-checkbox mode="tag" multiple v-model="checkbox2" :localdata="hobby"></uni-data-checkbox> --> |
| | | </view> |
| | | </view> |
| | | <view class="mat-list-title"> |
| | | </view> |
| | |
| | | </view> |
| | | <!-- 弹窗 --> |
| | | <!-- 修改数量 --> |
| | | |
| | | |
| | | <!-- 移除确认 --> |
| | | <view> |
| | | <!-- 提示窗示例 --> |
| | |
| | | barcode: '', |
| | | orderNo: '', |
| | | dataList: [], |
| | | checkbox2: [], |
| | | hobby: [{ |
| | | text: '新台车入库', |
| | | value: 1 |
| | | }], |
| | | count: 0, |
| | | rowNum: '', |
| | | matnr: '', |
| | |
| | | matFocus: false, |
| | | matData: '', |
| | | removeNum: 0, |
| | | locNo:"", |
| | | orgSite:'', |
| | | tarSite:'', |
| | | staList:[], |
| | | locNo: "", |
| | | orgSite: '', |
| | | tarSite: '', |
| | | staList: [], |
| | | } |
| | | }, |
| | | onLoad() { |
| | |
| | | this.baseUrl = uni.getStorageSync('baseUrl'); |
| | | this.token = uni.getStorageSync('token'); |
| | | }, |
| | | mounted() { |
| | | mounted() { |
| | | // this.tarSite = uni.getStorageSync('tarSite') |
| | | }, |
| | | methods: { |
| | | change(e) { |
| | | console.log('单选值:', e); |
| | | this.orgSite = e |
| | | }, |
| | | messageToggle(type) { |
| | | this.msgType1 = type |
| | | this.$refs.message.open() |
| | |
| | | barcodeInput() { |
| | | // 不设置定时器 会出现扫入的字符串不全 |
| | | setTimeout(() => { |
| | | var len = this.barcode.length |
| | | var len = this.barcode.length |
| | | this.focuss() |
| | | }, 200) |
| | | }, |
| | |
| | | let that = this |
| | | let staResults = []; |
| | | uni.request({ |
| | | url: that.baseUrl + '/mobile/cache/locs', |
| | | url: that.baseUrl + '/mobile/cache/sites/5', |
| | | header: { |
| | | 'token':uni.getStorageSync('token') |
| | | 'token': uni.getStorageSync('token') |
| | | }, |
| | | method: 'GET', |
| | | success(result) { |
| | |
| | | if (result.code === 200 && result.data) { |
| | | staResults.push(...result.data); |
| | | staResults.forEach(item => { |
| | | that.staList.push(item?.locNo) |
| | | that.staList.push({ |
| | | value: item.devNo, |
| | | text: item.devNo |
| | | }) |
| | | }) |
| | | } else if (result.code == 403) { |
| | | uni.showToast({ |
| | |
| | | }); |
| | | that.matnr = '' |
| | | }, |
| | | checkMat(mat) { |
| | | checkMat(mat) { |
| | | this.dataList = mat |
| | | }, |
| | | // 修改批号 |
| | |
| | | }, |
| | | // 列表移除按钮 |
| | | remove(item, i, type) { |
| | | this.removeNum = i |
| | | this.removeNum = i |
| | | this.msgType = type |
| | | this.title = '警告' |
| | | this.content = '是否移除当前商品!' |
| | |
| | | this.messageText = "产线站为空" |
| | | this.messageToggle('error') |
| | | return; |
| | | } |
| | | } |
| | | uni.request({ |
| | | url: that.baseUrl + '/mobile/cache/agv/call', |
| | | data: JSON.stringify({ |
| | |
| | | if (res.code === 200) { |
| | | that.resst(); |
| | | that.messageText = "呼叫成功" |
| | | that.messageToggle('success') |
| | | that.messageToggle('success') |
| | | } else if (res.code == 403) { |
| | | that.messageText = res.msg |
| | | that.messageToggle('error') |
| | |
| | | resst() { |
| | | this.orgSite = '' |
| | | this.dataList = [] |
| | | |
| | | |
| | | |
| | | |
| | | }, |
| | | } |
| | | } |
| | |
| | | text-align: center; |
| | | box-shadow: 0px 0px 10px 0px rgba(0, 0, 0, 0.2); |
| | | } |
| | | </style> |
| | | </style> |