Commit dbf41fde by 伍思炜

宽带下单时的多媒体账号校验规则修改2.0

parent 8fcd43be
...@@ -146,12 +146,14 @@ public class DankuanController { ...@@ -146,12 +146,14 @@ public class DankuanController {
if (StringUtils.isNotBlank(regularId)){ if (StringUtils.isNotBlank(regularId)){
Wrapper<Regular> wrapper = new EntityWrapper<>(); Wrapper<Regular> wrapper = new EntityWrapper<>();
Regular regular = regularMapper.selectById(regularId); Regular regular = regularMapper.selectById(regularId);
if (StringUtils.isNotBlank(regular.getRegular())) {
String orderCustomerAccounts = orderCustomerAccount.split("@")[0]; String orderCustomerAccounts = orderCustomerAccount.split("@")[0];
Pattern iphoneVerification = Pattern.compile(regular.getRegular().replace("/","")); Pattern iphoneVerification = Pattern.compile(regular.getRegular().replace("/", ""));
if (!iphoneVerification.matcher(orderCustomerAccounts).matches()) { if (!iphoneVerification.matcher(orderCustomerAccounts).matches()) {
return ResponseData.error(regular.getTips()); return ResponseData.error(regular.getTips());
} }
} }
}
} else { } else {
return ResponseData.error("多媒体账号不能为空"); return ResponseData.error("多媒体账号不能为空");
} }
......
...@@ -180,10 +180,12 @@ public class RongHeController { ...@@ -180,10 +180,12 @@ public class RongHeController {
if (StringUtils.isNotBlank(regularId)){ if (StringUtils.isNotBlank(regularId)){
Wrapper<Regular> wrapper = new EntityWrapper<>(); Wrapper<Regular> wrapper = new EntityWrapper<>();
Regular regular = regularMapper.selectById(regularId); Regular regular = regularMapper.selectById(regularId);
if (StringUtils.isNotBlank(regular.getRegular())) {
String orderCustomerAccounts = orderCustomerAccount.split("@")[0]; String orderCustomerAccounts = orderCustomerAccount.split("@")[0];
Pattern iphoneVerification = Pattern.compile(regular.getRegular().replace("/","")); Pattern iphoneVerification = Pattern.compile(regular.getRegular().replace("/", ""));
if (!iphoneVerification.matcher(orderCustomerAccounts).matches()) { if (!iphoneVerification.matcher(orderCustomerAccounts).matches()) {
return ResponseData.error("账号格式错误"); return ResponseData.error(regular.getTips());
}
} }
} }
} else { } else {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment