exclude cancelled presentations from being slotted
This commit is contained in:
parent
4b6684b611
commit
51c35434f8
1 changed files with 1 additions and 1 deletions
|
@ -13,7 +13,7 @@ class SlotEditForm(forms.Form):
|
||||||
if content:
|
if content:
|
||||||
kwargs.setdefault("initial", {})["presentation"] = content
|
kwargs.setdefault("initial", {})["presentation"] = content
|
||||||
super(SlotEditForm, self).__init__(*args, **kwargs)
|
super(SlotEditForm, self).__init__(*args, **kwargs)
|
||||||
queryset = Presentation.objects.order_by("proposal_base__pk")
|
queryset = Presentation.objects.exclude(cancelled=True).order_by("proposal_base__pk")
|
||||||
if content:
|
if content:
|
||||||
queryset = queryset.filter(Q(slot=None) | Q(pk=content.pk))
|
queryset = queryset.filter(Q(slot=None) | Q(pk=content.pk))
|
||||||
self.fields["presentation"].required = False
|
self.fields["presentation"].required = False
|
||||||
|
|
Loading…
Reference in a new issue