|
|
@@ -216,7 +216,8 @@ public class GroupRelationFrontServiceImpl implements GroupRelationFrontService
|
|
|
}
|
|
|
//查看双重验证码
|
|
|
if (StrUtil.isNotEmpty(ticket.getApiSecret())) {
|
|
|
- Integer codeNum = getUserCodeNumBySkuId(ticket.getUserId(), ticket.getSkuId());
|
|
|
+ Boolean isHasVerifyCode = StrUtil.isNotBlank(ticket.getVerifyCode()) ? true : false;
|
|
|
+ Integer codeNum = getUserCodeNumBySkuId(ticket.getUserId(), ticket.getSkuId(), isHasVerifyCode);
|
|
|
ticket.setCodeNum(codeNum);
|
|
|
}
|
|
|
});
|
|
|
@@ -576,7 +577,7 @@ public class GroupRelationFrontServiceImpl implements GroupRelationFrontService
|
|
|
}
|
|
|
|
|
|
@Override
|
|
|
- public Integer getUserCodeNumBySkuId(Long userId, Long skuId) {
|
|
|
+ public Integer getUserCodeNumBySkuId(Long userId, Long skuId, Boolean isHasVerifyCode) {
|
|
|
//查看双重验证码
|
|
|
UserFuncProperty userFuncProperty = userFuncPropertyMapper.selectOne(Wrappers.lambdaQuery(UserFuncProperty.class).eq(UserFuncProperty::getUserId, userId).last("limit 1"));
|
|
|
//默认0次
|
|
|
@@ -586,6 +587,10 @@ public class GroupRelationFrontServiceImpl implements GroupRelationFrontService
|
|
|
if (sku.getCodeNum() > 0) {
|
|
|
num = sku.getCodeNum();
|
|
|
}
|
|
|
+ //有安全码并客服未设置对应用户可查看次数 置为0
|
|
|
+ if (isHasVerifyCode && userFuncProperty == null) {
|
|
|
+ num = 0;
|
|
|
+ }
|
|
|
if (userFuncProperty != null) num = userFuncProperty.getVerifyCheckNum();
|
|
|
return num;
|
|
|
}
|