Filter items from database according to tag and source
This commit is contained in:
parent
fe12819163
commit
1d1c121aab
@ -71,6 +71,10 @@ class Repository(private val api: SelfossApi, private val appSettingsService: Ap
|
|||||||
displayedItems == ItemType.ALL ||
|
displayedItems == ItemType.ALL ||
|
||||||
(it.unread && displayedItems == ItemType.UNREAD) ||
|
(it.unread && displayedItems == ItemType.UNREAD) ||
|
||||||
(it.starred && displayedItems == ItemType.STARRED)
|
(it.starred && displayedItems == ItemType.STARRED)
|
||||||
|
}.filter {
|
||||||
|
tagFilter == null || it.tags.contains(tagFilter!!.tag)
|
||||||
|
}.filter {
|
||||||
|
sourceFilter == null || it.sourcetitle == sourceFilter!!.title
|
||||||
}.map { it.toView() }
|
}.map { it.toView() }
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user