Merge branch 'master' of https://e.coding.net/ctcdevteam/ehs/ehs_server
This commit is contained in:
commit
ce54f326ee
|
@ -255,6 +255,7 @@ class MIOItemViewSet(CustomListModelMixin, BulkCreateModelMixin, BulkDestroyMode
|
||||||
"mio__type": ["exact", "in"],
|
"mio__type": ["exact", "in"],
|
||||||
"mio__inout_date": ["gte", "lte", "exact"],
|
"mio__inout_date": ["gte", "lte", "exact"],
|
||||||
"material": ["exact"],
|
"material": ["exact"],
|
||||||
|
"material__type": ["exact"],
|
||||||
"test_date": ["isnull", "exact"]
|
"test_date": ["isnull", "exact"]
|
||||||
}
|
}
|
||||||
ordering = ['create_time']
|
ordering = ['create_time']
|
||||||
|
|
|
@ -921,6 +921,8 @@ def handover_revert(handover:Handover):
|
||||||
handover_type = handover.type
|
handover_type = handover.type
|
||||||
handover_mtype = handover.mtype
|
handover_mtype = handover.mtype
|
||||||
if handover_type in [Handover.H_NORMAL, Handover.H_REPAIR] and handover_mtype == Handover.H_NORMAL:
|
if handover_type in [Handover.H_NORMAL, Handover.H_REPAIR] and handover_mtype == Handover.H_NORMAL:
|
||||||
|
pass
|
||||||
|
else:
|
||||||
raise ParseError('该交接单不支持撤销!')
|
raise ParseError('该交接单不支持撤销!')
|
||||||
handoverb_qs = Handoverb.objects.filter(handover=handover)
|
handoverb_qs = Handoverb.objects.filter(handover=handover)
|
||||||
material = handover.material
|
material = handover.material
|
||||||
|
|
|
@ -746,6 +746,9 @@ class MlogbOutViewSet(UpdateModelMixin, CustomGenericViewSet):
|
||||||
|
|
||||||
@transaction.atomic
|
@transaction.atomic
|
||||||
def perform_update(self, serializer):
|
def perform_update(self, serializer):
|
||||||
|
material_out = serializer.validated_data.get('material_out')
|
||||||
|
if material_out and material_out.tracking == Material.MA_TRACKING_SINGLE:
|
||||||
|
raise ParseError("单件产品不支持直接修改")
|
||||||
ins:Mlogb = serializer.save()
|
ins:Mlogb = serializer.save()
|
||||||
ins.mlog.cal_mlog_count_from_mlogb()
|
ins.mlog.cal_mlog_count_from_mlogb()
|
||||||
|
|
||||||
|
|
|
@ -103,11 +103,12 @@ class Wpr(BaseModel):
|
||||||
if is_create:
|
if is_create:
|
||||||
ins.material_start = wm.material
|
ins.material_start = wm.material
|
||||||
WprDefect.objects.filter(wpr=ins).delete()
|
WprDefect.objects.filter(wpr=ins).delete()
|
||||||
if wm.defect:
|
|
||||||
WprDefect.objects.create(wpr=ins, defect=wm.defect, is_main=True)
|
|
||||||
if add_version:
|
if add_version:
|
||||||
ins.version = ins.version + 1
|
ins.version = ins.version + 1
|
||||||
ins.save()
|
ins.save()
|
||||||
|
if wm:
|
||||||
|
if wm.defect:
|
||||||
|
WprDefect.objects.create(wpr=ins, defect=wm.defect, is_main=True)
|
||||||
if ftest:
|
if ftest:
|
||||||
# 通过检验变更其缺陷项
|
# 通过检验变更其缺陷项
|
||||||
WprDefect.objects.filter(wpr=ins).delete()
|
WprDefect.objects.filter(wpr=ins).delete()
|
||||||
|
|
11
changelog.md
11
changelog.md
|
@ -1,3 +1,14 @@
|
||||||
|
## 2.6.2025062015
|
||||||
|
- feat: 新增功能
|
||||||
|
- 增加交接撤回功能 [caoqianming]
|
||||||
|
- mlogbin的bug [caoqianming]
|
||||||
|
- mioitem返回mio数据添加单价字段 [caoqianming]
|
||||||
|
- 物料增加主库位号 [caoqianming]
|
||||||
|
- wmaterial添加can_handover字段 [caoqianming]
|
||||||
|
- fix: 问题修复
|
||||||
|
- wpr不合格的话先save再创建wm.defect [caoqianming]
|
||||||
|
- wpm/service 优化煤粉热值获取方式 [zty]
|
||||||
|
- mioitem price 计算bug [caoqianming]
|
||||||
## 2.6.2025061715
|
## 2.6.2025061715
|
||||||
- feat: 新增功能
|
- feat: 新增功能
|
||||||
- mlogbin的编辑与mlogbout的联动 [caoqianming]
|
- mlogbin的编辑与mlogbout的联动 [caoqianming]
|
||||||
|
|
|
@ -35,7 +35,7 @@ sys.path.insert(0, os.path.join(BASE_DIR, 'apps'))
|
||||||
ALLOWED_HOSTS = ['*']
|
ALLOWED_HOSTS = ['*']
|
||||||
|
|
||||||
SYS_NAME = '星途工厂综合管理系统'
|
SYS_NAME = '星途工厂综合管理系统'
|
||||||
SYS_VERSION = '2.6.2025061715'
|
SYS_VERSION = '2.6.2025062015'
|
||||||
X_FRAME_OPTIONS = 'SAMEORIGIN'
|
X_FRAME_OPTIONS = 'SAMEORIGIN'
|
||||||
|
|
||||||
# Application definition
|
# Application definition
|
||||||
|
|
Loading…
Reference in New Issue