Fix PRETIXEU-3V3

This commit is contained in:
Raphael Michel
2021-03-30 21:24:53 +02:00
parent 0efd4fedd5
commit 33ff7c39aa

View File

@@ -390,7 +390,12 @@ def add_subevents_for_days(qs, before, after, ebd, timezones, event=None, cart_n
s = event.settings if event else se.event.settings
if s.event_list_available_only:
if se.presale_has_ended or ((not voucher or not voucher.allow_ignore_quota) and se.best_availability_state < Quota.AVAILABILITY_RESERVED):
hide = se.presale_has_ended or (
(not voucher or not voucher.allow_ignore_quota) and
se.best_availability_state is not None and
se.best_availability_state < Quota.AVAILABILITY_RESERVED
)
if hide:
continue
timezones.add(s.timezones)