mirror of
https://github.com/bggRGjQaUbCoE/PiliPlus.git
synced 2026-06-01 00:28:18 +08:00
refa video params
Signed-off-by: bggRGjQaUbCoE <githubaccount56556@proton.me>
This commit is contained in:
@@ -11,7 +11,6 @@ import 'package:PiliPlus/pages/common/common_list_controller.dart';
|
||||
import 'package:PiliPlus/utils/extension.dart';
|
||||
import 'package:PiliPlus/utils/id_utils.dart';
|
||||
import 'package:PiliPlus/utils/page_utils.dart';
|
||||
import 'package:PiliPlus/utils/utils.dart';
|
||||
import 'package:flutter_smart_dialog/flutter_smart_dialog.dart';
|
||||
import 'package:get/get.dart';
|
||||
|
||||
@@ -154,22 +153,26 @@ class MemberVideoCtr
|
||||
if (oid != null) {
|
||||
var bvid = IdUtils.av2bv(int.parse(oid));
|
||||
var cid = await SearchHttp.ab2c(aid: oid, bvid: bvid);
|
||||
PageUtils.toVideoPage(
|
||||
'bvid=$bvid&cid=$cid',
|
||||
arguments: {
|
||||
'heroTag': Utils.makeHeroTag(oid),
|
||||
'sourceType': SourceType.archive,
|
||||
'mediaId': seasonId ?? seriesId ?? mid,
|
||||
'oid': oid,
|
||||
'favTitle': '$username: ${title ?? episodicButton.text ?? '播放全部'}',
|
||||
if (seriesId == null) 'count': count.value,
|
||||
if (seasonId != null || seriesId != null)
|
||||
'mediaType': params['page_type'],
|
||||
'desc': params['desc'] == '1',
|
||||
'sortField': params['sort_field'],
|
||||
'isContinuePlaying': true,
|
||||
},
|
||||
);
|
||||
if (cid != null) {
|
||||
PageUtils.toVideoPage(
|
||||
aid: int.parse(oid),
|
||||
bvid: bvid,
|
||||
cid: cid,
|
||||
extraArguments: {
|
||||
'sourceType': SourceType.archive,
|
||||
'mediaId': seasonId ?? seriesId ?? mid,
|
||||
'oid': oid,
|
||||
'favTitle':
|
||||
'$username: ${title ?? episodicButton.text ?? '播放全部'}',
|
||||
if (seriesId == null) 'count': count.value,
|
||||
if (seasonId != null || seriesId != null)
|
||||
'mediaType': params['page_type'],
|
||||
'desc': params['desc'] == '1',
|
||||
'sortField': params['sort_field'],
|
||||
'isContinuePlaying': true,
|
||||
},
|
||||
);
|
||||
}
|
||||
}
|
||||
return;
|
||||
}
|
||||
@@ -195,10 +198,11 @@ class MemberVideoCtr
|
||||
? !desc
|
||||
: desc;
|
||||
PageUtils.toVideoPage(
|
||||
'bvid=${element.bvid}&cid=${element.cid}',
|
||||
arguments: {
|
||||
'videoItem': element,
|
||||
'heroTag': Utils.makeHeroTag(element.bvid),
|
||||
bvid: element.bvid,
|
||||
cid: element.cid!,
|
||||
cover: element.cover,
|
||||
title: element.title,
|
||||
extraArguments: {
|
||||
'sourceType': SourceType.archive,
|
||||
'mediaId': seasonId ?? seriesId ?? mid,
|
||||
'oid': IdUtils.bv2av(element.bvid!),
|
||||
|
||||
@@ -11,7 +11,6 @@ import 'package:PiliPlus/models_new/space/space_archive/item.dart';
|
||||
import 'package:PiliPlus/utils/date_util.dart';
|
||||
import 'package:PiliPlus/utils/duration_util.dart';
|
||||
import 'package:PiliPlus/utils/page_utils.dart';
|
||||
import 'package:PiliPlus/utils/utils.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter_smart_dialog/flutter_smart_dialog.dart';
|
||||
|
||||
@@ -57,10 +56,10 @@ class VideoCardHMemberVideo extends StatelessWidget {
|
||||
}
|
||||
try {
|
||||
PageUtils.toVideoPage(
|
||||
'bvid=${videoItem.bvid}&cid=${videoItem.cid}',
|
||||
arguments: {
|
||||
'heroTag': Utils.makeHeroTag(videoItem.bvid),
|
||||
},
|
||||
bvid: videoItem.bvid,
|
||||
cid: videoItem.cid!,
|
||||
cover: videoItem.cover,
|
||||
title: videoItem.title,
|
||||
);
|
||||
} catch (err) {
|
||||
SmartDialog.showToast(err.toString());
|
||||
|
||||
Reference in New Issue
Block a user