add - whole system of inventory entry in organization quotas stat

This commit is contained in:
2025-11-19 15:56:15 +03:30
parent 42c01f3eb5
commit 1bf6950ccb
9 changed files with 152 additions and 34 deletions

View File

@@ -33,6 +33,7 @@ class QuotaSerializer(serializers.ModelSerializer):
representation['quota_distributed'] = quota_weight_by_org['quota_distributed']
representation['remaining_weight'] = quota_weight_by_org['remaining_weight']
representation['been_sold'] = quota_weight_by_org['been_sold']
representation['inventory_received'] = quota_weight_by_org['inventory_received']
representation['distributions_number_by_me'] = instance.distributions_assigned.filter(
assigner_organization=org
).count()