update hatching

This commit is contained in:
2026-02-07 15:43:21 +03:30
parent 54fdfea058
commit 8bf7ab61e4

View File

@@ -806,7 +806,8 @@ class HatchingsViewSet(viewsets.ModelViewSet):
'MenuUserAccess', 'LogTableName', 'LogTableAlias', 'PageTitle',
'PartIdCode', 'UnitTypeName'
]
if int(request.data['GoodSum']['loadingSum ']) > 0:
good_sum = request.data.get('GoodSum', [])
if int(good_sum.get('loadingSum ')) > 0:
for key in same_keys:
if key in request.data and request.data[key] is not None:
poultry_data[key] = request.data[key]