Browse Source

[fix]修改更新行业信息任然重复出现的问题

zk 1 year ago
parent
commit
139b446b9c
1 changed files with 4 additions and 2 deletions
  1. 4 2
      lib/data/repositories/account_repository.dart

+ 4 - 2
lib/data/repositories/account_repository.dart

@@ -63,7 +63,10 @@ class AccountRepository {
   Future<void> updateUserInfo(String profession, String post) {
     return atmobApi
         .updateUserInfo(UserInfoUpdateRequest(profession, post))
-        .then(HttpHandler.handle(true));
+        .then(HttpHandler.handle(true))
+        .then((data) {
+      accountRepository.refreshUserInfo();
+    });
   }
 
   Future<void>? refreshUserInfo() {
@@ -124,7 +127,6 @@ class AccountRepository {
     eventBus.emit(EventUserLogout);
   }
 
-
   getUserSubName(String? phone) {
     String name = StringName.account.tr;
     if (phone == null) {