|
|
@ -158,7 +158,7 @@ class CacheActivity : VMBaseActivity<ActivityCacheBookBinding, CacheViewModel>() |
|
|
|
else -> appDb.bookDao.flowByGroup(groupId) |
|
|
|
else -> appDb.bookDao.flowByGroup(groupId) |
|
|
|
}.collect { list -> |
|
|
|
}.collect { list -> |
|
|
|
val booksDownload = list.filter { |
|
|
|
val booksDownload = list.filter { |
|
|
|
it.isOnLineTxt() |
|
|
|
it.type == 0 |
|
|
|
} |
|
|
|
} |
|
|
|
val books = when (getPrefInt(PreferKey.bookshelfSort)) { |
|
|
|
val books = when (getPrefInt(PreferKey.bookshelfSort)) { |
|
|
|
1 -> booksDownload.sortedByDescending { it.latestChapterTime } |
|
|
|
1 -> booksDownload.sortedByDescending { it.latestChapterTime } |
|
|
|