Skip to content

Commit 762c705

Browse files
committed
[release] Patch for version 2025.10.12
1 parent d47d31d commit 762c705

7 files changed

Lines changed: 385 additions & 1330 deletions

File tree

lib/models/hako_models.dart

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@ class NovelBasic {
33
final String title;
44
final String cover;
55
final String url;
6-
final String? latestChapter; // Dành cho list mới nhất
7-
final String? summary; // Dành cho list vừa đăng
6+
final String? latestChapter;
7+
final String? summary;
88

99
NovelBasic({
1010
required this.id,
@@ -33,6 +33,7 @@ class NovelDetail {
3333
final String cover;
3434
final String author;
3535
final String illustrator;
36+
final String status;
3637
final List<String> genres;
3738
final String summary;
3839
final List<Volume> volumes;
@@ -43,6 +44,7 @@ class NovelDetail {
4344
required this.cover,
4445
required this.author,
4546
required this.illustrator,
47+
required this.status,
4648
required this.genres,
4749
required this.summary,
4850
required this.volumes,
@@ -53,8 +55,9 @@ class NovelDetail {
5355
id: json['id']?.toString() ?? '',
5456
title: json['title'] ?? '',
5557
cover: json['cover'] ?? '',
56-
author: json['author'] ?? '',
58+
author: json['author'] ?? 'Unknown',
5759
illustrator: json['illustrator'] ?? '',
60+
status: json['status'] ?? '',
5861
genres: List<String>.from(json['genres'] ?? []),
5962
summary: json['summary'] ?? '',
6063
volumes:

lib/modules/chapter.dart

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,22 @@
11
class Chapter {
2+
final String id; // Thêm cái này
23
final String title;
34
final String url;
45
final String coverUrl;
56
final String seriesTitle;
67
final String seriesUrl;
78
final String? volumeTitle;
9+
final String time; // Thêm cái này
810

911
Chapter({
12+
this.id = '', // Mặc định rỗng để không lỗi code cũ
1013
required this.title,
1114
required this.url,
1215
required this.coverUrl,
1316
required this.seriesTitle,
1417
required this.seriesUrl,
1518
this.volumeTitle,
19+
this.time = '', // Mặc định rỗng
1620
});
1721

1822
factory Chapter.fromHtml(String html) {
@@ -30,12 +34,14 @@ class Chapter {
3034
final volumeTitleMatch = volumeTitleRegex.firstMatch(html);
3135

3236
return Chapter(
37+
id: '', // Mặc định
3338
title: titleMatch?.group(1) ?? '',
3439
url: urlMatch?.group(1) ?? '',
3540
coverUrl: coverMatch?.group(1) ?? 'https://docln.sbs/img/nocover.jpg',
3641
seriesTitle: seriesTitleMatch?.group(1) ?? '',
3742
seriesUrl: '', // Extract from series link
3843
volumeTitle: volumeTitleMatch?.group(1),
44+
time: '', // Mặc định
3945
);
4046
}
4147
}

0 commit comments

Comments
 (0)