| | |
| | | _this.getContainerType() |
| | | },500) |
| | | |
| | | _this.getWrkMast() |
| | | _this.getWrkMast(res.data.records[0].barcode) |
| | | } else if (res.code == 403) { |
| | | uni.showToast({ title: res.msg, icon: "error", position: 'top' }) |
| | | setTimeout(() => { uni.reLaunch({ url: '../login/login' }); }, 1000); |
| | |
| | | this.containerType = option |
| | | }, |
| | | // 查询工作档 |
| | | getWrkMast() { |
| | | getWrkMast(barcode) { |
| | | let _this = this |
| | | uni.request({ |
| | | url: `${_this.baseUrl}/agv/wrkMast/list/auth`, |
| | |
| | | success(res) { |
| | | res = res.data |
| | | if (res.code === 200 && res.data.records.length > 0) { |
| | | if (res.data.records[0].ioType == 1) { |
| | | res.data.records[0]['ioTitle'] = '入库' |
| | | } else if (res.data.records[0].ioType == 10) { |
| | | res.data.records[0]['ioTitle'] = '空板入库' |
| | | } else if (res.data.records[0].ioType == 53) { |
| | | res.data.records[0]['ioTitle'] = '拣料回库' |
| | | } else if (res.data.records[0].ioType == 101) { |
| | | res.data.records[0]['ioTitle'] = '全板出库' |
| | | _this.btnType = 'out' |
| | | } else if (res.data.records[0].ioType == 103) { |
| | | res.data.records[0]['ioTitle'] = '拣料出库' |
| | | _this.btnType = 'pick' |
| | | } else if (res.data.records[0].ioType == 110) { |
| | | res.data.records[0]['ioTitle'] = '空板出库' |
| | | let mast = null |
| | | for (let wrkMast of res.data.records) { |
| | | if (wrkMast.ioType == 1) { |
| | | wrkMast['ioTitle'] = '入库' |
| | | } else if (wrkMast.ioType == 10) { |
| | | wrkMast['ioTitle'] = '空板入库' |
| | | } else if (wrkMast.ioType == 53) { |
| | | wrkMast['ioTitle'] = '拣料回库' |
| | | } else if (wrkMast.ioType == 101) { |
| | | wrkMast['ioTitle'] = '全板出库' |
| | | _this.btnType = 'out' |
| | | } else if (wrkMast.ioType == 103) { |
| | | wrkMast['ioTitle'] = '拣料出库' |
| | | _this.btnType = 'pick' |
| | | } else if (wrkMast.ioType == 110) { |
| | | wrkMast['ioTitle'] = '空板出库' |
| | | } |
| | | if (wrkMast.barcode == barcode) { |
| | | mast = wrkMast |
| | | } |
| | | } |
| | | _this.wrkMast = res.data.records[0] |
| | | _this.getWrkDetl(_this.wrkMast.wrkNo) |
| | | |
| | | _this.wrkMast = mast |
| | | _this.getWrkDetl(mast.wrkNo) |
| | | } else if (res.code === 200 && res.data.records.length == 0) { |
| | | _this.wrkMast = null |
| | | _this.wrkDetls = [] |