mirror of
https://github.com/bggRGjQaUbCoE/PiliPlus.git
synced 2026-04-27 22:05:53 +08:00
@@ -20,14 +20,14 @@ class Bangumi {
|
||||
});
|
||||
|
||||
factory Bangumi.fromJson(Map<String, dynamic> json) => Bangumi(
|
||||
epId: json['ep_id'] as int?,
|
||||
title: json['title'] as String?,
|
||||
longTitle: json['long_title'] as String?,
|
||||
episodeStatus: json['episode_status'] as int?,
|
||||
follow: json['follow'] as int?,
|
||||
cover: json['cover'] as String?,
|
||||
season: json['season'] == null
|
||||
? null
|
||||
: Season.fromJson(json['season'] as Map<String, dynamic>),
|
||||
);
|
||||
epId: json['ep_id'] as int?,
|
||||
title: json['title'] as String?,
|
||||
longTitle: json['long_title'] as String?,
|
||||
episodeStatus: json['episode_status'] as int?,
|
||||
follow: json['follow'] as int?,
|
||||
cover: json['cover'] as String?,
|
||||
season: json['season'] == null
|
||||
? null
|
||||
: Season.fromJson(json['season'] as Map<String, dynamic>),
|
||||
);
|
||||
}
|
||||
|
||||
@@ -7,9 +7,9 @@ class LaterData {
|
||||
LaterData({this.count, this.list});
|
||||
|
||||
factory LaterData.fromJson(Map<String, dynamic> json) => LaterData(
|
||||
count: json['count'] as int?,
|
||||
list: (json['list'] as List<dynamic>?)
|
||||
?.map((e) => LaterItemModel.fromJson(e as Map<String, dynamic>))
|
||||
.toList(),
|
||||
);
|
||||
count: json['count'] as int?,
|
||||
list: (json['list'] as List<dynamic>?)
|
||||
?.map((e) => LaterItemModel.fromJson(e as Map<String, dynamic>))
|
||||
.toList(),
|
||||
);
|
||||
}
|
||||
|
||||
@@ -6,8 +6,8 @@ class Dimension {
|
||||
Dimension({this.width, this.height, this.rotate});
|
||||
|
||||
factory Dimension.fromJson(Map<String, dynamic> json) => Dimension(
|
||||
width: json['width'] as int?,
|
||||
height: json['height'] as int?,
|
||||
rotate: json['rotate'] as int?,
|
||||
);
|
||||
width: json['width'] as int?,
|
||||
height: json['height'] as int?,
|
||||
rotate: json['rotate'] as int?,
|
||||
);
|
||||
}
|
||||
|
||||
@@ -103,65 +103,67 @@ class LaterItemModel with MultiSelectData {
|
||||
});
|
||||
|
||||
factory LaterItemModel.fromJson(Map<String, dynamic> json) => LaterItemModel(
|
||||
aid: json['aid'] as int?,
|
||||
videos: json['videos'] as int?,
|
||||
tid: json['tid'] as int?,
|
||||
tname: json['tname'] as String?,
|
||||
copyright: json['copyright'] as int?,
|
||||
pic: json['pic'] as String?,
|
||||
title: json['title'] as String?,
|
||||
pubdate: json['pubdate'] as int?,
|
||||
ctime: json['ctime'] as int?,
|
||||
desc: json['desc'] as String?,
|
||||
state: json['state'] as int?,
|
||||
duration: json['duration'] as int?,
|
||||
redirectUrl: json['redirect_url'] as String?,
|
||||
rights: json['rights'] == null
|
||||
? null
|
||||
: Rights.fromJson(json['rights'] as Map<String, dynamic>),
|
||||
owner: json['owner'] == null
|
||||
? null
|
||||
: Owner.fromJson(json['owner'] as Map<String, dynamic>),
|
||||
stat: json['stat'] == null
|
||||
? null
|
||||
: Stat.fromJson(json['stat'] as Map<String, dynamic>),
|
||||
dynam1c: json['dynamic'] as String?,
|
||||
dimension: json['dimension'] == null
|
||||
? null
|
||||
: Dimension.fromJson(json['dimension'] as Map<String, dynamic>),
|
||||
shortLinkV2: json['short_link_v2'] as String?,
|
||||
upFromV2: json['up_from_v2'] as int?,
|
||||
pubLocation: json['pub_location'] as String?,
|
||||
cover43: json['cover43'] as String?,
|
||||
tidv2: json['tidv2'] as int?,
|
||||
tnamev2: json['tnamev2'] as String?,
|
||||
pidV2: json['pid_v2'] as int?,
|
||||
pidNameV2: json['pid_name_v2'] as String?,
|
||||
pages: (json['pages'] as List<dynamic>?)
|
||||
?.map((e) => Page.fromJson(e as Map<String, dynamic>))
|
||||
.toList(),
|
||||
bangumi: json['bangumi'] == null
|
||||
? null
|
||||
: Bangumi.fromJson(json['bangumi'] as Map<String, dynamic>),
|
||||
subtitle: json['bangumi'] == null
|
||||
? null
|
||||
: (json['title'] as String)
|
||||
.replaceFirst('${json['bangumi']['season']['title']} ', ''),
|
||||
cid: json['cid'] as int?,
|
||||
progress: json['progress'] as int?,
|
||||
addAt: json['add_at'] as int?,
|
||||
bvid: json['bvid'] as String?,
|
||||
uri: json['uri'] as String?,
|
||||
viewed: json['viewed'] as bool?,
|
||||
seq: json['seq'] as int?,
|
||||
enableVt: json['enable_vt'] as int?,
|
||||
viewText1: json['view_text_1'] as String?,
|
||||
isPgc: json['is_pgc'] as bool?,
|
||||
pgcLabel: json['pgc_label'] == '' ? null : json['pgc_label'],
|
||||
isPugv: json['is_pugv'] as bool?,
|
||||
missionId: json['mission_id'] as int?,
|
||||
firstFrame: json['first_frame'] as String?,
|
||||
seasonId: json['season_id'] as int?,
|
||||
isCharging: json['charging_pay']?['level'] != null,
|
||||
);
|
||||
aid: json['aid'] as int?,
|
||||
videos: json['videos'] as int?,
|
||||
tid: json['tid'] as int?,
|
||||
tname: json['tname'] as String?,
|
||||
copyright: json['copyright'] as int?,
|
||||
pic: json['pic'] as String?,
|
||||
title: json['title'] as String?,
|
||||
pubdate: json['pubdate'] as int?,
|
||||
ctime: json['ctime'] as int?,
|
||||
desc: json['desc'] as String?,
|
||||
state: json['state'] as int?,
|
||||
duration: json['duration'] as int?,
|
||||
redirectUrl: json['redirect_url'] as String?,
|
||||
rights: json['rights'] == null
|
||||
? null
|
||||
: Rights.fromJson(json['rights'] as Map<String, dynamic>),
|
||||
owner: json['owner'] == null
|
||||
? null
|
||||
: Owner.fromJson(json['owner'] as Map<String, dynamic>),
|
||||
stat: json['stat'] == null
|
||||
? null
|
||||
: Stat.fromJson(json['stat'] as Map<String, dynamic>),
|
||||
dynam1c: json['dynamic'] as String?,
|
||||
dimension: json['dimension'] == null
|
||||
? null
|
||||
: Dimension.fromJson(json['dimension'] as Map<String, dynamic>),
|
||||
shortLinkV2: json['short_link_v2'] as String?,
|
||||
upFromV2: json['up_from_v2'] as int?,
|
||||
pubLocation: json['pub_location'] as String?,
|
||||
cover43: json['cover43'] as String?,
|
||||
tidv2: json['tidv2'] as int?,
|
||||
tnamev2: json['tnamev2'] as String?,
|
||||
pidV2: json['pid_v2'] as int?,
|
||||
pidNameV2: json['pid_name_v2'] as String?,
|
||||
pages: (json['pages'] as List<dynamic>?)
|
||||
?.map((e) => Page.fromJson(e as Map<String, dynamic>))
|
||||
.toList(),
|
||||
bangumi: json['bangumi'] == null
|
||||
? null
|
||||
: Bangumi.fromJson(json['bangumi'] as Map<String, dynamic>),
|
||||
subtitle: json['bangumi'] == null
|
||||
? null
|
||||
: (json['title'] as String).replaceFirst(
|
||||
'${json['bangumi']['season']['title']} ',
|
||||
'',
|
||||
),
|
||||
cid: json['cid'] as int?,
|
||||
progress: json['progress'] as int?,
|
||||
addAt: json['add_at'] as int?,
|
||||
bvid: json['bvid'] as String?,
|
||||
uri: json['uri'] as String?,
|
||||
viewed: json['viewed'] as bool?,
|
||||
seq: json['seq'] as int?,
|
||||
enableVt: json['enable_vt'] as int?,
|
||||
viewText1: json['view_text_1'] as String?,
|
||||
isPgc: json['is_pgc'] as bool?,
|
||||
pgcLabel: json['pgc_label'] == '' ? null : json['pgc_label'],
|
||||
isPugv: json['is_pugv'] as bool?,
|
||||
missionId: json['mission_id'] as int?,
|
||||
firstFrame: json['first_frame'] as String?,
|
||||
seasonId: json['season_id'] as int?,
|
||||
isCharging: json['charging_pay']?['level'] != null,
|
||||
);
|
||||
}
|
||||
|
||||
@@ -6,8 +6,8 @@ class Owner {
|
||||
Owner({this.mid, this.name, this.face});
|
||||
|
||||
factory Owner.fromJson(Map<String, dynamic> json) => Owner(
|
||||
mid: json['mid'] as int?,
|
||||
name: json['name'] as String?,
|
||||
face: json['face'] as String?,
|
||||
);
|
||||
mid: json['mid'] as int?,
|
||||
name: json['name'] as String?,
|
||||
face: json['face'] as String?,
|
||||
);
|
||||
}
|
||||
|
||||
@@ -24,16 +24,16 @@ class Page {
|
||||
});
|
||||
|
||||
factory Page.fromJson(Map<String, dynamic> json) => Page(
|
||||
cid: json['cid'] as int?,
|
||||
page: json['page'] as int?,
|
||||
from: json['from'] as String?,
|
||||
part: json['part'] as String?,
|
||||
duration: json['duration'] as int?,
|
||||
vid: json['vid'] as String?,
|
||||
weblink: json['weblink'] as String?,
|
||||
dimension: json['dimension'] == null
|
||||
? null
|
||||
: Dimension.fromJson(json['dimension'] as Map<String, dynamic>),
|
||||
ctime: json['ctime'] as int?,
|
||||
);
|
||||
cid: json['cid'] as int?,
|
||||
page: json['page'] as int?,
|
||||
from: json['from'] as String?,
|
||||
part: json['part'] as String?,
|
||||
duration: json['duration'] as int?,
|
||||
vid: json['vid'] as String?,
|
||||
weblink: json['weblink'] as String?,
|
||||
dimension: json['dimension'] == null
|
||||
? null
|
||||
: Dimension.fromJson(json['dimension'] as Map<String, dynamic>),
|
||||
ctime: json['ctime'] as int?,
|
||||
);
|
||||
}
|
||||
|
||||
@@ -32,19 +32,19 @@ class Rights {
|
||||
});
|
||||
|
||||
factory Rights.fromJson(Map<String, dynamic> json) => Rights(
|
||||
bp: json['bp'] as int?,
|
||||
elec: json['elec'] as int?,
|
||||
download: json['download'] as int?,
|
||||
movie: json['movie'] as int?,
|
||||
pay: json['pay'] as int?,
|
||||
hd5: json['hd5'] as int?,
|
||||
noReprint: json['no_reprint'] as int?,
|
||||
autoplay: json['autoplay'] as int?,
|
||||
ugcPay: json['ugc_pay'] as int?,
|
||||
isCooperation: json['is_cooperation'] as int?,
|
||||
ugcPayPreview: json['ugc_pay_preview'] as int?,
|
||||
noBackground: json['no_background'] as int?,
|
||||
arcPay: json['arc_pay'] as int?,
|
||||
payFreeWatch: json['pay_free_watch'] as int?,
|
||||
);
|
||||
bp: json['bp'] as int?,
|
||||
elec: json['elec'] as int?,
|
||||
download: json['download'] as int?,
|
||||
movie: json['movie'] as int?,
|
||||
pay: json['pay'] as int?,
|
||||
hd5: json['hd5'] as int?,
|
||||
noReprint: json['no_reprint'] as int?,
|
||||
autoplay: json['autoplay'] as int?,
|
||||
ugcPay: json['ugc_pay'] as int?,
|
||||
isCooperation: json['is_cooperation'] as int?,
|
||||
ugcPayPreview: json['ugc_pay_preview'] as int?,
|
||||
noBackground: json['no_background'] as int?,
|
||||
arcPay: json['arc_pay'] as int?,
|
||||
payFreeWatch: json['pay_free_watch'] as int?,
|
||||
);
|
||||
}
|
||||
|
||||
@@ -20,13 +20,13 @@ class Season {
|
||||
});
|
||||
|
||||
factory Season.fromJson(Map<String, dynamic> json) => Season(
|
||||
seasonId: json['season_id'] as int?,
|
||||
title: json['title'] as String?,
|
||||
seasonStatus: json['season_status'] as int?,
|
||||
isFinish: json['is_finish'] as int?,
|
||||
totalCount: json['total_count'] as int?,
|
||||
newestEpId: json['newest_ep_id'] as int?,
|
||||
newestEpIndex: json['newest_ep_index'] as String?,
|
||||
seasonType: json['season_type'] as int?,
|
||||
);
|
||||
seasonId: json['season_id'] as int?,
|
||||
title: json['title'] as String?,
|
||||
seasonStatus: json['season_status'] as int?,
|
||||
isFinish: json['is_finish'] as int?,
|
||||
totalCount: json['total_count'] as int?,
|
||||
newestEpId: json['newest_ep_id'] as int?,
|
||||
newestEpIndex: json['newest_ep_index'] as String?,
|
||||
seasonType: json['season_type'] as int?,
|
||||
);
|
||||
}
|
||||
|
||||
@@ -30,18 +30,18 @@ class Stat {
|
||||
});
|
||||
|
||||
factory Stat.fromJson(Map<String, dynamic> json) => Stat(
|
||||
aid: json['aid'] as int?,
|
||||
view: json['view'] as int?,
|
||||
danmaku: json['danmaku'] as int?,
|
||||
reply: json['reply'] as int?,
|
||||
favorite: json['favorite'] as int?,
|
||||
coin: json['coin'] as num?,
|
||||
share: json['share'] as int?,
|
||||
nowRank: json['now_rank'] as int?,
|
||||
hisRank: json['his_rank'] as int?,
|
||||
like: json['like'] as int?,
|
||||
dislike: json['dislike'] as int?,
|
||||
vt: json['vt'] as int?,
|
||||
vv: json['vv'] as int?,
|
||||
);
|
||||
aid: json['aid'] as int?,
|
||||
view: json['view'] as int?,
|
||||
danmaku: json['danmaku'] as int?,
|
||||
reply: json['reply'] as int?,
|
||||
favorite: json['favorite'] as int?,
|
||||
coin: json['coin'] as num?,
|
||||
share: json['share'] as int?,
|
||||
nowRank: json['now_rank'] as int?,
|
||||
hisRank: json['his_rank'] as int?,
|
||||
like: json['like'] as int?,
|
||||
dislike: json['dislike'] as int?,
|
||||
vt: json['vt'] as int?,
|
||||
vv: json['vv'] as int?,
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user