Fix a bug when opening a chapter from the recents tab and changing the viewer from the reader would not update chapters for that manga anymore
This commit is contained in:
parent
908e60dea4
commit
5029e4a28c
@ -36,7 +36,7 @@ val libraryQuery =
|
|||||||
* @param date the delimiting date.
|
* @param date the delimiting date.
|
||||||
*/
|
*/
|
||||||
fun getRecentsQuery(date: Date): String =
|
fun getRecentsQuery(date: Date): String =
|
||||||
"SELECT * FROM ${Manga.TABLE} JOIN ${Chapter.TABLE} " +
|
"SELECT ${Manga.TABLE}.${Manga.COLUMN_URL} as mangaUrl, * FROM ${Manga.TABLE} JOIN ${Chapter.TABLE} " +
|
||||||
"ON ${Manga.TABLE}.${Manga.COLUMN_ID} = ${Chapter.TABLE}.${Chapter.COLUMN_MANGA_ID} " +
|
"ON ${Manga.TABLE}.${Manga.COLUMN_ID} = ${Chapter.TABLE}.${Chapter.COLUMN_MANGA_ID} " +
|
||||||
"WHERE ${Manga.COLUMN_FAVORITE} = 1 AND ${Chapter.COLUMN_DATE_UPLOAD} > ${date.time} " +
|
"WHERE ${Manga.COLUMN_FAVORITE} = 1 AND ${Chapter.COLUMN_DATE_UPLOAD} > ${date.time} " +
|
||||||
"ORDER BY ${Chapter.COLUMN_DATE_UPLOAD} DESC"
|
"ORDER BY ${Chapter.COLUMN_DATE_UPLOAD} DESC"
|
||||||
|
@ -20,6 +20,7 @@ class MangaChapterGetResolver : DefaultGetResolver<MangaChapter>() {
|
|||||||
val manga = mangaGetResolver.mapFromCursor(cursor)
|
val manga = mangaGetResolver.mapFromCursor(cursor)
|
||||||
val chapter = chapterGetResolver.mapFromCursor(cursor)
|
val chapter = chapterGetResolver.mapFromCursor(cursor)
|
||||||
manga.id = chapter.manga_id
|
manga.id = chapter.manga_id
|
||||||
|
manga.url = cursor.getString(cursor.getColumnIndex("mangaUrl"));
|
||||||
|
|
||||||
return MangaChapter(manga, chapter)
|
return MangaChapter(manga, chapter)
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user