mirror of
https://github.com/bggRGjQaUbCoE/PiliPlus.git
synced 2026-04-21 19:28:27 +08:00
fix: view fan/follow list from member info
This commit is contained in:
@@ -88,15 +88,7 @@ class MemberControllerNew extends CommonController
|
||||
TextButton(
|
||||
onPressed: () async {
|
||||
Get.back();
|
||||
var res = await VideoHttp.relationMod(
|
||||
mid: mid ?? -1,
|
||||
act: relation.value != -1 ? 5 : 6,
|
||||
reSrc: 11,
|
||||
);
|
||||
if (res['status']) {
|
||||
relation.value = relation.value != -1 ? -1 : 1;
|
||||
isFollow.value = false;
|
||||
}
|
||||
_onBlock();
|
||||
},
|
||||
child: const Text('确认'),
|
||||
)
|
||||
@@ -109,4 +101,26 @@ class MemberControllerNew extends CommonController
|
||||
void shareUser() {
|
||||
Share.share('https://space.bilibili.com/$mid');
|
||||
}
|
||||
|
||||
void _onBlock() async {
|
||||
dynamic res = await VideoHttp.relationMod(
|
||||
mid: mid ?? -1,
|
||||
act: relation.value != -1 ? 5 : 6,
|
||||
reSrc: 11,
|
||||
);
|
||||
if (res['status']) {
|
||||
relation.value = relation.value != -1 ? -1 : 1;
|
||||
isFollow.value = false;
|
||||
}
|
||||
}
|
||||
|
||||
void onFollow() async {
|
||||
if (relation.value == -1) {
|
||||
_onBlock();
|
||||
} else if (!isFollow.value) {
|
||||
// TODO
|
||||
} else {
|
||||
// TODO
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user