Commit c32bac54 by liangjianmin

fix(stockRecheck): 修复旧标签开关逻辑和批次号截取

- 添加旧标签开关切换赋值逻辑
- 仅当旧标签开启且为自营仓库时截取入库批次号前8位
- 修改批量扫描和单个输入对应的批次号更新逻辑
- 保证文本输入时批次号正确更新及状态同步
parent 15e7f47e
Showing with 9 additions and 3 deletions
......@@ -780,7 +780,8 @@
switchChange(e, type) {
console.log('switch 发生 change 事件,携带值为', e.detail.value);
if (type == 1) {
// 旧标签开关切换
this.old_Label = e.detail.value;
} else {
this.is_batch = e.detail.value;
//重置相关数据
......@@ -1109,10 +1110,15 @@
this.input_flag_box_name = true;
this.getData();
} else if (type == 2) {
//入库批次号为自营仓库的时候,旧标签开启状态,输入文本后自动截取前8位,。
//入库批次号为自营仓库的时候,只有旧标签开启状态才截取前8位,关闭状态不截取
if (this.warehouse_id == 9 && this.old_Label) {
val = getFirstEightChars(val);
// 更新对应的输入框值
if (this.is_batch) {
this.search_keyword = val;
} else {
this.searchParams.stock_in_batch_sn = val;
}
}
//入库批次号 开启批量扫描
......
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