Skip to content

Commit

Permalink
Affiche : Si il y a pas de diag, indiquer qu'il y a pas de données (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
hfroot authored Nov 13, 2024
1 parent bf7a921 commit 104d0eb
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions api/serializers/canteen.py
Original file line number Diff line number Diff line change
Expand Up @@ -94,13 +94,13 @@ class Meta:

class BadgesSerializer(serializers.ModelSerializer):
year = serializers.IntegerField(source="latest_published_year")
appro = serializers.BooleanField(source="latest_published_appro_diagnostic.appro_badge", default=False)
waste = serializers.BooleanField(source="latest_published_service_diagnostic.waste_badge", default=False)
appro = serializers.BooleanField(source="latest_published_appro_diagnostic.appro_badge", default=None)
waste = serializers.BooleanField(source="latest_published_service_diagnostic.waste_badge", default=None)
diversification = serializers.BooleanField(
source="latest_published_service_diagnostic.diversification_badge", default=False
source="latest_published_service_diagnostic.diversification_badge", default=None
)
plastic = serializers.BooleanField(source="latest_published_service_diagnostic.plastic_badge", default=False)
info = serializers.BooleanField(source="latest_published_service_diagnostic.info_badge", default=False)
plastic = serializers.BooleanField(source="latest_published_service_diagnostic.plastic_badge", default=None)
info = serializers.BooleanField(source="latest_published_service_diagnostic.info_badge", default=None)

class Meta:
model = Canteen
Expand Down

0 comments on commit 104d0eb

Please sign in to comment.