| | |
| | | //此js文件是用来自定义扩展业务代码,可以扩展一些自定义页面或者重新配置生成的代码 |
| | | import RobotSelect from './extend/RobotSelect.vue'; |
| | | |
| | | let extension = { |
| | | components: { |
| | | //查询界面扩展组件 |
| | | gridHeader: '', |
| | | gridBody: '', |
| | | gridBody: RobotSelect, |
| | | gridFooter: '', |
| | | //新建、编辑弹出框扩展组件 |
| | | modelHeader: '', |
| | |
| | | }, |
| | | |
| | | // 托盘组盘操作 |
| | | async handleBind(row) { |
| | | try { |
| | | await this.$confirm(`确认执行托盘组盘操作?\n托盘编号:${row.palletCode}`, "组盘确认", { |
| | | confirmButtonText: "确认", |
| | | cancelButtonText: "取消", |
| | | type: "warning" |
| | | }); |
| | | |
| | | const result = await this.http.post("/api/StockInfoDetail/BindContainer", { |
| | | palletCode: row.palletCode |
| | | }, "正在调用MES接口..."); |
| | | |
| | | if (result.status) { |
| | | this.$Message.success(result.message || "托盘组盘成功"); |
| | | this.$refs.table.load(); |
| | | } else { |
| | | this.$error(result.message || "托盘组盘失败"); |
| | | } |
| | | } catch (error) { |
| | | if (error !== "cancel") { |
| | | this.$error(error.message || "网络错误,请稍后重试"); |
| | | } |
| | | } |
| | | handleBind(row) { |
| | | this.$refs.gridBody.open('bind', row); |
| | | }, |
| | | |
| | | // 托盘进站操作 |
| | |
| | | }, |
| | | |
| | | // 托盘拆盘操作 |
| | | async handleUnbind(row) { |
| | | try { |
| | | await this.$confirm(`确认执行托盘拆盘操作?\n托盘编号:${row.palletCode}`, "拆盘确认", { |
| | | confirmButtonText: "确认", |
| | | cancelButtonText: "取消", |
| | | type: "warning" |
| | | }); |
| | | |
| | | const result = await this.http.post("/api/StockInfoDetail/UnbindContainer", { |
| | | palletCode: row.palletCode, |
| | | }, "正在调用MES接口..."); |
| | | |
| | | if (result.status) { |
| | | this.$Message.success(result.message || "托盘拆盘成功"); |
| | | this.$refs.table.load(); |
| | | } else { |
| | | this.$error(result.message || "托盘拆盘失败"); |
| | | } |
| | | } catch (error) { |
| | | if (error !== "cancel") { |
| | | this.$error(error.message || "网络错误,请稍后重试"); |
| | | } |
| | | } |
| | | handleUnbind(row) { |
| | | this.$refs.gridBody.open('unbind', row); |
| | | }, |
| | | |
| | | onInited() { |