add group peer card

Signed-off-by: 21pages <pages21@163.com>
This commit is contained in:
21pages
2022-12-11 21:40:35 +08:00
parent 5ee3e3f347
commit 880a0d4209
42 changed files with 777 additions and 195 deletions

View File

@@ -21,10 +21,8 @@ class AbModel {
AbModel(this.parent);
FFI? get _ffi => parent.target;
Future<dynamic> pullAb() async {
if (_ffi!.userModel.userName.isEmpty) return;
if (gFFI.userModel.userName.isEmpty) return;
abLoading.value = true;
abError.value = "";
final api = "${await bind.mainGetApiServer()}/api/ab/get";
@@ -63,7 +61,8 @@ class AbModel {
return null;
}
void reset() {
Future<void> reset() async {
await bind.mainSetLocalOption(key: "selected-tags", value: '');
tags.clear();
peers.clear();
}
@@ -188,9 +187,4 @@ class AbModel {
await pushAb();
}
}
void clear() {
peers.clear();
tags.clear();
}
}