From e9f0c962494ef0aba9fc8f5aa4444b99eeba6601 Mon Sep 17 00:00:00 2001 From: Mark McDowall Date: Fri, 26 Jan 2024 21:01:36 -0800 Subject: [PATCH] Fixed: Specials not allowing multi-episode select in Manual Import Closes #6429 --- .../Interactive/InteractiveImportModalContent.tsx | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/frontend/src/InteractiveImport/Interactive/InteractiveImportModalContent.tsx b/frontend/src/InteractiveImport/Interactive/InteractiveImportModalContent.tsx index 071ec650c..b778388a5 100644 --- a/frontend/src/InteractiveImport/Interactive/InteractiveImportModalContent.tsx +++ b/frontend/src/InteractiveImport/Interactive/InteractiveImportModalContent.tsx @@ -298,14 +298,20 @@ function InteractiveImportModalContent( return acc; } + const lastSelectedSeason = acc.lastSelectedSeason; + acc.seasonSelectDisabled ||= !item.series; - acc.episodeSelectDisabled ||= !item.seasonNumber; + acc.episodeSelectDisabled ||= + item.seasonNumber === undefined || + (lastSelectedSeason >= 0 && item.seasonNumber !== lastSelectedSeason); + acc.lastSelectedSeason = item.seasonNumber ?? -1; return acc; }, { seasonSelectDisabled: false, episodeSelectDisabled: false, + lastSelectedSeason: -1, } );