mirror of
https://github.com/Prowlarr/Prowlarr.git
synced 2025-09-27 04:21:27 +02:00
More Season ignore work. Already ignored seasons will be ignored.
Fix: Season Ignore is handled separately from Episode Ignore.
This commit is contained in:
@@ -17,6 +17,13 @@ namespace NzbDrone.Core.Datastore.Migrations
|
||||
new Column("SeasonNumber", DbType.Int32, ColumnProperty.NotNull),
|
||||
new Column("Ignored", DbType.Boolean, ColumnProperty.NotNull)
|
||||
});
|
||||
|
||||
Database.ExecuteNonQuery(@"INSERT INTO Seasons (SeriesId, SeasonNumber, Ignored)
|
||||
SELECT SeriesId, SeasonNumber,
|
||||
CASE WHEN Count(*) =
|
||||
SUM(CASE WHEN Ignored = 1 THEN 1 ELSE 0 END) THEN 1 ELSE 0 END AS Ignored
|
||||
FROM Episodes
|
||||
GROUP BY SeriesId, SeasonNumber");
|
||||
}
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user