Adds the new shows admin screen and drives schedule from it
This commit is contained in:
@@ -89,6 +89,7 @@ async def update_show(
|
||||
# Replace all schedule slots
|
||||
for sched in show.schedules:
|
||||
await session.delete(sched)
|
||||
await session.flush() # execute deletes before inserts to avoid UNIQUE conflict
|
||||
for slot in payload.schedules:
|
||||
session.add(ShowSchedule(show_id=show.id, **slot.model_dump()))
|
||||
|
||||
|
||||
Reference in New Issue
Block a user