feat: 移除单个稍后再看

This commit is contained in:
guozhigq
2023-08-30 09:36:19 +08:00
parent fceb55aaa3
commit 108c37f0d7
3 changed files with 36 additions and 19 deletions

View File

@ -179,14 +179,16 @@ class UserHttp {
}
// 移除已观看
static Future toViewDel() async {
static Future toViewDel({int? aid}) async {
final Map<String, dynamic> params = {
'jsonp': 'jsonp',
'csrf': await Request.getCsrf(),
};
params[aid != null ? 'aid' : 'viewed'] = aid ?? true;
var res = await Request().post(
Api.toViewDel,
queryParameters: {
'jsonp': 'jsonp',
'viewed': true,
'csrf': await Request.getCsrf(),
},
queryParameters: params,
);
if (res.data['code'] == 0) {
return {'status': true, 'msg': 'yeah成功移除'};