fix error 500
This commit is contained in:
parent
551c919a9f
commit
a382b9ce22
@ -126,7 +126,10 @@ class EventFilter(django_filters.FilterSet):
|
|||||||
return self.form.cleaned_data["status"]
|
return self.form.cleaned_data["status"]
|
||||||
|
|
||||||
def get_status_names(self):
|
def get_status_names(self):
|
||||||
|
if "status" in self.form.cleaned_data:
|
||||||
return [dict(Event.STATUS.choices)[s] for s in self.form.cleaned_data["status"]]
|
return [dict(Event.STATUS.choices)[s] for s in self.form.cleaned_data["status"]]
|
||||||
|
else:
|
||||||
|
return []
|
||||||
|
|
||||||
def is_active(self, only_categories=False):
|
def is_active(self, only_categories=False):
|
||||||
if only_categories:
|
if only_categories:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user