parent
7cebc9ac8b
commit
e66a5651bc
|
@ -6,7 +6,7 @@ ext {
|
||||||
extName = 'Yomu Mangás'
|
extName = 'Yomu Mangás'
|
||||||
pkgNameSuffix = 'pt.yomumangas'
|
pkgNameSuffix = 'pt.yomumangas'
|
||||||
extClass = '.YomuMangas'
|
extClass = '.YomuMangas'
|
||||||
extVersionCode = 1
|
extVersionCode = 2
|
||||||
isNsfw = true
|
isNsfw = true
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -70,13 +70,13 @@ data class YomuMangasChaptersDto(val chapters: List<YomuMangasChapterDto> = empt
|
||||||
@Serializable
|
@Serializable
|
||||||
data class YomuMangasChapterDto(
|
data class YomuMangasChapterDto(
|
||||||
val id: Int,
|
val id: Int,
|
||||||
val chapter: Int,
|
val chapter: Float,
|
||||||
@SerialName("uploaded_at") val uploadedAt: String,
|
@SerialName("uploaded_at") val uploadedAt: String,
|
||||||
val images: List<YomuMangasImageDto>? = emptyList(),
|
val images: List<YomuMangasImageDto>? = emptyList(),
|
||||||
) {
|
) {
|
||||||
|
|
||||||
fun toSChapter(series: YomuMangasSeriesDto): SChapter = SChapter.create().apply {
|
fun toSChapter(series: YomuMangasSeriesDto): SChapter = SChapter.create().apply {
|
||||||
name = "Capítulo $chapter"
|
name = "Capítulo ${chapter.toString().removeSuffix(".0")}"
|
||||||
date_upload = runCatching { DATE_FORMATTER.parse(uploadedAt)?.time }
|
date_upload = runCatching { DATE_FORMATTER.parse(uploadedAt)?.time }
|
||||||
.getOrNull() ?: 0L
|
.getOrNull() ?: 0L
|
||||||
url = "/manga/${series.id}/${series.slug}/chapter/$id#$chapter"
|
url = "/manga/${series.id}/${series.slug}/chapter/$id#$chapter"
|
||||||
|
|
Loading…
Reference in New Issue