mirror of
https://github.com/simon-ding/polaris.git
synced 2026-04-22 11:47:30 +08:00
chore: improve ui
This commit is contained in:
@@ -65,6 +65,7 @@ class SeriesDetails {
|
|||||||
String? mediaType;
|
String? mediaType;
|
||||||
Storage? storage;
|
Storage? storage;
|
||||||
String? targetDir;
|
String? targetDir;
|
||||||
|
bool? downloadHistoryEpisodes;
|
||||||
|
|
||||||
SeriesDetails(
|
SeriesDetails(
|
||||||
{this.id,
|
{this.id,
|
||||||
@@ -80,7 +81,8 @@ class SeriesDetails {
|
|||||||
this.episodes,
|
this.episodes,
|
||||||
this.mediaType,
|
this.mediaType,
|
||||||
this.targetDir,
|
this.targetDir,
|
||||||
this.storage});
|
this.storage,
|
||||||
|
this.downloadHistoryEpisodes});
|
||||||
|
|
||||||
SeriesDetails.fromJson(Map<String, dynamic> json) {
|
SeriesDetails.fromJson(Map<String, dynamic> json) {
|
||||||
id = json['id'];
|
id = json['id'];
|
||||||
@@ -96,6 +98,7 @@ class SeriesDetails {
|
|||||||
mediaType = json["media_type"];
|
mediaType = json["media_type"];
|
||||||
storage = Storage.fromJson(json["storage"]);
|
storage = Storage.fromJson(json["storage"]);
|
||||||
targetDir = json["target_dir"];
|
targetDir = json["target_dir"];
|
||||||
|
downloadHistoryEpisodes = json["download_history_episodes"]??false;
|
||||||
if (json['episodes'] != null) {
|
if (json['episodes'] != null) {
|
||||||
episodes = <Episodes>[];
|
episodes = <Episodes>[];
|
||||||
json['episodes'].forEach((v) {
|
json['episodes'].forEach((v) {
|
||||||
|
|||||||
@@ -70,7 +70,16 @@ class _DetailCardState extends ConsumerState<DetailCard> {
|
|||||||
),
|
),
|
||||||
Text(
|
Text(
|
||||||
"${widget.details.mediaType == "tv" ? widget.details.storage!.tvPath : widget.details.storage!.moviePath}"
|
"${widget.details.mediaType == "tv" ? widget.details.storage!.tvPath : widget.details.storage!.moviePath}"
|
||||||
"${widget.details.targetDir}")
|
"${widget.details.targetDir}"),
|
||||||
|
const SizedBox(
|
||||||
|
width: 30,
|
||||||
|
),
|
||||||
|
widget.details.mediaType == 'tv'
|
||||||
|
? (widget.details.downloadHistoryEpisodes ==
|
||||||
|
true
|
||||||
|
? const Text("下载往期剧集")
|
||||||
|
: const Text("只下载更新剧集"))
|
||||||
|
: const Text("")
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
const Divider(thickness: 1, height: 1),
|
const Divider(thickness: 1, height: 1),
|
||||||
@@ -82,6 +91,8 @@ class _DetailCardState extends ConsumerState<DetailCard> {
|
|||||||
const Text(""),
|
const Text(""),
|
||||||
Expanded(
|
Expanded(
|
||||||
child: Text(
|
child: Text(
|
||||||
|
overflow: TextOverflow.ellipsis,
|
||||||
|
maxLines: 9,
|
||||||
widget.details.overview ?? "",
|
widget.details.overview ?? "",
|
||||||
)),
|
)),
|
||||||
Row(
|
Row(
|
||||||
|
|||||||
Reference in New Issue
Block a user