mirror of
https://github.com/bggRGjQaUbCoE/PiliPlus.git
synced 2026-04-21 19:28:27 +08:00
@@ -6,8 +6,8 @@ class Category {
|
||||
Category({this.id, this.parentId, this.name});
|
||||
|
||||
factory Category.fromJson(Map<String, dynamic> json) => Category(
|
||||
id: json['id'] as int?,
|
||||
parentId: json['parent_id'] as int?,
|
||||
name: json['name'] as String?,
|
||||
);
|
||||
id: json['id'] as int?,
|
||||
parentId: json['parent_id'] as int?,
|
||||
name: json['name'] as String?,
|
||||
);
|
||||
}
|
||||
|
||||
@@ -149,7 +149,8 @@ class ArticleViewData {
|
||||
opus: json['opus'] == null
|
||||
? null
|
||||
: ArticleOpus.fromJson(json['opus'] as Map<String, dynamic>),
|
||||
ops:
|
||||
(json['ops'] as List?)?.map((e) => ArticleOps.fromJson(e)).toList(),
|
||||
ops: (json['ops'] as List?)
|
||||
?.map((e) => ArticleOps.fromJson(e))
|
||||
.toList(),
|
||||
);
|
||||
}
|
||||
|
||||
@@ -6,8 +6,8 @@ class Label {
|
||||
Label({this.path, this.text, this.labelTheme});
|
||||
|
||||
factory Label.fromJson(Map<String, dynamic> json) => Label(
|
||||
path: json['path'] as String?,
|
||||
text: json['text'] as String?,
|
||||
labelTheme: json['label_theme'] as String?,
|
||||
);
|
||||
path: json['path'] as String?,
|
||||
text: json['text'] as String?,
|
||||
labelTheme: json['label_theme'] as String?,
|
||||
);
|
||||
}
|
||||
|
||||
@@ -22,14 +22,14 @@ class Media {
|
||||
});
|
||||
|
||||
factory Media.fromJson(Map<String, dynamic> json) => Media(
|
||||
score: json['score'] as int?,
|
||||
mediaId: json['media_id'] as int?,
|
||||
title: json['title'] as String?,
|
||||
cover: json['cover'] as String?,
|
||||
area: json['area'] as String?,
|
||||
typeId: json['type_id'] as int?,
|
||||
typeName: json['type_name'] as String?,
|
||||
spoiler: json['spoiler'] as int?,
|
||||
seasonId: json['season_id'] as int?,
|
||||
);
|
||||
score: json['score'] as int?,
|
||||
mediaId: json['media_id'] as int?,
|
||||
title: json['title'] as String?,
|
||||
cover: json['cover'] as String?,
|
||||
area: json['area'] as String?,
|
||||
typeId: json['type_id'] as int?,
|
||||
typeName: json['type_name'] as String?,
|
||||
spoiler: json['spoiler'] as int?,
|
||||
seasonId: json['season_id'] as int?,
|
||||
);
|
||||
}
|
||||
|
||||
@@ -22,8 +22,8 @@ class Attributes {
|
||||
Attributes({this.clazz});
|
||||
|
||||
factory Attributes.fromJson(Map<String, dynamic> json) => Attributes(
|
||||
clazz: json['class'] as String?,
|
||||
);
|
||||
clazz: json['class'] as String?,
|
||||
);
|
||||
}
|
||||
|
||||
class Insert {
|
||||
|
||||
@@ -20,13 +20,13 @@ class Stats {
|
||||
});
|
||||
|
||||
factory Stats.fromJson(Map<String, dynamic> json) => Stats(
|
||||
view: json['view'] as int?,
|
||||
favorite: json['favorite'] as int?,
|
||||
like: json['like'] as int?,
|
||||
dislike: json['dislike'] as int?,
|
||||
reply: json['reply'] as int?,
|
||||
share: json['share'] as int?,
|
||||
coin: json['coin'] as num?,
|
||||
dynam1c: json['dynamic'] as int?,
|
||||
);
|
||||
view: json['view'] as int?,
|
||||
favorite: json['favorite'] as int?,
|
||||
like: json['like'] as int?,
|
||||
dislike: json['dislike'] as int?,
|
||||
reply: json['reply'] as int?,
|
||||
share: json['share'] as int?,
|
||||
coin: json['coin'] as num?,
|
||||
dynam1c: json['dynamic'] as int?,
|
||||
);
|
||||
}
|
||||
|
||||
@@ -5,7 +5,7 @@ class Tag {
|
||||
Tag({this.tid, this.name});
|
||||
|
||||
factory Tag.fromJson(Map<String, dynamic> json) => Tag(
|
||||
tid: json['tid'] as int?,
|
||||
name: json['name'] as String?,
|
||||
);
|
||||
tid: json['tid'] as int?,
|
||||
name: json['name'] as String?,
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user