feat: 批号追加工段标识2

This commit is contained in:
caoqianming 2025-04-21 13:22:39 +08:00
parent 82587b1736
commit 2ea3dc79cb
1 changed files with 3 additions and 3 deletions

View File

@ -32,6 +32,9 @@ def generate_new_batch(old_batch: str, mlog: Mlog):
supplier = mlog.supplier
mgroup = mlog.mgroup
process = mgroup.process
if mgroup.batch_append_code:
if mgroup.code:
new_batch = f'{new_batch}>{mgroup.code}'
if mlog.mtype == Mlog.MTYPE_OUT:
supplier_number = supplier.number if supplier else ''
if supplier_number:
@ -42,9 +45,6 @@ def generate_new_batch(old_batch: str, mlog: Mlog):
new_batch = f'{new_batch}>{number}'
if mlog.index:
new_batch = f'{new_batch}>{mlog.index}'
if mgroup.batch_append_code:
if mgroup.code:
new_batch = f'{new_batch}>{mgroup.code}'
return new_batch
def find_material_can_change(material: Material, mgroup_to: Mgroup):