From 104d0eb89b41a86f93de64403f7415dceca6d309 Mon Sep 17 00:00:00 2001 From: hfroot <9282816+hfroot@users.noreply.github.com> Date: Wed, 13 Nov 2024 10:36:07 +0100 Subject: [PATCH] =?UTF-8?q?Affiche=20:=20Si=20il=20y=20a=20pas=20de=20diag?= =?UTF-8?q?,=20indiquer=20qu'il=20y=20a=20pas=20de=20donn=C3=A9es=20(#4643?= =?UTF-8?q?)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- api/serializers/canteen.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/api/serializers/canteen.py b/api/serializers/canteen.py index cd1b05bbe..bcb8bc2ff 100644 --- a/api/serializers/canteen.py +++ b/api/serializers/canteen.py @@ -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