fix: 变更单件产品的属性问题3

This commit is contained in:
caoqianming 2025-01-17 10:19:58 +08:00
parent d653caed1d
commit 6bcafcad3a
1 changed files with 4 additions and 1 deletions

View File

@ -288,9 +288,12 @@ class InmService:
ddict["batch_ofrom"] = i.batch
ddict["material_ofrom"] = i.material
count_change = i.count - i.count_notok
if field == "count":
count_change = i.count - i.count_notok
elif field == "count_notok":
count_change = getattr(i, field)
else:
raise ParseError("不支持该字段")
m_list = [(material, warehouse, i.batch, count_change, None, i)]
if tracking == Material.MA_TRACKING_SINGLE: