实名唯一性判断,进件微小改动
This commit is contained in:
@@ -20,7 +20,9 @@ public interface IdCardService extends IService<IdCard> {
|
||||
default int getAgentCount(String certNo, String userId) {
|
||||
return ((IdCardMapper) getBaseMapper()).selectAgentCount(certNo, userId);
|
||||
}
|
||||
|
||||
default Integer getCountIdCard(String certNo){
|
||||
return ((IdCardMapper) getBaseMapper()).getCountIdCard(certNo);
|
||||
}
|
||||
/**
|
||||
* 获取实名的身份证信息
|
||||
* @param userId 用户id
|
||||
|
||||
@@ -416,6 +416,11 @@ public class AccountServiceImpl extends ServiceImpl<AccountMapper, Account> impl
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public void realNameAudit(CertificationDTO certificationDTO) {
|
||||
//验证唯一性
|
||||
Integer countIdCard = idCardService.getCountIdCard(certificationDTO.getCertnum());
|
||||
if (countIdCard > 0){
|
||||
throw new MsgException("身份证已注册");
|
||||
}
|
||||
UserApp tokenUa = uaService.queryUserAppByToken();
|
||||
if ("agent".equals(tokenUa.getUserType()) && "ZY_BST".equals(tokenUa.getRoleCode())) {
|
||||
IdCard condition = new IdCard().setCertNo(certificationDTO.getCertnum());
|
||||
@@ -445,7 +450,6 @@ public class AccountServiceImpl extends ServiceImpl<AccountMapper, Account> impl
|
||||
userApp.setMerchantCode(merchantCode);
|
||||
uaService.updateById(userApp);
|
||||
}
|
||||
|
||||
if (Objects.equals(userApp.getStatus(), 1) || Objects.equals(userApp.getStatus(), 3)) {
|
||||
throw new MsgException("当前状态不允许修改实名认证信息");
|
||||
}
|
||||
|
||||
@@ -807,6 +807,8 @@ public class UserAppServiceImpl extends ServiceImpl<UserAppMapper, UserApp> impl
|
||||
case "5":
|
||||
laKalaInterface.createTuoKeInfo(userId);
|
||||
break;
|
||||
case "6":
|
||||
ysAuditServiceV3.merchantAuditV3(userId, false);
|
||||
default:
|
||||
MsgException.throwException("未知的进件通道");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user