Merge remote-tracking branch 'origin/develop' into develop

master
liuxinxin 5 years ago
commit ded82ea5d9

@ -9,7 +9,7 @@
</parent> </parent>
<modelVersion>4.0.0</modelVersion> <modelVersion>4.0.0</modelVersion>
<artifactId>manage</artifactId> <artifactId>manage</artifactId>
<version>1.2.72</version> <version>1.2.74</version>
<properties> <properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<jib-maven-plugin.version>1.4.0</jib-maven-plugin.version> <jib-maven-plugin.version>1.4.0</jib-maven-plugin.version>

@ -2196,7 +2196,7 @@ public class RetailAppServiceImp implements RetailAppService {
throw new BadRequestException("Verification code is wrong"); throw new BadRequestException("Verification code is wrong");
} }
List<JSONObject> account = clientAccountMapper.findByPhone(contactPhone, "+" + nationCode); List<JSONObject> account = clientAccountMapper.findByPhone(contactPhone, "+" + nationCode);
if (account != null) { if (account != null && account.size()>0) {
throw new BadRequestException("Mobile phone number has been bound to other users, please unbind it before binding"); throw new BadRequestException("Mobile phone number has been bound to other users, please unbind it before binding");
} }

@ -281,7 +281,7 @@ public class SimpleClientApplyServiceImpl implements SimpleClientApplyService {
nation_code = "+" + nation_code; nation_code = "+" + nation_code;
} }
List<JSONObject> account = clientAccountMapper.findByPhone(contact_phone, nation_code); List<JSONObject> account = clientAccountMapper.findByPhone(contact_phone, nation_code);
if (account != null) { if (account != null && account.size()>0) {
throw new ForbiddenException("用户名已被注册"); throw new ForbiddenException("用户名已被注册");
} }
} }
@ -599,7 +599,7 @@ public class SimpleClientApplyServiceImpl implements SimpleClientApplyService {
JSONObject apply = sysClientPreMapperMapper.findByUserName(username); JSONObject apply = sysClientPreMapperMapper.findByUserName(username);
List<JSONObject> account = clientAccountMapper.findByPhone(apply.getString("contact_phone"), "+61"); List<JSONObject> account = clientAccountMapper.findByPhone(apply.getString("contact_phone"), "+61");
if (account != null) { if (account != null && account.size() > 0) {
throw new ForbiddenException("The user name has been registered"); throw new ForbiddenException("The user name has been registered");
} }
String clientMoniker = generateClientMoniker(); String clientMoniker = generateClientMoniker();

@ -1579,7 +1579,8 @@ public class ClientManagerImpl implements ClientManager, ManagerTodoNoticeProvid
} }
private void checkPhoneAndWechatExist(NewAccountBean account) { private void checkPhoneAndWechatExist(NewAccountBean account) {
if (clientAccountMapper.findByPhone(account.getContactPhone(), account.getNation_code().startsWith("+")?account.getNation_code():"+"+account.getNation_code()) != null) { List<JSONObject> accounts = clientAccountMapper.findByPhone(account.getContactPhone(), account.getNation_code().startsWith("+") ? account.getNation_code() : "+" + account.getNation_code());
if ( accounts != null && accounts.size()>0) {
throw new BadRequestException("Mobile phone number has been bound to other accounts"); throw new BadRequestException("Mobile phone number has been bound to other accounts");
} }
} }

Loading…
Cancel
Save