mirror of
https://github.com/HChaZZY/PiliPlus.git
synced 2025-12-21 17:46:24 +08:00
opt handle res
Signed-off-by: bggRGjQaUbCoE <githubaccount56556@proton.me>
This commit is contained in:
22
lib/models/fav_article/data.dart
Normal file
22
lib/models/fav_article/data.dart
Normal file
@@ -0,0 +1,22 @@
|
||||
import 'package:PiliPlus/models/fav_article/item.dart';
|
||||
|
||||
class FavArticleData {
|
||||
List<FavArticleItemModel>? items;
|
||||
bool? hasMore;
|
||||
String? offset;
|
||||
|
||||
FavArticleData({
|
||||
this.items,
|
||||
this.hasMore,
|
||||
this.offset,
|
||||
});
|
||||
|
||||
factory FavArticleData.fromJson(Map<String, dynamic> json) => FavArticleData(
|
||||
items: (json['items'] as List<dynamic>?)
|
||||
?.map(
|
||||
(e) => FavArticleItemModel.fromJson(e as Map<String, dynamic>))
|
||||
.toList(),
|
||||
hasMore: json['has_more'] as bool?,
|
||||
offset: json['offset'] as String?,
|
||||
);
|
||||
}
|
||||
Reference in New Issue
Block a user