fix cas de base

This commit is contained in:
Jean-Marie Favreau 2024-04-24 17:01:09 +02:00
parent 510ce9f69c
commit 5822c7807c

View File

@ -143,7 +143,12 @@ class EventFilter(django_filters.FilterSet):
return [] return []
def get_recurrence_filtering(self): def get_recurrence_filtering(self):
if "recurrences" in self.form.cleaned_data: if "recurrences" in self.form.cleaned_data:
return dict(self.RECURRENT_CHOICES)[self.form.cleaned_data["recurrences"]] d = dict(self.RECURRENT_CHOICES)
v = self.form.cleaned_data["recurrences"]
if v in d:
return d[v]
else:
return ""
else: else:
return "" return ""