mirror of
https://github.com/pretix/pretix.git
synced 2026-05-08 15:44:02 +00:00
Fix not allowing program times on event series (API/copy) (#5595)
* Fix not allowing program times on event series (API/copy) * Return 400 when reading endpoint in event series * add docs program times not available on event series * fix isort
This commit is contained in:
committed by
GitHub
parent
e2d9cbb41d
commit
d7b6856322
@@ -241,6 +241,12 @@ class ItemProgramTimeSerializer(serializers.ModelSerializer):
|
||||
if start > end:
|
||||
raise ValidationError(_("The program end must not be before the program start."))
|
||||
|
||||
event = self.context['event']
|
||||
if event.has_subevents:
|
||||
raise ValidationError({
|
||||
_("You cannot use program times on an event series.")
|
||||
})
|
||||
|
||||
return data
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user