Commit 700f3180 by LJM

理货确认-打印标签:箱,卡板都有值情况

parent cf59893b
Showing with 23 additions and 19 deletions
...@@ -107,9 +107,29 @@ ...@@ -107,9 +107,29 @@
}, },
onLoad(option) { onLoad(option) {
this.platform = getPlatform(); this.platform = getPlatform();
this.printParams.board_num = option.board_num || ''; this.printParams.board_num = Number(option.board_num) || ''; //箱
this.printParams.box_num = option.box_num || ''; this.printParams.box_num = Number(option.box_num) || ''; //板子
this.printParams.erp_order_sn = option.erp_order_sn || ''; this.printParams.erp_order_sn = option.erp_order_sn || ''; //入仓号
//停止搜索,节省系统资源
uni.stopBluetoothDevicesDiscovery({
success: res => {
console.log('停止搜索', JSON.stringify(res.errMsg));
}
});
try {
uni.removeStorageSync('device');
} catch (e) {
// error
}
//如果【理货确认-板/箱 均不为0】,则【打印标签】打印类型只继承入仓号,打印类型默认为【散箱】标签数量1 批次为0(保持原默认值)
if (this.printParams.box_num && this.printParams.board_num) {
this.form.erp_order_sn = this.printParams.erp_order_sn;
return false;
}
//如果【理货确认-箱】有数值,则【打印标签】打印类型为【散箱】并继承数据【标签数量】 //如果【理货确认-箱】有数值,则【打印标签】打印类型为【散箱】并继承数据【标签数量】
if (this.printParams.box_num) { if (this.printParams.box_num) {
...@@ -125,23 +145,7 @@ ...@@ -125,23 +145,7 @@
this.numberIndex = findIndexOrZero(this.numberArr, Number(this.printParams.board_num)); //匹配到卡板数就选中,否则就是默认0 this.numberIndex = findIndexOrZero(this.numberArr, Number(this.printParams.board_num)); //匹配到卡板数就选中,否则就是默认0
} }
//如果【理货确认-板/箱 均不为0】,则【打印标签】打印类型只继承入仓号,打印类型默认为【散箱】标签数量1 批次为0(保持原默认值)
if (this.printParams.box_num && this.printParams.board_num) {
this.form.erp_order_sn = this.printParams.erp_order_sn;
}
//停止搜索,节省系统资源
uni.stopBluetoothDevicesDiscovery({
success: res => {
console.log('停止搜索', JSON.stringify(res.errMsg));
}
});
try {
uni.removeStorageSync('device');
} catch (e) {
// error
}
}, },
onShow() { onShow() {
//获取已连接蓝牙设备信息 //获取已连接蓝牙设备信息
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment