|
@@ -19,6 +19,7 @@ import com.sunxung.factoring.entity.bocom.log.BocomRequestLog;
|
|
|
import com.sunxung.factoring.entity.bocom.register.BocomAuthorizedAgent;
|
|
|
import com.sunxung.factoring.entity.bocom.register.BocomBasicInfo;
|
|
|
import com.sunxung.factoring.entity.bocom.register.BocomLegalPersonInfo;
|
|
|
+import com.sunxung.factoring.entity.bocom.register.BocomShareholderActualController;
|
|
|
import com.sunxung.factoring.entity.bocom.request.*;
|
|
|
import com.sunxung.factoring.entity.bocom.response.*;
|
|
|
import com.sunxung.factoring.entity.bocom.vipaccount.*;
|
|
@@ -50,7 +51,6 @@ import java.math.BigDecimal;
|
|
|
import java.text.SimpleDateFormat;
|
|
|
import java.util.*;
|
|
|
import java.util.concurrent.CompletableFuture;
|
|
|
-import java.util.stream.Collectors;
|
|
|
|
|
|
/**
|
|
|
* <p>
|
|
@@ -136,8 +136,8 @@ public class BocomVipAccountBasicInfoServiceImpl extends ServiceImpl<BocomVipAcc
|
|
|
bocomVipAccountBasicInfo.setExpiringDate(new Date());
|
|
|
}
|
|
|
save(bocomVipAccountBasicInfo);
|
|
|
- if (CollectionUtil.isNotEmpty(bocomVipAccountBasicInfo.getNoticeInfoList())){
|
|
|
- bocomVipAccountBasicInfo.getNoticeInfoList().forEach(n->{
|
|
|
+ if (CollectionUtil.isNotEmpty(bocomVipAccountBasicInfo.getNoticeInfoList())) {
|
|
|
+ bocomVipAccountBasicInfo.getNoticeInfoList().forEach(n -> {
|
|
|
n.setBocomVipAccountBasicInfoId(bocomVipAccountBasicInfo.getId());
|
|
|
bocomVipAccountNoticeInfoService.save(n);
|
|
|
});
|
|
@@ -458,7 +458,7 @@ public class BocomVipAccountBasicInfoServiceImpl extends ServiceImpl<BocomVipAcc
|
|
|
BocomVipAccountBasicInfo newVipAccountInfo = autoQueryVipRequest(vipAccountBasicInfo);
|
|
|
//新旧对比 如果之前状态不是客户授权中 现在是客户授权中 则重置二维码及二维码的生效时间
|
|
|
if (0 == newVipAccountInfo.getAuthorizationStatus() && !newVipAccountInfo.getAuthorizationStatus().equals(vipAccountBasicInfo.getAuthorizationStatus())) {
|
|
|
- resetUrl(newVipAccountInfo.getId());
|
|
|
+ resetUrl(newVipAccountInfo.getId());
|
|
|
}
|
|
|
if (1 == newVipAccountInfo.getAccountStatus() && !newVipAccountInfo.getAccountStatus().equals(vipAccountBasicInfo.getAccountStatus())) {
|
|
|
newVipAccountInfo.setOpenTime(new Date());
|
|
@@ -655,9 +655,9 @@ public class BocomVipAccountBasicInfoServiceImpl extends ServiceImpl<BocomVipAcc
|
|
|
BocomVipAccountBasicInfo vipAccountBasicInfo = resetUrlAuthorized(basicInfo);
|
|
|
//全删全进
|
|
|
bocomVipAccountNoticeInfoService.remove(new QueryWrapper<BocomVipAccountNoticeInfo>()
|
|
|
- .eq("bocom_vip_account_basic_info_id",vipAccountBasicInfo.getId()));
|
|
|
- if (CollectionUtil.isNotEmpty(vipAccountBasicInfo.getNoticeInfoList())){
|
|
|
- vipAccountBasicInfo.getNoticeInfoList().forEach(n->{
|
|
|
+ .eq("bocom_vip_account_basic_info_id", vipAccountBasicInfo.getId()));
|
|
|
+ if (CollectionUtil.isNotEmpty(vipAccountBasicInfo.getNoticeInfoList())) {
|
|
|
+ vipAccountBasicInfo.getNoticeInfoList().forEach(n -> {
|
|
|
bocomVipAccountNoticeInfoService.save(n);
|
|
|
});
|
|
|
}
|
|
@@ -2479,11 +2479,16 @@ public class BocomVipAccountBasicInfoServiceImpl extends ServiceImpl<BocomVipAcc
|
|
|
|
|
|
/**
|
|
|
* 填充授权代理人
|
|
|
+ *
|
|
|
* @param bocomVipAccountBasicInfo
|
|
|
*/
|
|
|
- private void autoAuthenticator(BocomVipAccountBasicInfo bocomVipAccountBasicInfo){
|
|
|
+ private void autoAuthenticator(BocomVipAccountBasicInfo bocomVipAccountBasicInfo) {
|
|
|
+
|
|
|
BocomBasicInfo basicInfo = bocomBasicInfoService.get(bocomVipAccountBasicInfo.getBocomBasicInfoId());
|
|
|
- if (CollectionUtil.isNotEmpty(bocomVipAccountBasicInfo.getNoticeInfoList())) {
|
|
|
+ List<BocomVipAccountNoticeInfo> noticeInfoList = bocomVipAccountNoticeInfoService.lambdaQuery()
|
|
|
+ .eq(BocomVipAccountNoticeInfo::getBocomVipAccountBasicInfoId, bocomVipAccountBasicInfo.getId())
|
|
|
+ .list();
|
|
|
+ if (CollectionUtil.isNotEmpty(noticeInfoList)) {
|
|
|
//授权代理人
|
|
|
BocomAuthorizedAgent authorizedAgent = bocomAuthorizedAgentService.lambdaQuery()
|
|
|
.eq(BocomAuthorizedAgent::getBocomBasicInfoId, basicInfo.getId())
|
|
@@ -2492,16 +2497,28 @@ public class BocomVipAccountBasicInfoServiceImpl extends ServiceImpl<BocomVipAcc
|
|
|
BocomLegalPersonInfo legalPersonInfo = bocomLegalPersonInfoService.lambdaQuery()
|
|
|
.eq(BocomLegalPersonInfo::getBocomBasicInfoId, basicInfo.getId())
|
|
|
.one();
|
|
|
- bocomVipAccountBasicInfo.getNoticeInfoList().forEach(n->{
|
|
|
- if (n.getNoticeObject().equals("1")){
|
|
|
- n.setAuthenticator(legalPersonInfo.getName());
|
|
|
+ //负责人
|
|
|
+ BocomShareholderActualController actualController = bocomShareholderActualControllerService.lambdaQuery()
|
|
|
+ .eq(BocomShareholderActualController::getBocomBasicInfoId, basicInfo.getId())
|
|
|
+ .eq(BocomShareholderActualController::getPersonType, 2)
|
|
|
+ .one();
|
|
|
+ bocomVipAccountBasicInfo.getNoticeInfoList().forEach(n -> {
|
|
|
+ if (n.getNoticeObject().equals("1")) {
|
|
|
+ if (basicInfo.getCustomerType() == 0) {
|
|
|
+ n.setAuthenticator(legalPersonInfo.getName());
|
|
|
+ } else if (basicInfo.getCustomerType() == 1) {
|
|
|
+ n.setAuthenticator(actualController.getName());
|
|
|
+ }
|
|
|
+
|
|
|
}
|
|
|
- if (n.getNoticeObject().equals("2")){
|
|
|
+ if (n.getNoticeObject().equals("2")) {
|
|
|
n.setAuthenticator(authorizedAgent.getName());
|
|
|
}
|
|
|
});
|
|
|
|
|
|
}
|
|
|
+ bocomVipAccountBasicInfo.setNoticeInfoList(noticeInfoList);
|
|
|
+
|
|
|
}
|
|
|
|
|
|
|