Browse Source

同步Server最新接口更改

loki.wu 2 years ago
parent
commit
ea140f02cf
3 changed files with 8 additions and 2 deletions
  1. 1 0
      lib/services/authentication.m.dart
  2. 2 2
      lib/services/email.dart
  3. 5 0
      lib/services/login.m.dart

+ 1 - 0
lib/services/authentication.m.dart

@@ -6229,6 +6229,7 @@ enum CustomerRpcCode {
 	AccountIsEmpty,
 	AccountLengthError,
 	VerificationCodeIncorrect,
+	EmailVerifyCodeExpired,
 }
 
 class ValidateTokenResult {

+ 2 - 2
lib/services/email.dart

@@ -17,8 +17,8 @@ class EmailService extends JsonRpcClientBase {
 						timeout: timeout,
 				);
 
-	Future<bool> sendEmailAsync(List<String> receivers,String templateName,List<String> templateArg) async {
-		var rpcRst = await call("SendEmailAsync", [receivers,templateName,templateArg]);
+	Future<bool> sendEmailAsync(String language,List<String> receivers,String templateName,List<String> templateArg) async {
+		var rpcRst = await call("SendEmailAsync", [language,receivers,templateName,templateArg]);
 		return rpcRst;
 	}
 

+ 5 - 0
lib/services/login.m.dart

@@ -171,14 +171,17 @@ class SendSMSVerificationCodeRequest {
 
 class SendEmailVerificationCodeRequest {
 	String? emailAddress;
+	String? languageCode;
 
 	SendEmailVerificationCodeRequest({
 		this.emailAddress,
+		this.languageCode,
 	});
 
 	factory SendEmailVerificationCodeRequest.fromJson(Map<String, dynamic> map) {
 		return SendEmailVerificationCodeRequest( 
 			emailAddress: map['EmailAddress'],
+			languageCode: map['LanguageCode'],
 		);
 	}
 
@@ -186,6 +189,8 @@ class SendEmailVerificationCodeRequest {
 		final map = Map<String, dynamic>();
 		if(emailAddress != null)
 			map['EmailAddress'] = emailAddress;
+		if(languageCode != null)
+			map['LanguageCode'] = languageCode;
 		return map;
 	}
 }