根据产品日志更新生产进度
This commit is contained in:
parent
d62a09a00c
commit
0b989f79b1
|
@ -75,7 +75,7 @@ class WpmServies(object):
|
|||
"""
|
||||
根据产品变动日志更新生产进度
|
||||
"""
|
||||
objs = WproductFlow.objects.filter(subporduction_plan=sp, is_lastlog=True)
|
||||
objs = WproductFlow.objects.filter(subproduction_plan=sp, is_lastlog=True)
|
||||
count_ok = objs.filter(act_state__in=[WProduct.WPR_ACT_STATE_INM,
|
||||
WProduct.WPR_ACT_STATE_OK, WProduct.WPR_ACT_STATE_SELLED]).count()
|
||||
count_real = objs.exclude(act_state__in=[WProduct.WPR_ACT_STATE_TORETEST,
|
||||
|
|
|
@ -194,6 +194,7 @@ class WProductViewSet(ListModelMixin, GenericViewSet):
|
|||
return queryset
|
||||
|
||||
@action(methods=['post'], detail=False, perms_map={'post':'*'}, serializer_class=WpmTestFormInitSerializer)
|
||||
@transaction.atomic
|
||||
def test_init(self, request, pk=None):
|
||||
"""
|
||||
检验记录创建及初始化
|
||||
|
|
Loading…
Reference in New Issue