Add category filters for Updates tab (#3589)
* Add category filters for Updates tab Works just like Library Updates. Provides a tab in the Updates tab filter dialog to allow for including & excluding of updates belonging to a title from a given category. Excludes overpower Includes, as with Library Updates. A little helpful text informs users about this. * Changelog * [skip ci] Remove unused string Leftover from before I realized the Default category will always be available for in-/exclusion. * Make :includeEmpty/:excludeEmpty true Boolean params * "include" -> "included" Consistency with #3607. * Remove DISTINCT from getRecentUpdatesWithFilters Apparently not needed anymore (though it was required at some point). * [skip ci] Fix Changelog
This commit is contained in:
@@ -35,6 +35,8 @@ class UpdatesRepositoryImpl(
|
||||
started: Boolean?,
|
||||
bookmarked: Boolean?,
|
||||
hideExcludedScanlators: Boolean,
|
||||
includedCategories: List<Long>,
|
||||
excludedCategories: List<Long>,
|
||||
): Flow<List<UpdatesWithRelations>> {
|
||||
return database.updatesViewQueries
|
||||
.getRecentUpdatesWithFilters(
|
||||
@@ -44,6 +46,10 @@ class UpdatesRepositoryImpl(
|
||||
started = started?.toLong(),
|
||||
bookmarked = bookmarked,
|
||||
hideExcludedScanlators = hideExcludedScanlators.toLong(),
|
||||
includedEmpty = includedCategories.isEmpty(),
|
||||
excludedEmpty = excludedCategories.isEmpty(),
|
||||
includedCategories = includedCategories,
|
||||
excludedCategories = excludedCategories,
|
||||
mapper = ::mapUpdatesWithRelations,
|
||||
)
|
||||
.subscribeToList()
|
||||
|
||||
Reference in New Issue
Block a user