feat(frontend): extend schedule dialog to support show/series selection

This commit is contained in:
2026-03-20 01:19:00 +01:00
parent 33338ac100
commit 5b89481104

View File

@@ -114,8 +114,12 @@ export function ScheduleFromLibraryDialog({ selectedItems, selectedShows }: Prop
const canConfirm = !!channelId && selectedDays.size > 0; const canConfirm = !!channelId && selectedDays.size > 0;
const daysLabel = [...selectedDays].map(d => WEEKDAY_LABELS[d]).join(", "); const daysLabel = [...selectedDays].map(d => WEEKDAY_LABELS[d]).join(", ");
const hasShows = selectedShows && selectedShows.length > 0;
const contentLabel = hasShows
? (selectedShows!.length === 1 ? selectedShows![0].series_name : `${selectedShows!.length} shows`)
: `${selectedItems.length} item(s)`;
const preview = canConfirm const preview = canConfirm
? `${selectedDays.size} block(s) will be created on ${selectedChannel?.name}${daysLabel} at ${startTime}, ${strategy}` ? `${selectedDays.size} block(s) of ${contentLabel} will be created on ${selectedChannel?.name}${daysLabel} at ${startTime}, ${strategy}`
: null; : null;
return ( return (