mirror of
https://github.com/pretix/pretix.git
synced 2026-05-17 17:14:04 +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
@@ -990,10 +990,11 @@ class Event(EventMixin, LoggedModel):
|
||||
ia.bundled_variation = variation_map[ia.bundled_variation.pk]
|
||||
ia.save(force_insert=True)
|
||||
|
||||
for ipt in ItemProgramTime.objects.filter(item__event=other).prefetch_related('item'):
|
||||
ipt.pk = None
|
||||
ipt.item = item_map[ipt.item.pk]
|
||||
ipt.save(force_insert=True)
|
||||
if not self.has_subevents and not other.has_subevents:
|
||||
for ipt in ItemProgramTime.objects.filter(item__event=other).prefetch_related('item'):
|
||||
ipt.pk = None
|
||||
ipt.item = item_map[ipt.item.pk]
|
||||
ipt.save(force_insert=True)
|
||||
|
||||
quota_map = {}
|
||||
for q in Quota.objects.filter(event=other, subevent__isnull=True).prefetch_related('items', 'variations'):
|
||||
|
||||
Reference in New Issue
Block a user