mirror of
https://github.com/HChaZZY/PiliPlus.git
synced 2025-12-17 23:56:13 +08:00
show forwarded dyn pic
Signed-off-by: bggRGjQaUbCoE <githubaccount56556@proton.me>
This commit is contained in:
@@ -892,4 +892,6 @@ class Api {
|
||||
static const String dynTopicRcmd = '/x/topic/web/dynamic/rcmd';
|
||||
|
||||
static const String matchInfo = '/x/esports/match/info';
|
||||
|
||||
static const String dynPic = '/x/polymer/web-dynamic/v1/detail/pic';
|
||||
}
|
||||
|
||||
@@ -493,4 +493,21 @@ class DynamicsHttp {
|
||||
return Error(res.data['message']);
|
||||
}
|
||||
}
|
||||
|
||||
static Future<LoadingState<List<OpusPicModel>?>> dynPic(dynamic id) async {
|
||||
final res = await Request().get(
|
||||
Api.dynPic,
|
||||
queryParameters: {
|
||||
'id': id,
|
||||
'web_location': 333.1368,
|
||||
},
|
||||
);
|
||||
if (res.data['code'] == 0) {
|
||||
return Success((res.data['data'] as List?)
|
||||
?.map((e) => OpusPicModel.fromJson(e))
|
||||
.toList());
|
||||
} else {
|
||||
return Error(res.data['message']);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user