Эх сурвалжийг харах

fix 兼容奈飞安全码

zoujiajian 2 жил өмнө
parent
commit
f63835623d

+ 4 - 1
netflix-service/src/main/java/com/cyksj/service/mail/impl/CuiQiuMailServiceImpl.java

@@ -129,8 +129,11 @@ public class CuiQiuMailServiceImpl implements CuiQiuMailService {
 		if (goodsId == 1) {
 			if (type != null && type == 1) {
 				String pre = "NetflixSans-Regular, Helvetica, Roboto, Segoe UI, sans-serif; font-weight";
-				if (body.contains("輸入此代碼登入") || body.contains("输入此代码登录")) {
+				if (body.contains("輸入此代碼登入") || body.contains("输入此代码登录") || body.contains("Enter this code to sign in")) {
 					code = StrUtil.subAfter(body, pre, false);
+					if (StrUtil.isEmpty(code)) {
+						code = StrUtil.subAfter(body, "Enter this code to sign in", true);
+					}
 				}
 				if (StrUtil.isEmpty(code)) {
 					throw BusinessRuntimeException.getInstance("查询失败,请检查是否发送了登陆码..");

+ 4 - 1
netflix-service/src/main/java/com/cyksj/service/relation/impl/GroupRelationFrontServiceImpl.java

@@ -767,11 +767,14 @@ public class GroupRelationFrontServiceImpl implements GroupRelationFrontService
 		//奈飞
 		if (goodsId == 1) {
 			if (type != null && type == 1) {
-				if (body.contains("輸入此代碼登入") || body.contains("输入此代码登录")) {
+				if (body.contains("輸入此代碼登入") || body.contains("输入此代码登录") || body.contains("Enter this code to sign in")) {
 					code = StrUtil.subBetween(body, "輸入此代碼登入", "請在裝置上輸入上");
 					if (StrUtil.isEmpty(code)) {
 						code = StrUtil.subAfter(body, "输入此代码登录", true);
 					}
+					if (StrUtil.isEmpty(code)) {
+						code = StrUtil.subAfter(body, "Enter this code to sign in", true);
+					}
 				}
 				if (StrUtil.isEmpty(code)) {
 					throw BusinessRuntimeException.getInstance("查询失败,请检查是否发送了登陆码..");