|
@@ -12,6 +12,7 @@ import com.inkasso.factoring.bocom.register.entity.BocomAuthorizedAgent;
|
|
|
import com.inkasso.factoring.bocom.register.entity.BocomBasicInfo;
|
|
|
import com.inkasso.factoring.bocom.register.entity.BocomLegalPersonInfo;
|
|
|
import com.inkasso.factoring.bocom.register.entity.BocomShareholderActualController;
|
|
|
+import com.inkasso.factoring.bocom.register.enums.BocomCustomerStatuEnums;
|
|
|
import com.inkasso.factoring.bocom.register.service.IBocomAuthorizedAgentService;
|
|
|
import com.inkasso.factoring.bocom.register.service.IBocomBasicInfoService;
|
|
|
import com.inkasso.factoring.bocom.register.service.IBocomLegalPersonInfoService;
|
|
@@ -114,7 +115,7 @@ public class BocomVipAccountBasicInfoServiceImpl extends ServiceImpl<BocomVipAcc
|
|
|
if (CollectionUtils.isNotEmpty(vipList)) {
|
|
|
vipList.forEach(vipAccountBasicInfo -> {
|
|
|
|
|
|
- autoAccountRealStatus(vipAccountBasicInfo);
|
|
|
+// autoAccountRealStatus(vipAccountBasicInfo);
|
|
|
|
|
|
if (bocomBasicInfo != null) {
|
|
|
//填充需要授权的人
|
|
@@ -155,10 +156,13 @@ public class BocomVipAccountBasicInfoServiceImpl extends ServiceImpl<BocomVipAcc
|
|
|
} else {
|
|
|
vipAccountBasicInfo.setIsRebuild(1);
|
|
|
}
|
|
|
- //客户状态
|
|
|
- if (customerStatusDic != null) {
|
|
|
- vo.setCustomerStatus(customerStatusDic.getName());
|
|
|
+
|
|
|
+ //填充真实状态
|
|
|
+ Dictionary customerStatusRealDic = dictionaryService.getByCode(vipAccountBasicInfo.getAccountStatusReal());
|
|
|
+ if (customerStatusRealDic != null) {
|
|
|
+ vipAccountBasicInfo.setAccountStatusReal(customerStatusRealDic.getName());
|
|
|
}
|
|
|
+
|
|
|
//静默户数量
|
|
|
Integer count = Math.toIntExact(bocomVipSilentAccoutInfoService.lambdaQuery()
|
|
|
.eq(BocomVipSilentAccountInfo::getBocomVipAccountBasicInfoId, vipAccountBasicInfo.getId())
|
|
@@ -177,7 +181,7 @@ public class BocomVipAccountBasicInfoServiceImpl extends ServiceImpl<BocomVipAcc
|
|
|
vo.setVipAccountBasicInfoList(vipList);
|
|
|
}
|
|
|
|
|
|
- if ("生效".equals(bocomBasicInfo.getCustomerRealStatus())) {
|
|
|
+ if (BocomCustomerStatuEnums.SUCCESS.getCode().equals(bocomBasicInfo.getCustomerStatus())) {
|
|
|
//客户真实状态为生效 且 该客户名下不存在待生效的登记簿 或者 该客户下账户状态为 生效的 会员登记簿少于五个时 展示新增账户按钮
|
|
|
Integer addVipAccount = 1;
|
|
|
if (CollectionUtil.isNotEmpty(vipList)){
|
|
@@ -491,53 +495,53 @@ public class BocomVipAccountBasicInfoServiceImpl extends ServiceImpl<BocomVipAcc
|
|
|
*
|
|
|
* @param vipAccountBasicInfo
|
|
|
*/
|
|
|
- private void autoAccountRealStatus(BocomVipAccountBasicInfo vipAccountBasicInfo) {
|
|
|
-
|
|
|
- if (vipAccountBasicInfo != null) {
|
|
|
- BocomVipLimitInfo vipLimitInfo = bocomVipLimitInfoService
|
|
|
- .lambdaQuery()
|
|
|
- .eq(BocomVipLimitInfo::getBocomVipAccountBasicInfoId, vipAccountBasicInfo.getId())
|
|
|
- .one();
|
|
|
-
|
|
|
- String realStatus = "";
|
|
|
- if (vipAccountBasicInfo.getAccountStatus() == 1 ) {
|
|
|
- // 授权状态 0-待用户授权 1-银行审核中 2-授权失败(用户拒绝)3-授权失败(银行拒绝)4-授权成功
|
|
|
- //授权代理人授权状态
|
|
|
- Integer authorizationStatus = vipAccountBasicInfo.getAuthorizationStatus();
|
|
|
- //法人授权状态
|
|
|
- Integer legalAuthorizationStatus = vipAccountBasicInfo.getLegalAuthorizationStatus();
|
|
|
-
|
|
|
-
|
|
|
- if (authorizationStatus == 1 || legalAuthorizationStatus == 1 ||
|
|
|
- authorizationStatus == 2 || legalAuthorizationStatus == 2 ||
|
|
|
- authorizationStatus == 3 || legalAuthorizationStatus == 3) {
|
|
|
- //任一授权状态为 1/2/3 时 账户真实状态置为 开通失败
|
|
|
- realStatus = "开通失败";
|
|
|
- }
|
|
|
-
|
|
|
- if ((authorizationStatus == 0 || authorizationStatus == 4) && (authorizationStatus == 0 || authorizationStatus == 4)) {
|
|
|
- //授权状态组合为 0+0 || 0+4 时 且 可收可付款(无收入管控且无支出管控)且 接口返回的登记簿状态为是生效 时 账户真实状态置为 生效
|
|
|
- if (vipAccountBasicInfo.getChdbokSts() != null && vipAccountBasicInfo.getChdbokSts() == 1 || (vipLimitInfo != null && vipLimitInfo.getIncFlg() == 1 && vipLimitInfo.getPayFlg() == 1)) {
|
|
|
- realStatus = "生效";
|
|
|
- } else {
|
|
|
- //授权状态组合为 0+0 || 0+4 时 且 可收可付款(无收入管控且无支出管控) 时 账户真实状态置为 待生效
|
|
|
- realStatus = "待生效";
|
|
|
- }
|
|
|
- }
|
|
|
-
|
|
|
- if (authorizationStatus == 4 && authorizationStatus == 4) {
|
|
|
- //授权状态组合为 4+4 且 可收可付款(无收入管控且无支出管控) 时 账户真实状态置 为 生效
|
|
|
- if (vipAccountBasicInfo.getChdbokSts() != null && vipAccountBasicInfo.getChdbokSts() == 1 || (vipLimitInfo != null && vipLimitInfo.getIncFlg() == 1 && vipLimitInfo.getPayFlg() == 1)) {
|
|
|
- realStatus = "生效";
|
|
|
- }
|
|
|
- }
|
|
|
-
|
|
|
- } else {
|
|
|
- realStatus = "失效";
|
|
|
- }
|
|
|
- vipAccountBasicInfo.setAccountStatusReal(realStatus);
|
|
|
- }
|
|
|
- }
|
|
|
+// private void autoAccountRealStatus(BocomVipAccountBasicInfo vipAccountBasicInfo) {
|
|
|
+//
|
|
|
+// if (vipAccountBasicInfo != null) {
|
|
|
+// BocomVipLimitInfo vipLimitInfo = bocomVipLimitInfoService
|
|
|
+// .lambdaQuery()
|
|
|
+// .eq(BocomVipLimitInfo::getBocomVipAccountBasicInfoId, vipAccountBasicInfo.getId())
|
|
|
+// .one();
|
|
|
+//
|
|
|
+// String realStatus = "";
|
|
|
+// if (vipAccountBasicInfo.getAccountStatus() == 1 ) {
|
|
|
+// // 授权状态 0-待用户授权 1-银行审核中 2-授权失败(用户拒绝)3-授权失败(银行拒绝)4-授权成功
|
|
|
+// //授权代理人授权状态
|
|
|
+// Integer authorizationStatus = vipAccountBasicInfo.getAuthorizationStatus();
|
|
|
+// //法人授权状态
|
|
|
+// Integer legalAuthorizationStatus = vipAccountBasicInfo.getLegalAuthorizationStatus();
|
|
|
+//
|
|
|
+//
|
|
|
+// if (authorizationStatus == 1 || legalAuthorizationStatus == 1 ||
|
|
|
+// authorizationStatus == 2 || legalAuthorizationStatus == 2 ||
|
|
|
+// authorizationStatus == 3 || legalAuthorizationStatus == 3) {
|
|
|
+// //任一授权状态为 1/2/3 时 账户真实状态置为 开通失败
|
|
|
+// realStatus = "开通失败";
|
|
|
+// }
|
|
|
+//
|
|
|
+// if ((authorizationStatus == 0 || authorizationStatus == 4) && (authorizationStatus == 0 || authorizationStatus == 4)) {
|
|
|
+// //授权状态组合为 0+0 || 0+4 时 且 可收可付款(无收入管控且无支出管控)且 接口返回的登记簿状态为是生效 时 账户真实状态置为 生效
|
|
|
+// if (vipAccountBasicInfo.getChdbokSts() != null && vipAccountBasicInfo.getChdbokSts() == 1 || (vipLimitInfo != null && vipLimitInfo.getIncFlg() == 1 && vipLimitInfo.getPayFlg() == 1)) {
|
|
|
+// realStatus = "生效";
|
|
|
+// } else {
|
|
|
+// //授权状态组合为 0+0 || 0+4 时 且 可收可付款(无收入管控且无支出管控) 时 账户真实状态置为 待生效
|
|
|
+// realStatus = "待生效";
|
|
|
+// }
|
|
|
+// }
|
|
|
+//
|
|
|
+// if (authorizationStatus == 4 && authorizationStatus == 4) {
|
|
|
+// //授权状态组合为 4+4 且 可收可付款(无收入管控且无支出管控) 时 账户真实状态置 为 生效
|
|
|
+// if (vipAccountBasicInfo.getChdbokSts() != null && vipAccountBasicInfo.getChdbokSts() == 1 || (vipLimitInfo != null && vipLimitInfo.getIncFlg() == 1 && vipLimitInfo.getPayFlg() == 1)) {
|
|
|
+// realStatus = "生效";
|
|
|
+// }
|
|
|
+// }
|
|
|
+//
|
|
|
+// } else {
|
|
|
+// realStatus = "失效";
|
|
|
+// }
|
|
|
+// vipAccountBasicInfo.setAccountStatus(realStatus);
|
|
|
+// }
|
|
|
+// }
|
|
|
|
|
|
|
|
|
}
|