检测bug

This commit is contained in:
caoqianming 2021-11-16 17:08:32 +08:00
parent 3df4c68f47
commit 43d297881e
1 changed files with 2 additions and 1 deletions

View File

@ -24,6 +24,7 @@ from rest_framework import exceptions, serializers
from apps.wpm.services import WpmServies
from django.utils import timezone
import uuid
# Create your views here.
class WPlanViewSet(ListModelMixin, GenericViewSet):
"""
@ -164,7 +165,7 @@ class WProductViewSet(ListModelMixin, GenericViewSet):
if obj.is_testok:
wproduct.act_state = WProduct.WPR_ACT_STATE_OK
if wproduct.number is None: # 产生半成品编号
wproduct.number = 'BCP' + str(timezone.now())
wproduct.number = uuid.uuid4()
wproduct.save()
# 更新子计划状态
# 获取该子计划主产品数, 更新进度