mirror of
https://github.com/HChaZZY/PiliPlus.git
synced 2025-12-06 09:13:48 +08:00
fix: 评论区无法切换最新
This commit is contained in:
@@ -129,7 +129,7 @@ class Api {
|
||||
|
||||
// 评论列表
|
||||
// https://api.bilibili.com/x/v2/reply/main?csrf=6e22efc1a47225ea25f901f922b5cfdd&mode=3&oid=254175381&pagination_str=%7B%22offset%22:%22%22%7D&plat=1&seek_rpid=0&type=11
|
||||
static const String replyList = '/x/v2/reply';
|
||||
static const String replyList = '/x/v2/reply/main';
|
||||
|
||||
// 楼中楼
|
||||
static const String replyReplyList = '/x/v2/reply/reply';
|
||||
|
||||
@@ -6,17 +6,15 @@ import 'init.dart';
|
||||
class ReplyHttp {
|
||||
static Future replyList({
|
||||
required int oid,
|
||||
required int pageNum,
|
||||
required String nextOffset,
|
||||
required int type,
|
||||
int? ps,
|
||||
int sort = 1,
|
||||
}) async {
|
||||
var res = await Request().get(Api.replyList, data: {
|
||||
'oid': oid,
|
||||
'pn': pageNum,
|
||||
'type': type,
|
||||
'sort': sort,
|
||||
'ps': ps ?? 20
|
||||
'pagination_str': '{"offset":"${nextOffset.replaceAll('"', '\\"')}"}',
|
||||
'mode': sort + 2, //2:按时间排序;3:按热度排序
|
||||
});
|
||||
if (res.data['code'] == 0) {
|
||||
return {
|
||||
@@ -50,7 +48,7 @@ class ReplyHttp {
|
||||
if (res.data['code'] == 0) {
|
||||
return {
|
||||
'status': true,
|
||||
'data': ReplyData.fromJson(res.data['data']),
|
||||
'data': ReplyReplyData.fromJson(res.data['data']),
|
||||
};
|
||||
} else {
|
||||
return {
|
||||
|
||||
Reference in New Issue
Block a user