feat: mlogbin的编辑与mlogbout的联动
This commit is contained in:
parent
95b10371b9
commit
1366f432ee
|
|
@ -789,7 +789,9 @@ class MlogbInUpdateSerializer(CustomModelSerializer):
|
||||||
if mlogb_defect_objects:
|
if mlogb_defect_objects:
|
||||||
MlogbDefect.objects.bulk_create(mlogb_defect_objects)
|
MlogbDefect.objects.bulk_create(mlogb_defect_objects)
|
||||||
# 只有普通工序的才可联动
|
# 只有普通工序的才可联动
|
||||||
|
material_out:Material = ins.mlog.material_out
|
||||||
route:Route = mlog.route
|
route:Route = mlog.route
|
||||||
|
if material_out.tracking == Material.MA_TRACKING_BATCH:
|
||||||
if route and route.process and route.process.mtype == Process.PRO_NORMAL:
|
if route and route.process and route.process.mtype == Process.PRO_NORMAL:
|
||||||
mlogbout_qs = Mlogb.objects.filter(mlog=ins.mlog, mlogb_from=ins)
|
mlogbout_qs = Mlogb.objects.filter(mlog=ins.mlog, mlogb_from=ins)
|
||||||
if mlogbout_qs.count() == 1:
|
if mlogbout_qs.count() == 1:
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue