update KillRequestViewSet
This commit is contained in:
@@ -3177,7 +3177,8 @@ class KillRequestViewSet(viewsets.ModelViewSet):
|
|||||||
recive_date = datetime.strptime(str(request.data['recive_date']), '%Y-%m-%d %H:%M:%S').date()
|
recive_date = datetime.strptime(str(request.data['recive_date']), '%Y-%m-%d %H:%M:%S').date()
|
||||||
total_unpaid_wage = get_finance_info(kill_house)['total_price']
|
total_unpaid_wage = get_finance_info(kill_house)['total_price']
|
||||||
slaughter_transactions = InternalTransaction.objects.filter(
|
slaughter_transactions = InternalTransaction.objects.filter(
|
||||||
kill_house=kill_house, status='completed',
|
Q(kill_house=kill_house) | Q(parent_kill_house=kill_house),
|
||||||
|
status='completed',
|
||||||
trash=False)
|
trash=False)
|
||||||
|
|
||||||
total_paid_wage += slaughter_transactions.aggregate(total=Sum('amount'))[
|
total_paid_wage += slaughter_transactions.aggregate(total=Sum('amount'))[
|
||||||
|
|||||||
Reference in New Issue
Block a user