update_plan_state_by_mtestok bug

This commit is contained in:
caoqianming 2022-01-07 09:52:56 +08:00
parent 7d033ca12c
commit ef46ddf7ab
1 changed files with 1 additions and 1 deletions

View File

@ -126,7 +126,7 @@ class WpmServies(object):
根据军检结果更新主计划状态
"""
# 计算计划军检合格数并进行状态变更
count_mtestok = WProduct.objects.filter(material=plan.product, iproduct_wproduct__ismtestok=True, is_deleted=False).count()
count_mtestok = WProduct.objects.filter(material=plan.product, ismtestok=True, is_deleted=False).count()
plan.count_mtestok = count_mtestok
if count_mtestok >= plan.count:
plan.state = ProductionPlan.PLAN_MTEST_DONE