|
@@ -295,7 +295,7 @@ class KMSignUpViewModel: ObservableObject {
|
|
|
|
|
|
self.timer?.cancel()
|
|
self.timer?.cancel()
|
|
self.sendContent = NSLocalizedString("Resend", tableName: "MemberCenterLocalizable", comment: "")
|
|
self.sendContent = NSLocalizedString("Resend", tableName: "MemberCenterLocalizable", comment: "")
|
|
-
|
|
|
|
|
|
+
|
|
KMMemberInfo.shared.avatarImage = nil
|
|
KMMemberInfo.shared.avatarImage = nil
|
|
} else {
|
|
} else {
|
|
if(resultDict.code == 305) {
|
|
if(resultDict.code == 305) {
|
|
@@ -326,19 +326,12 @@ class KMSignUpViewModel: ObservableObject {
|
|
}
|
|
}
|
|
} else {
|
|
} else {
|
|
callback?(false)
|
|
callback?(false)
|
|
-
|
|
|
|
print("错误信息:%@", msg as Any)
|
|
print("错误信息:%@", msg as Any)
|
|
- DispatchQueue.main.async {
|
|
|
|
- let alert = NSAlert()
|
|
|
|
- alert.messageText = NSLocalizedString(msg!, comment: "")
|
|
|
|
- alert.addButton(withTitle: NSLocalizedString("OK", comment: ""))
|
|
|
|
- let response = alert.runModal()
|
|
|
|
|
|
+ KMMemberCenterManager.showAlert(code: .init(rawValue: resultDict.code), message: resultDict.msg) { response, _ in
|
|
if response == .alertFirstButtonReturn {
|
|
if response == .alertFirstButtonReturn {
|
|
if(resultDict.code == 317) {
|
|
if(resultDict.code == 317) {
|
|
self.signUpState = .verificationCode
|
|
self.signUpState = .verificationCode
|
|
self.countDown(type: .login, callback: nil)
|
|
self.countDown(type: .login, callback: nil)
|
|
- } else {
|
|
|
|
- KMMemberCenterManager.showAlert(code: .init(rawValue: resultDict.code), message: resultDict.msg, callback: nil)
|
|
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|