Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
Y
yd-csf
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
xingmin
yd-csf
Commits
7b943b2c
Commit
7b943b2c
authored
Dec 19, 2025
by
zhangxingmin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
预约-v1版本
parent
477ad0a9
Hide whitespace changes
Inline
Side-by-side
Showing
104 changed files
with
4420 additions
and
1726 deletions
+4420
-1726
.idea/encodings.xml
+1
-0
yd-csf-api/pom.xml
+6
-0
yd-csf-api/src/main/java/com/yd/csf/api/controller/ApiAppointmentController.java
+90
-3
yd-csf-api/src/main/java/com/yd/csf/api/controller/ApiCsfCommonController.java
+39
-0
yd-csf-api/src/main/java/com/yd/csf/api/controller/AppointmentLogController.java
+18
-0
yd-csf-api/src/main/java/com/yd/csf/api/controller/AppointmentReferrerController.java
+18
-0
yd-csf-api/src/main/java/com/yd/csf/api/controller/AppointmentReferrerLogController.java
+18
-0
yd-csf-api/src/main/java/com/yd/csf/api/controller/AppointmentUserSignController.java
+18
-0
yd-csf-api/src/main/java/com/yd/csf/api/controller/AppointmentUserSignLogController.java
+18
-0
yd-csf-api/src/main/java/com/yd/csf/api/controller/TaxationController.java
+18
-0
yd-csf-api/src/main/java/com/yd/csf/api/service/ApiAppointmentLogService.java
+9
-0
yd-csf-api/src/main/java/com/yd/csf/api/service/ApiAppointmentReferrerLogService.java
+12
-0
yd-csf-api/src/main/java/com/yd/csf/api/service/ApiAppointmentReferrerService.java
+12
-0
yd-csf-api/src/main/java/com/yd/csf/api/service/ApiAppointmentService.java
+9
-3
yd-csf-api/src/main/java/com/yd/csf/api/service/ApiAppointmentUserSignLogService.java
+12
-0
yd-csf-api/src/main/java/com/yd/csf/api/service/ApiAppointmentUserSignService.java
+12
-0
yd-csf-api/src/main/java/com/yd/csf/api/service/ApiCsfCommonService.java
+11
-0
yd-csf-api/src/main/java/com/yd/csf/api/service/impl/ApiAppointmentCheckServiceImpl.java
+268
-265
yd-csf-api/src/main/java/com/yd/csf/api/service/impl/ApiAppointmentLogServiceImpl.java
+37
-0
yd-csf-api/src/main/java/com/yd/csf/api/service/impl/ApiAppointmentReferrerLogServiceImpl.java
+48
-0
yd-csf-api/src/main/java/com/yd/csf/api/service/impl/ApiAppointmentReferrerServiceImpl.java
+53
-0
yd-csf-api/src/main/java/com/yd/csf/api/service/impl/ApiAppointmentServiceImpl.java
+285
-87
yd-csf-api/src/main/java/com/yd/csf/api/service/impl/ApiAppointmentUserSignLogServiceImpl.java
+48
-0
yd-csf-api/src/main/java/com/yd/csf/api/service/impl/ApiAppointmentUserSignServiceImpl.java
+52
-0
yd-csf-api/src/main/java/com/yd/csf/api/service/impl/ApiBeneficiaryServiceImpl.java
+14
-62
yd-csf-api/src/main/java/com/yd/csf/api/service/impl/ApiCsfCommonServiceImpl.java
+282
-0
yd-csf-api/src/main/java/com/yd/csf/api/service/impl/ApiInsurantServiceImpl.java
+38
-3
yd-csf-api/src/main/java/com/yd/csf/api/service/impl/ApiPolicyholderServiceImpl.java
+5
-1
yd-csf-api/src/main/java/com/yd/csf/api/service/impl/ApiProductPlanServiceImpl.java
+11
-4
yd-csf-api/src/main/java/com/yd/csf/api/service/impl/ApiSecondHolderServiceImpl.java
+1
-1
yd-csf-feign/pom.xml
+6
-0
yd-csf-feign/src/main/java/com/yd/csf/feign/client/appointment/ApiAppointmentFeignClient.java
+35
-1
yd-csf-feign/src/main/java/com/yd/csf/feign/client/common/ApiCsfCommonFeignClient.java
+27
-0
yd-csf-feign/src/main/java/com/yd/csf/feign/dto/appointment/ApiAppointmentInfoDto.java
+25
-67
yd-csf-feign/src/main/java/com/yd/csf/feign/dto/appointment/ApiAppointmentReferrerDto.java
+32
-0
yd-csf-feign/src/main/java/com/yd/csf/feign/dto/appointment/ApiAppointmentReferrerLogDto.java
+79
-0
yd-csf-feign/src/main/java/com/yd/csf/feign/dto/appointment/ApiAppointmentUserSignDto.java
+47
-0
yd-csf-feign/src/main/java/com/yd/csf/feign/dto/appointment/ApiAppointmentUserSignLogDto.java
+94
-0
yd-csf-feign/src/main/java/com/yd/csf/feign/dto/appointment/ApiBeneficiaryInfoDto.java
+16
-112
yd-csf-feign/src/main/java/com/yd/csf/feign/dto/appointment/ApiInsurantInfoDto.java
+147
-159
yd-csf-feign/src/main/java/com/yd/csf/feign/dto/appointment/ApiPolicyholderInfoDto.java
+138
-176
yd-csf-feign/src/main/java/com/yd/csf/feign/dto/appointment/ApiProductPlanInfoDto.java
+2
-0
yd-csf-feign/src/main/java/com/yd/csf/feign/dto/appointment/ApiProductPlanMainInfoDto.java
+44
-52
yd-csf-feign/src/main/java/com/yd/csf/feign/dto/appointment/ApiSecondHolderInfoDto.java
+10
-31
yd-csf-feign/src/main/java/com/yd/csf/feign/dto/excel/ApiExcelAppointmentMainDto.java
+11
-11
yd-csf-feign/src/main/java/com/yd/csf/feign/dto/excel/ApiExcelImportAppointmentDto.java
+23
-23
yd-csf-feign/src/main/java/com/yd/csf/feign/dto/taxation/ApiTaxationDto.java
+17
-0
yd-csf-feign/src/main/java/com/yd/csf/feign/enums/RelTypeEnum.java
+1
-1
yd-csf-feign/src/main/java/com/yd/csf/feign/fallback/appointment/ApiAppointmentFeignFallbackFactory.java
+21
-0
yd-csf-feign/src/main/java/com/yd/csf/feign/fallback/common/ApiCsfCommonFeignFallbackFactory.java
+28
-0
yd-csf-feign/src/main/java/com/yd/csf/feign/request/appointment/ApiAppointmentAddRequest.java
+6
-1
yd-csf-feign/src/main/java/com/yd/csf/feign/request/appointment/ApiAppointmentEditRequest.java
+4
-0
yd-csf-feign/src/main/java/com/yd/csf/feign/request/appointment/ApiAppointmentEditStatusRequest.java
+33
-0
yd-csf-feign/src/main/java/com/yd/csf/feign/request/appointment/ApiAppointmentEditStorageRequest.java
+46
-0
yd-csf-feign/src/main/java/com/yd/csf/feign/request/appointment/ApiAppointmentLogPageRequest.java
+10
-0
yd-csf-feign/src/main/java/com/yd/csf/feign/request/common/ApiCsfCalculateRequest.java
+26
-0
yd-csf-feign/src/main/java/com/yd/csf/feign/response/appointment/ApiAppointmentDetailResponse.java
+1
-1
yd-csf-feign/src/main/java/com/yd/csf/feign/response/appointment/ApiAppointmentLogDetailResponse.java
+202
-0
yd-csf-feign/src/main/java/com/yd/csf/feign/response/appointment/ApiAppointmentLogPageResponse.java
+49
-0
yd-csf-feign/src/main/java/com/yd/csf/feign/response/common/ApiCsfCalculateResponse.java
+31
-0
yd-csf-feign/src/main/java/com/yd/csf/feign/valid/GroupValid.java
+13
-0
yd-csf-service/src/main/java/com/yd/csf/service/dao/AppointmentLogMapper.java
+16
-0
yd-csf-service/src/main/java/com/yd/csf/service/dao/AppointmentMapper.java
+5
-0
yd-csf-service/src/main/java/com/yd/csf/service/dao/AppointmentReferrerLogMapper.java
+16
-0
yd-csf-service/src/main/java/com/yd/csf/service/dao/AppointmentReferrerMapper.java
+16
-0
yd-csf-service/src/main/java/com/yd/csf/service/dao/AppointmentUserSignLogMapper.java
+16
-0
yd-csf-service/src/main/java/com/yd/csf/service/dao/AppointmentUserSignMapper.java
+16
-0
yd-csf-service/src/main/java/com/yd/csf/service/dao/TaxationMapper.java
+16
-0
yd-csf-service/src/main/java/com/yd/csf/service/enums/AppointmentStatusEnum.java
+10
-4
yd-csf-service/src/main/java/com/yd/csf/service/model/Appointment.java
+12
-0
yd-csf-service/src/main/java/com/yd/csf/service/model/AppointmentLog.java
+335
-0
yd-csf-service/src/main/java/com/yd/csf/service/model/AppointmentReferrer.java
+107
-0
yd-csf-service/src/main/java/com/yd/csf/service/model/AppointmentReferrerLog.java
+107
-0
yd-csf-service/src/main/java/com/yd/csf/service/model/AppointmentUserSign.java
+125
-0
yd-csf-service/src/main/java/com/yd/csf/service/model/AppointmentUserSignLog.java
+125
-0
yd-csf-service/src/main/java/com/yd/csf/service/model/Beneficiary.java
+20
-122
yd-csf-service/src/main/java/com/yd/csf/service/model/Insurant.java
+141
-211
yd-csf-service/src/main/java/com/yd/csf/service/model/Policyholder.java
+137
-232
yd-csf-service/src/main/java/com/yd/csf/service/model/ProductPlan.java
+72
-54
yd-csf-service/src/main/java/com/yd/csf/service/model/SecondHolder.java
+23
-34
yd-csf-service/src/main/java/com/yd/csf/service/model/Taxation.java
+107
-0
yd-csf-service/src/main/java/com/yd/csf/service/service/IAppointmentLogService.java
+17
-0
yd-csf-service/src/main/java/com/yd/csf/service/service/IAppointmentReferrerLogService.java
+19
-0
yd-csf-service/src/main/java/com/yd/csf/service/service/IAppointmentReferrerService.java
+17
-0
yd-csf-service/src/main/java/com/yd/csf/service/service/IAppointmentService.java
+5
-0
yd-csf-service/src/main/java/com/yd/csf/service/service/IAppointmentUserSignLogService.java
+18
-0
yd-csf-service/src/main/java/com/yd/csf/service/service/IAppointmentUserSignService.java
+17
-0
yd-csf-service/src/main/java/com/yd/csf/service/service/ITaxationService.java
+16
-0
yd-csf-service/src/main/java/com/yd/csf/service/service/impl/AppointmentLogServiceImpl.java
+25
-0
yd-csf-service/src/main/java/com/yd/csf/service/service/impl/AppointmentReferrerLogServiceImpl.java
+28
-0
yd-csf-service/src/main/java/com/yd/csf/service/service/impl/AppointmentReferrerServiceImpl.java
+25
-0
yd-csf-service/src/main/java/com/yd/csf/service/service/impl/AppointmentServiceImpl.java
+8
-0
yd-csf-service/src/main/java/com/yd/csf/service/service/impl/AppointmentUserSignLogServiceImpl.java
+29
-0
yd-csf-service/src/main/java/com/yd/csf/service/service/impl/AppointmentUserSignServiceImpl.java
+25
-0
yd-csf-service/src/main/java/com/yd/csf/service/service/impl/PolicyServiceImpl.java
+1
-1
yd-csf-service/src/main/java/com/yd/csf/service/service/impl/TaxationServiceImpl.java
+20
-0
yd-csf-service/src/main/java/com/yd/csf/service/utils/MyBatisPlusCodeGenerator.java
+4
-4
yd-csf-service/src/main/resources/mappers/AppointmentLogMapper.xml
+5
-0
yd-csf-service/src/main/resources/mappers/AppointmentMapper.xml
+7
-0
yd-csf-service/src/main/resources/mappers/AppointmentReferrerLogMapper.xml
+5
-0
yd-csf-service/src/main/resources/mappers/AppointmentReferrerMapper.xml
+5
-0
yd-csf-service/src/main/resources/mappers/AppointmentUserSignLogMapper.xml
+5
-0
yd-csf-service/src/main/resources/mappers/AppointmentUserSignMapper.xml
+5
-0
yd-csf-service/src/main/resources/mappers/TaxationMapper.xml
+5
-0
No files found.
.idea/encodings.xml
View file @
7b943b2c
<?xml version="1.0" encoding="UTF-8"?>
<project
version=
"4"
>
<component
name=
"Encoding"
>
<file
url=
"file://$PROJECT_DIR$/src/main/java"
charset=
"UTF-8"
/>
<file
url=
"file://$PROJECT_DIR$/yd-csf-api/src/main/java"
charset=
"UTF-8"
/>
<file
url=
"file://$PROJECT_DIR$/yd-csf-api/src/main/resources"
charset=
"UTF-8"
/>
<file
url=
"file://$PROJECT_DIR$/yd-csf-feign/src/main/java"
charset=
"UTF-8"
/>
...
...
yd-csf-api/pom.xml
View file @
7b943b2c
...
...
@@ -97,6 +97,12 @@
<groupId>
org.springframework.boot
</groupId>
<artifactId>
spring-boot-starter-jdbc
</artifactId>
</dependency>
<!-- 如果使用pinyin4j进行拼音转换 -->
<dependency>
<groupId>
com.belerweb
</groupId>
<artifactId>
pinyin4j
</artifactId>
</dependency>
</dependencies>
<build>
...
...
yd-csf-api/src/main/java/com/yd/csf/api/controller/ApiAppointmentController.java
View file @
7b943b2c
package
com
.
yd
.
csf
.
api
.
controller
;
import
com.baomidou.mybatisplus.core.metadata.IPage
;
import
com.yd.common.exception.BusinessException
;
import
com.yd.common.result.Result
;
import
com.yd.csf.api.service.ApiAppointmentService
;
import
com.yd.csf.feign.client.appointment.ApiAppointmentFeignClient
;
import
com.yd.csf.feign.dto.appointment.ApiAppointmentInfoDto
;
import
com.yd.csf.feign.dto.appointment.ApiInsurantInfoDto
;
import
com.yd.csf.feign.request.appointment.*
;
import
com.yd.csf.feign.response.appointment.ApiAppointmentAddResponse
;
import
com.yd.csf.feign.response.appointment.ApiAppointmentDetailResponse
;
import
com.yd.csf.feign.response.appointment.ApiAppointmentPageResponse
;
import
com.yd.csf.feign.response.appointment.*
;
import
com.yd.csf.feign.valid.GroupValid
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.validation.annotation.Validated
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.RestController
;
import
javax.validation.ConstraintViolation
;
import
javax.validation.Validator
;
import
javax.validation.constraints.NotBlank
;
import
java.util.Objects
;
import
java.util.Set
;
/**
* 预约信息
...
...
@@ -30,6 +35,11 @@ public class ApiAppointmentController implements ApiAppointmentFeignClient {
@Autowired
private
ApiAppointmentService
apiAppointmentService
;
private
final
Validator
validator
;
public
ApiAppointmentController
(
Validator
validator
)
{
this
.
validator
=
validator
;
}
/**
* 预约分页查询
* @param request
...
...
@@ -67,6 +77,10 @@ public class ApiAppointmentController implements ApiAppointmentFeignClient {
*/
@Override
public
Result
<
ApiAppointmentAddResponse
>
add
(
ApiAppointmentAddRequest
request
)
{
//手动校验受保人信息(因为它没有 @Valid 注解)
ApiInsurantInfoDto
insurantInfo
=
request
.
getApiInsurantInfoDto
();
validateInsurantInfo
(
insurantInfo
);
return
apiAppointmentService
.
add
(
request
);
}
...
...
@@ -87,10 +101,24 @@ public class ApiAppointmentController implements ApiAppointmentFeignClient {
*/
@Override
public
Result
edit
(
ApiAppointmentEditRequest
request
)
{
//手动校验受保人信息(因为它没有 @Valid 注解)
ApiInsurantInfoDto
insurantInfo
=
request
.
getApiInsurantInfoDto
();
validateInsurantInfo
(
insurantInfo
);
return
apiAppointmentService
.
edit
(
request
);
}
/**
* 编辑预约暂存 (聚合信息编辑预约暂存)
* @param request
* @return
*/
@Override
public
Result
editStorage
(
ApiAppointmentEditStorageRequest
request
)
{
return
apiAppointmentService
.
editStorage
(
request
);
}
/**
* 确定预约时间提交 (流程流转到新单跟进)
* @param request
* @return
...
...
@@ -161,6 +189,16 @@ public class ApiAppointmentController implements ApiAppointmentFeignClient {
}
/**
* 编辑预约状态
* @param request
* @return
*/
@Override
public
Result
editStatus
(
ApiAppointmentEditStatusRequest
request
)
{
return
apiAppointmentService
.
editStatus
(
request
);
}
/**
* 删除预约信息
* @param appointmentBizId
* @return
...
...
@@ -170,5 +208,54 @@ public class ApiAppointmentController implements ApiAppointmentFeignClient {
return
apiAppointmentService
.
del
(
appointmentBizId
);
}
/**
* 历史记录 - 签约信息
* @param request
* @return
*/
@Override
public
Result
<
IPage
<
ApiAppointmentLogPageResponse
>>
logPage
(
ApiAppointmentLogPageRequest
request
)
{
return
apiAppointmentService
.
logPage
(
request
);
}
/**
* 历史记录 - 签约信息 - 详情
* @param appointmentLogBizId
* @return
*/
@Override
public
Result
<
ApiAppointmentLogDetailResponse
>
logDetail
(
String
appointmentLogBizId
)
{
return
apiAppointmentService
.
logDetail
(
appointmentLogBizId
);
}
/**
* 手动校验受保人信息
* @param insurantInfo
*/
private
void
validateInsurantInfo
(
ApiInsurantInfoDto
insurantInfo
)
{
if
(
Objects
.
isNull
(
insurantInfo
))
{
throw
new
BusinessException
(
"受保人信息不能为空"
);
}
// 根据与投保人关系选择校验组
Class
<?>[]
groups
;
if
(
insurantInfo
.
isSelf
())
{
// 本人关系:只校验 Always 组
groups
=
new
Class
<?>[]{
GroupValid
.
Always
.
class
};
}
else
{
// 非本人关系:校验 Always 和 NotSelf 组
groups
=
new
Class
<?>[]{
GroupValid
.
Always
.
class
,
GroupValid
.
NotSelf
.
class
};
}
// 执行手动校验
Set
<
ConstraintViolation
<
ApiInsurantInfoDto
>>
violations
=
validator
.
validate
(
insurantInfo
,
groups
);
// 如果校验失败,抛出业务异常
if
(!
violations
.
isEmpty
())
{
String
errorMessage
=
violations
.
iterator
().
next
().
getMessage
();
throw
new
BusinessException
(
errorMessage
);
}
}
}
yd-csf-api/src/main/java/com/yd/csf/api/controller/ApiCsfCommonController.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
api
.
controller
;
import
com.yd.common.result.Result
;
import
com.yd.csf.api.service.ApiCsfCommonService
;
import
com.yd.csf.feign.client.common.ApiCsfCommonFeignClient
;
import
com.yd.csf.feign.request.common.ApiCsfCalculateRequest
;
import
com.yd.csf.feign.response.common.ApiCsfCalculateResponse
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.validation.annotation.Validated
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.RestController
;
import
java.util.List
;
/**
* 公共接口信息
*
* @author zxm
* @since 2025-12-18
*/
@RestController
@RequestMapping
(
"/common"
)
@Validated
public
class
ApiCsfCommonController
implements
ApiCsfCommonFeignClient
{
@Autowired
private
ApiCsfCommonService
apiCsfCommonService
;
/**
* 计算-字段值
* @param request
* @return
*/
@Override
public
Result
<
List
<
ApiCsfCalculateResponse
>>
calculate
(
ApiCsfCalculateRequest
request
)
{
return
apiCsfCommonService
.
calculate
(
request
);
}
}
yd-csf-api/src/main/java/com/yd/csf/api/controller/AppointmentLogController.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
api
.
controller
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.RestController
;
/**
* <p>
* 预约信息日志表(快照表) 前端控制器
* </p>
*
* @author zxm
* @since 2025-12-15
*/
@RestController
@RequestMapping
(
"/appointmentLog"
)
public
class
AppointmentLogController
{
}
yd-csf-api/src/main/java/com/yd/csf/api/controller/AppointmentReferrerController.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
api
.
controller
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.RestController
;
/**
* <p>
* 预约-转介人信息表 前端控制器
* </p>
*
* @author zxm
* @since 2025-12-15
*/
@RestController
@RequestMapping
(
"/appointmentReferrer"
)
public
class
AppointmentReferrerController
{
}
yd-csf-api/src/main/java/com/yd/csf/api/controller/AppointmentReferrerLogController.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
api
.
controller
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.RestController
;
/**
* <p>
* 预约-转介人信息日志表(快照表) 前端控制器
* </p>
*
* @author zxm
* @since 2025-12-15
*/
@RestController
@RequestMapping
(
"/appointmentReferrerLog"
)
public
class
AppointmentReferrerLogController
{
}
yd-csf-api/src/main/java/com/yd/csf/api/controller/AppointmentUserSignController.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
api
.
controller
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.RestController
;
/**
* <p>
* 预约-签单员信息表 前端控制器
* </p>
*
* @author zxm
* @since 2025-12-15
*/
@RestController
@RequestMapping
(
"/appointmentUserSign"
)
public
class
AppointmentUserSignController
{
}
yd-csf-api/src/main/java/com/yd/csf/api/controller/AppointmentUserSignLogController.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
api
.
controller
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.RestController
;
/**
* <p>
* 预约-签单员信息日志表(快照表) 前端控制器
* </p>
*
* @author zxm
* @since 2025-12-15
*/
@RestController
@RequestMapping
(
"/appointmentUserSignLog"
)
public
class
AppointmentUserSignLogController
{
}
yd-csf-api/src/main/java/com/yd/csf/api/controller/TaxationController.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
api
.
controller
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.RestController
;
/**
* <p>
* 税务信息表 前端控制器
* </p>
*
* @author zxm
* @since 2025-12-17
*/
@RestController
@RequestMapping
(
"/taxation"
)
public
class
TaxationController
{
}
yd-csf-api/src/main/java/com/yd/csf/api/service/ApiAppointmentLogService.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
api
.
service
;
import
com.yd.common.result.Result
;
import
com.yd.csf.service.model.Appointment
;
public
interface
ApiAppointmentLogService
{
Result
<
String
>
saveAppointmentLog
(
Appointment
appointment
);
}
yd-csf-api/src/main/java/com/yd/csf/api/service/ApiAppointmentReferrerLogService.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
api
.
service
;
import
com.yd.common.result.Result
;
import
com.yd.csf.feign.dto.appointment.ApiAppointmentReferrerDto
;
import
java.util.List
;
public
interface
ApiAppointmentReferrerLogService
{
Result
saveAppointmentReferrerLogList
(
List
<
ApiAppointmentReferrerDto
>
referrerDtoList
,
String
appointmentLogBizId
);
}
yd-csf-api/src/main/java/com/yd/csf/api/service/ApiAppointmentReferrerService.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
api
.
service
;
import
com.yd.common.result.Result
;
import
com.yd.csf.feign.dto.appointment.ApiAppointmentReferrerDto
;
import
java.util.List
;
public
interface
ApiAppointmentReferrerService
{
Result
saveAppointmentReferrerList
(
List
<
ApiAppointmentReferrerDto
>
referrerDtoList
,
String
appointmentBizId
);
}
yd-csf-api/src/main/java/com/yd/csf/api/service/ApiAppointmentService.java
View file @
7b943b2c
...
...
@@ -4,9 +4,7 @@ import com.baomidou.mybatisplus.core.metadata.IPage;
import
com.yd.common.result.Result
;
import
com.yd.csf.feign.dto.appointment.ApiAppointmentInfoDto
;
import
com.yd.csf.feign.request.appointment.*
;
import
com.yd.csf.feign.response.appointment.ApiAppointmentAddResponse
;
import
com.yd.csf.feign.response.appointment.ApiAppointmentDetailResponse
;
import
com.yd.csf.feign.response.appointment.ApiAppointmentPageResponse
;
import
com.yd.csf.feign.response.appointment.*
;
import
com.yd.csf.service.model.Appointment
;
public
interface
ApiAppointmentService
{
...
...
@@ -22,6 +20,8 @@ public interface ApiAppointmentService {
Result
edit
(
ApiAppointmentEditRequest
request
);
Result
editStorage
(
ApiAppointmentEditStorageRequest
request
);
Result
editConfirmTime
(
ApiAppointmentEditConfirmTimeRequest
request
);
Result
singleEdit
(
ApiAppointmentInfoDto
apiAppointmentInfoDto
);
...
...
@@ -36,7 +36,13 @@ public interface ApiAppointmentService {
Result
editPolicyTransfer
(
ApiPolicyTransferRequest
request
);
Result
editStatus
(
ApiAppointmentEditStatusRequest
request
);
Result
del
(
String
appointmentBizId
);
Result
<
IPage
<
ApiAppointmentLogPageResponse
>>
logPage
(
ApiAppointmentLogPageRequest
request
);
Result
<
ApiAppointmentLogDetailResponse
>
logDetail
(
String
appointmentLogBizId
);
Result
<
Appointment
>
checkAppointmentIsExist
(
String
appointmentBizId
);
}
yd-csf-api/src/main/java/com/yd/csf/api/service/ApiAppointmentUserSignLogService.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
api
.
service
;
import
com.yd.common.result.Result
;
import
com.yd.csf.feign.dto.appointment.ApiAppointmentUserSignDto
;
import
java.util.List
;
public
interface
ApiAppointmentUserSignLogService
{
Result
saveAppointmentUserSignLogList
(
List
<
ApiAppointmentUserSignDto
>
userSignDtoList
,
String
appointmentLogBizId
);
}
yd-csf-api/src/main/java/com/yd/csf/api/service/ApiAppointmentUserSignService.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
api
.
service
;
import
com.yd.common.result.Result
;
import
com.yd.csf.feign.dto.appointment.ApiAppointmentUserSignDto
;
import
java.util.List
;
public
interface
ApiAppointmentUserSignService
{
Result
saveAppointmentUserSignList
(
List
<
ApiAppointmentUserSignDto
>
userSignDtoList
,
String
appointmentBizId
);
}
yd-csf-api/src/main/java/com/yd/csf/api/service/ApiCsfCommonService.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
api
.
service
;
import
com.yd.common.result.Result
;
import
com.yd.csf.feign.request.common.ApiCsfCalculateRequest
;
import
com.yd.csf.feign.response.common.ApiCsfCalculateResponse
;
import
java.util.List
;
public
interface
ApiCsfCommonService
{
Result
<
List
<
ApiCsfCalculateResponse
>>
calculate
(
ApiCsfCalculateRequest
request
);
}
yd-csf-api/src/main/java/com/yd/csf/api/service/impl/ApiAppointmentCheckServiceImpl.java
View file @
7b943b2c
...
...
@@ -9,7 +9,7 @@ import com.yd.csf.feign.dto.appointment.*;
import
com.yd.csf.feign.request.appointment.ApiAppointmentAddRequest
;
import
com.yd.csf.feign.request.appointment.ApiAppointmentEditRequest
;
import
com.yd.csf.service.enums.CustomerTypeEnum
;
import
com.yd.csf.
service
.enums.RelTypeEnum
;
import
com.yd.csf.
feign
.enums.RelTypeEnum
;
import
lombok.extern.slf4j.Slf4j
;
import
org.apache.commons.lang3.StringUtils
;
import
org.springframework.beans.BeanUtils
;
...
...
@@ -92,15 +92,15 @@ public class ApiAppointmentCheckServiceImpl implements ApiAppointmentCheckServic
dto
=
new
ApiAppointmentInfoDto
();
}
String
tipStr
=
"预约信息-"
;
if
(!
Objects
.
isNull
(
dto
.
getId
()))
{
throw
new
BusinessException
(
tipStr
+
"预约信息表主键id不传值"
);
}
//
if (!Objects.isNull(dto.getId())) {
//
throw new BusinessException(tipStr+"预约信息表主键id不传值");
//
}
if
(
StringUtils
.
isNotBlank
(
dto
.
getAppointmentBizId
()))
{
throw
new
BusinessException
(
tipStr
+
"预约信息主表唯一业务ID不传值"
);
}
if
(
StringUtils
.
isNotBlank
(
dto
.
getAppointmentNo
()))
{
throw
new
BusinessException
(
tipStr
+
"预约编号不传值"
);
}
//
if (StringUtils.isNotBlank(dto.getAppointmentNo())) {
//
throw new BusinessException(tipStr+"预约编号不传值");
//
}
//校验预约信息参数公共方法
checkApiAppointmentInfoDtoCommon
(
dto
,
tipStr
);
...
...
@@ -114,15 +114,15 @@ public class ApiAppointmentCheckServiceImpl implements ApiAppointmentCheckServic
*/
public
Result
checkEditApiAppointmentInfoDto
(
ApiAppointmentInfoDto
dto
)
{
String
tipStr
=
"预约信息-"
;
if
(
Objects
.
isNull
(
dto
.
getId
()))
{
throw
new
BusinessException
(
tipStr
+
"预约信息表主键id不能为空"
);
}
//
if (Objects.isNull(dto.getId())) {
//
throw new BusinessException(tipStr+"预约信息表主键id不能为空");
//
}
if
(
StringUtils
.
isBlank
(
dto
.
getAppointmentBizId
()))
{
throw
new
BusinessException
(
tipStr
+
"预约信息主表唯一业务ID不能为空"
);
}
if
(
StringUtils
.
isBlank
(
dto
.
getAppointmentNo
()))
{
throw
new
BusinessException
(
tipStr
+
"预约编号不能为空"
);
}
//
if (StringUtils.isBlank(dto.getAppointmentNo())) {
//
throw new BusinessException(tipStr+"预约编号不能为空");
//
}
//校验预约信息参数公共方法
checkApiAppointmentInfoDtoCommon
(
dto
,
tipStr
);
...
...
@@ -138,9 +138,9 @@ public class ApiAppointmentCheckServiceImpl implements ApiAppointmentCheckServic
if
(
StringUtils
.
isBlank
(
dto
.
getApplyType
()))
{
throw
new
BusinessException
(
tipStr
+
"申请类型不能为空"
);
}
if
(
Objects
.
isNull
(
dto
.
getIntentionAppointmentTime
()))
{
throw
new
BusinessException
(
tipStr
+
"意向预约时间不能为空"
);
}
//
if (Objects.isNull(dto.getIntentionAppointmentTime())) {
//
throw new BusinessException(tipStr+"意向预约时间不能为空");
//
}
//校验预约信息-客户和fna入参
checkCustomerAndFna
(
dto
,
tipStr
);
...
...
@@ -221,12 +221,12 @@ public class ApiAppointmentCheckServiceImpl implements ApiAppointmentCheckServic
dto
=
new
ApiProductPlanMainInfoDto
();
}
String
tipStr
=
"产品计划-"
;
if
(!
Objects
.
isNull
(
dto
.
getId
()))
{
throw
new
BusinessException
(
tipStr
+
"产品计划表主键id不传值"
);
}
if
(
StringUtils
.
isNotBlank
(
dto
.
getAppointmentBizId
()))
{
throw
new
BusinessException
(
tipStr
+
"预约信息主表唯一业务ID不传值"
);
}
//
if (!Objects.isNull(dto.getId())) {
//
throw new BusinessException(tipStr+"产品计划表主键id不传值");
//
}
//
if (StringUtils.isNotBlank(dto.getAppointmentBizId())) {
//
throw new BusinessException(tipStr+"预约信息主表唯一业务ID不传值");
//
}
if
(
StringUtils
.
isNotBlank
(
dto
.
getPlanBizId
()))
{
throw
new
BusinessException
(
tipStr
+
"产品计划信息表唯一业务ID不传值"
);
}
...
...
@@ -243,12 +243,12 @@ public class ApiAppointmentCheckServiceImpl implements ApiAppointmentCheckServic
*/
public
Result
checkEditApiProductPlanMainInfoDto
(
ApiProductPlanMainInfoDto
dto
){
String
tipStr
=
"产品计划-"
;
if
(
Objects
.
isNull
(
dto
.
getId
()))
{
throw
new
BusinessException
(
tipStr
+
"产品计划表主键id不能为空"
);
}
if
(
StringUtils
.
isBlank
(
dto
.
getAppointmentBizId
()))
{
throw
new
BusinessException
(
tipStr
+
"预约信息主表唯一业务ID不能为空"
);
}
//
if (Objects.isNull(dto.getId())) {
//
throw new BusinessException(tipStr+"产品计划表主键id不能为空");
//
}
//
if (StringUtils.isBlank(dto.getAppointmentBizId())) {
//
throw new BusinessException(tipStr+"预约信息主表唯一业务ID不能为空");
//
}
if
(
StringUtils
.
isBlank
(
dto
.
getPlanBizId
()))
{
throw
new
BusinessException
(
tipStr
+
"产品计划信息表唯一业务ID不能为空"
);
}
...
...
@@ -264,18 +264,18 @@ public class ApiAppointmentCheckServiceImpl implements ApiAppointmentCheckServic
* @return
*/
public
Result
checkApiProductPlanMainInfoDtoCommon
(
ApiProductPlanMainInfoDto
dto
,
String
tipStr
,
Integer
source
)
{
if
(
StringUtils
.
isBlank
(
dto
.
getProductBizId
()))
{
throw
new
BusinessException
(
tipStr
+
"保险产品名称不能为空"
);
}
if
(
StringUtils
.
isBlank
(
dto
.
getProductName
()))
{
throw
new
BusinessException
(
tipStr
+
"保险产品名称不能为空"
);
}
if
(
StringUtils
.
isBlank
(
dto
.
getCurrency
()))
{
throw
new
BusinessException
(
tipStr
+
"货币不能为空"
);
}
if
(
StringUtils
.
isBlank
(
dto
.
getPaymentTerm
()))
{
throw
new
BusinessException
(
tipStr
+
"供款年期不能为空"
);
}
//
if (StringUtils.isBlank(dto.getProductBizId())) {
//
throw new BusinessException(tipStr+"保险产品名称不能为空");
//
}
//
if (StringUtils.isBlank(dto.getProductName())) {
//
throw new BusinessException(tipStr+"保险产品名称不能为空");
//
}
//
if (StringUtils.isBlank(dto.getCurrency())) {
//
throw new BusinessException(tipStr+"货币不能为空");
//
}
//
if (StringUtils.isBlank(dto.getPaymentTerm())) {
//
throw new BusinessException(tipStr+"供款年期不能为空");
//
}
if
(
StringUtils
.
isBlank
(
dto
.
getPaymentFrequency
()))
{
throw
new
BusinessException
(
tipStr
+
"付款频率不能为空"
);
}
...
...
@@ -378,15 +378,15 @@ public class ApiAppointmentCheckServiceImpl implements ApiAppointmentCheckServic
dto
=
new
ApiPolicyholderInfoDto
();
}
String
tipStr
=
"投保人-"
;
if
(
StringUtils
.
isBlank
(
dto
.
getCustomerType
()))
{
throw
new
BusinessException
(
tipStr
+
"客户类型不能为空"
);
}
if
(!
Objects
.
isNull
(
dto
.
getId
()))
{
throw
new
BusinessException
(
tipStr
+
"投保人信息主键id不传值"
);
}
if
(
StringUtils
.
isNotBlank
(
dto
.
getAppointmentBizId
()))
{
throw
new
BusinessException
(
tipStr
+
"预约信息主表唯一业务ID不传值"
);
}
//
if (StringUtils.isBlank(dto.getCustomerType())) {
//
throw new BusinessException(tipStr+"客户类型不能为空");
//
}
//
if (!Objects.isNull(dto.getId())) {
//
throw new BusinessException(tipStr+"投保人信息主键id不传值");
//
}
//
if (StringUtils.isNotBlank(dto.getAppointmentBizId())) {
//
throw new BusinessException(tipStr+"预约信息主表唯一业务ID不传值");
//
}
if
(
StringUtils
.
isNotBlank
(
dto
.
getPolicyholderBizId
()))
{
throw
new
BusinessException
(
tipStr
+
"投保人信息表唯一业务ID不传值"
);
}
...
...
@@ -406,15 +406,15 @@ public class ApiAppointmentCheckServiceImpl implements ApiAppointmentCheckServic
*/
public
Result
checkEditApiPolicyholderInfoDto
(
ApiPolicyholderInfoDto
dto
)
{
String
tipStr
=
"投保人-"
;
if
(
StringUtils
.
isBlank
(
dto
.
getCustomerType
()))
{
throw
new
BusinessException
(
tipStr
+
"客户类型不能为空"
);
}
if
(
Objects
.
isNull
(
dto
.
getId
()))
{
throw
new
BusinessException
(
tipStr
+
"投保人信息主键id不能为空"
);
}
if
(
StringUtils
.
isBlank
(
dto
.
getAppointmentBizId
()))
{
throw
new
BusinessException
(
tipStr
+
"预约信息主表唯一业务ID不能为空"
);
}
//
if (StringUtils.isBlank(dto.getCustomerType())) {
//
throw new BusinessException(tipStr+"客户类型不能为空");
//
}
//
if (Objects.isNull(dto.getId())) {
//
throw new BusinessException(tipStr+"投保人信息主键id不能为空");
//
}
//
if (StringUtils.isBlank(dto.getAppointmentBizId())) {
//
throw new BusinessException(tipStr+"预约信息主表唯一业务ID不能为空");
//
}
if
(
StringUtils
.
isBlank
(
dto
.
getPolicyholderBizId
()))
{
throw
new
BusinessException
(
tipStr
+
"投保人信息表唯一业务ID不能为空"
);
}
...
...
@@ -433,30 +433,30 @@ public class ApiAppointmentCheckServiceImpl implements ApiAppointmentCheckServic
* @return
*/
public
Result
checkApiPolicyholderInfoDtoCommon
(
ApiPolicyholderInfoDto
dto
,
String
tipStr
)
{
if
(
CustomerTypeEnum
.
INDIVIDUAL
.
getItemValue
().
equals
(
dto
.
getCustomerType
()))
{
//客户类型为个人的字段校验
if
(
StringUtils
.
isBlank
(
dto
.
getMobile
()))
{
throw
new
BusinessException
(
tipStr
+
"移动电话不能为空"
);
}
if
(
StringUtils
.
isBlank
(
dto
.
getMobileCode
()))
{
throw
new
BusinessException
(
tipStr
+
"移动电话区号不能为空"
);
}
if
(
StringUtils
.
isBlank
(
dto
.
getNationality
()))
{
throw
new
BusinessException
(
tipStr
+
"国籍不能为空"
);
}
//校验客户类型为个人类型的公共参数字段
CustomerTypeIndividualCheckCommonDto
individualCheckCommonDto
=
new
CustomerTypeIndividualCheckCommonDto
();
BeanUtils
.
copyProperties
(
dto
,
individualCheckCommonDto
);
checkCustomerTypeIndividualCheckCommonDto
(
individualCheckCommonDto
,
tipStr
);
}
else
if
(
CustomerTypeEnum
.
COMPANY
.
getItemValue
().
equals
(
dto
.
getCustomerType
())){
//客户类型为公司的字段校验
CustomerTypeCompanyCheckCommonDto
companyCheckCommonDto
=
new
CustomerTypeCompanyCheckCommonDto
();
BeanUtils
.
copyProperties
(
dto
,
companyCheckCommonDto
);
//校验客户类型为公司类型的公共参数字段
checkCustomerTypeCompanyCheckCommonDto
(
companyCheckCommonDto
,
tipStr
);
}
//
if (CustomerTypeEnum.INDIVIDUAL.getItemValue().equals(dto.getCustomerType())) {
//
//客户类型为个人的字段校验
//
if (StringUtils.isBlank(dto.getMobile())) {
//
throw new BusinessException(tipStr+"移动电话不能为空");
//
}
//
if (StringUtils.isBlank(dto.getMobileCode())) {
//
throw new BusinessException(tipStr+"移动电话区号不能为空");
//
}
//
if (StringUtils.isBlank(dto.getNationality())) {
//
throw new BusinessException(tipStr+"国籍不能为空");
//
}
//
//
//校验客户类型为个人类型的公共参数字段
//
CustomerTypeIndividualCheckCommonDto individualCheckCommonDto = new CustomerTypeIndividualCheckCommonDto();
//
BeanUtils.copyProperties(dto,individualCheckCommonDto);
//
checkCustomerTypeIndividualCheckCommonDto(individualCheckCommonDto,tipStr);
//
//
}else if (CustomerTypeEnum.COMPANY.getItemValue().equals(dto.getCustomerType())){
//
//客户类型为公司的字段校验
//
CustomerTypeCompanyCheckCommonDto companyCheckCommonDto = new CustomerTypeCompanyCheckCommonDto();
//
BeanUtils.copyProperties(dto,companyCheckCommonDto);
//
//校验客户类型为公司类型的公共参数字段
//
checkCustomerTypeCompanyCheckCommonDto(companyCheckCommonDto,tipStr);
//
}
return
Result
.
success
();
}
...
...
@@ -470,9 +470,9 @@ public class ApiAppointmentCheckServiceImpl implements ApiAppointmentCheckServic
dto
=
new
ApiInsurantInfoDto
();
}
String
tipStr
=
"受保人-"
;
if
(
StringUtils
.
isBlank
(
dto
.
getCustomerType
()))
{
throw
new
BusinessException
(
tipStr
+
"客户类型不能为空"
);
}
//
if (StringUtils.isBlank(dto.getCustomerType())) {
//
throw new BusinessException(tipStr+"客户类型不能为空");
//
}
if
(
StringUtils
.
isBlank
(
dto
.
getPolicyholderRel
()))
{
throw
new
BusinessException
(
tipStr
+
"与投保人关系不能为空"
);
}
...
...
@@ -480,12 +480,12 @@ public class ApiAppointmentCheckServiceImpl implements ApiAppointmentCheckServic
//如果对象空或者与投保人关系为本人,就放行不校验
return
Result
.
success
();
}
if
(!
Objects
.
isNull
(
dto
.
getId
()))
{
throw
new
BusinessException
(
tipStr
+
"受保人信息表主键id不传值"
);
}
if
(
StringUtils
.
isNotBlank
(
dto
.
getAppointmentBizId
()))
{
throw
new
BusinessException
(
tipStr
+
"预约信息主表唯一业务ID不传值"
);
}
//
if (!Objects.isNull(dto.getId())) {
//
throw new BusinessException(tipStr+"受保人信息表主键id不传值");
//
}
//
if (StringUtils.isNotBlank(dto.getAppointmentBizId())) {
//
throw new BusinessException(tipStr+"预约信息主表唯一业务ID不传值");
//
}
if
(
StringUtils
.
isNotBlank
(
dto
.
getInsurantBizId
()))
{
throw
new
BusinessException
(
tipStr
+
"受保人信息表唯一业务ID不传值"
);
}
...
...
@@ -508,9 +508,9 @@ public class ApiAppointmentCheckServiceImpl implements ApiAppointmentCheckServic
*/
public
Result
checkEditApiInsurantInfoDto
(
ApiInsurantInfoDto
dto
)
{
String
tipStr
=
"受保人-"
;
if
(
StringUtils
.
isBlank
(
dto
.
getCustomerType
()))
{
throw
new
BusinessException
(
tipStr
+
"客户类型不能为空"
);
}
//
if (StringUtils.isBlank(dto.getCustomerType())) {
//
throw new BusinessException(tipStr+"客户类型不能为空");
//
}
if
(
StringUtils
.
isBlank
(
dto
.
getPolicyholderRel
()))
{
throw
new
BusinessException
(
tipStr
+
"与投保人关系不能为空"
);
}
...
...
@@ -518,12 +518,12 @@ public class ApiAppointmentCheckServiceImpl implements ApiAppointmentCheckServic
//如果对象空或者与投保人关系为本人,就放行不校验
return
Result
.
success
();
}
if
(
Objects
.
isNull
(
dto
.
getId
()))
{
throw
new
BusinessException
(
tipStr
+
"受保人信息表主键id不能为空"
);
}
if
(
StringUtils
.
isBlank
(
dto
.
getAppointmentBizId
()))
{
throw
new
BusinessException
(
tipStr
+
"预约信息主表唯一业务ID不能为空"
);
}
//
if (Objects.isNull(dto.getId())) {
//
throw new BusinessException(tipStr+"受保人信息表主键id不能为空");
//
}
//
if (StringUtils.isBlank(dto.getAppointmentBizId())) {
//
throw new BusinessException(tipStr+"预约信息主表唯一业务ID不能为空");
//
}
if
(
StringUtils
.
isBlank
(
dto
.
getInsurantBizId
()))
{
throw
new
BusinessException
(
tipStr
+
"受保人信息表唯一业务ID不能为空"
);
}
...
...
@@ -546,81 +546,81 @@ public class ApiAppointmentCheckServiceImpl implements ApiAppointmentCheckServic
*/
@Override
public
Result
checkEditApiBeneficiaryInfoDtoList
(
List
<
ApiBeneficiaryInfoDto
>
list
){
if
(
CollectionUtils
.
isEmpty
(
list
))
{
//如果对象集合空就放行不校验
return
Result
.
success
();
}
String
tipStr
=
"受益人-"
;
//列表下标标记位
int
i
=
1
;
for
(
ApiBeneficiaryInfoDto
dto
:
list
)
{
if
(
StringUtils
.
isBlank
(
dto
.
getCustomerType
()))
{
throw
new
BusinessException
(
tipStr
+
"客户类型不能为空"
);
}
if
(
StringUtils
.
isBlank
(
dto
.
getInsurantRel
()))
{
throw
new
BusinessException
(
tipStr
+
"与受保人关系不能为空"
);
}
// if (Objects.isNull(dto.getId())) {
// throw new BusinessException(tipStr+"第"+i+"项的受益人信息主键id不能为空");
// }
// if (StringUtils.isBlank(dto.getAppointmentBizId())) {
// throw new BusinessException(tipStr+"第"+i+"项的预约信息主表唯一业务ID不能为空");
// if (CollectionUtils.isEmpty(list)) {
// //如果对象集合空就放行不校验
// return Result.success();
// }
// String tipStr = "受益人-";
// //列表下标标记位
// int i = 1;
// for (ApiBeneficiaryInfoDto dto : list) {
//// if (StringUtils.isBlank(dto.getCustomerType())) {
//// throw new BusinessException(tipStr+"客户类型不能为空");
//// }
// if (StringUtils.isBlank(dto.getInsurantRel())) {
// throw new BusinessException(tipStr+"与受保人关系不能为空");
// }
// if (StringUtils.isBlank(dto.getBeneficiaryBizId())) {
// throw new BusinessException(tipStr+"第"+i+"项的受益人信息表唯一业务ID不能为空");
//// if (Objects.isNull(dto.getId())) {
//// throw new BusinessException(tipStr+"第"+i+"项的受益人信息主键id不能为空");
//// }
//// if (StringUtils.isBlank(dto.getAppointmentBizId())) {
//// throw new BusinessException(tipStr+"第"+i+"项的预约信息主表唯一业务ID不能为空");
//// }
//// if (StringUtils.isBlank(dto.getBeneficiaryBizId())) {
//// throw new BusinessException(tipStr+"第"+i+"项的受益人信息表唯一业务ID不能为空");
//// }
//
// if (RelTypeEnum.MYSELF.getItemValue().equals(dto.getInsurantRel())) {
// //如果对象与受保人关系为本人,就不校验下面的参数,继续循环下一个
// continue;
// }
if
(
RelTypeEnum
.
MYSELF
.
getItemValue
().
equals
(
dto
.
getInsurantRel
()))
{
//如果对象与受保人关系为本人,就不校验下面的参数,继续循环下一个
continue
;
}
if
(
CustomerTypeEnum
.
INDIVIDUAL
.
getItemValue
().
equals
(
dto
.
getCustomerType
()))
{
//客户类型为个人的字段校验
//校验客户类型为个人类型的公共参数字段
// if (StringUtils.isBlank(dto.getName())) {
// throw new BusinessException(tipStr+"第"+i+"项的名字不能为空");
//
// if (CustomerTypeEnum.INDIVIDUAL.getItemValue().equals(dto.getCustomerType())) {
// //客户类型为个人的字段校验
// //校验客户类型为个人类型的公共参数字段
//// if (StringUtils.isBlank(dto.getName())) {
//// throw new BusinessException(tipStr+"第"+i+"项的名字不能为空");
//// }
// if (StringUtils.isBlank(dto.getNameEn())) {
// throw new BusinessException(tipStr+"第"+i+"项的名字-英文不能为空");
// }
if
(
StringUtils
.
isBlank
(
dto
.
getNameEn
()))
{
throw
new
BusinessException
(
tipStr
+
"第"
+
i
+
"项的名字-英文不能为空"
);
}
if
(
StringUtils
.
isBlank
(
dto
.
getGender
()))
{
throw
new
BusinessException
(
tipStr
+
"第"
+
i
+
"项的性别不能为空"
);
}
// CustomerTypeIndividualCheckCommonDto individualCheckCommonDto = new CustomerTypeIndividualCheckCommonDto();
// BeanUtils.copyProperties(dto,individualCheckCommonDto);
// checkCustomerTypeIndividualCheckCommonDto(individualCheckCommonDto,tipStr);
}
else
if
(
CustomerTypeEnum
.
COMPANY
.
getItemValue
().
equals
(
dto
.
getCustomerType
())){
//客户类型为公司的字段校验
if
(
StringUtils
.
isBlank
(
dto
.
getCompanyName
()))
{
throw
new
BusinessException
(
tipStr
+
"第"
+
i
+
"项的公司名称不能为空"
);
}
if
(
StringUtils
.
isBlank
(
dto
.
getCompanyNameEn
()))
{
throw
new
BusinessException
(
tipStr
+
"第"
+
i
+
"项的公司名称(英文)不能为空"
);
}
if
(
StringUtils
.
isBlank
(
dto
.
getCompanyBusinessNo
()))
{
throw
new
BusinessException
(
tipStr
+
"第"
+
i
+
"项的公司商业登记号码不能为空"
);
}
if
(
Objects
.
isNull
(
dto
.
getCompanyRegisterTime
()))
{
throw
new
BusinessException
(
tipStr
+
"第"
+
i
+
"项的公司注册日期不能为空"
);
}
if
(
Objects
.
isNull
(
dto
.
getCompanyMobile
()))
{
throw
new
BusinessException
(
tipStr
+
"第"
+
i
+
"项的公司电话不能为空"
);
}
if
(
Objects
.
isNull
(
dto
.
getCompanyMobileCode
()))
{
throw
new
BusinessException
(
tipStr
+
"第"
+
i
+
"项的公司电话区号不能为空"
);
}
if
(
Objects
.
isNull
(
dto
.
getCompanyRegisterRegion
()))
{
throw
new
BusinessException
(
tipStr
+
"第"
+
i
+
"项的公司注册地区不能为空"
);
}
// CustomerTypeCompanyCheckCommonDto companyCheckCommonDto = new CustomerTypeCompanyCheckCommonDto();
// BeanUtils.copyProperties(dto,companyCheckCommonDto);
// //校验客户类型为公司类型的公共参数字段
// checkCustomerTypeCompanyCheckCommonDto(companyCheckCommonDto,tipStr);
}
i
++;
}
// if (StringUtils.isBlank(dto.getGender())) {
// throw new BusinessException(tipStr+"第"+i+"项的性别不能为空");
// }
//// CustomerTypeIndividualCheckCommonDto individualCheckCommonDto = new CustomerTypeIndividualCheckCommonDto();
//// BeanUtils.copyProperties(dto,individualCheckCommonDto);
//// checkCustomerTypeIndividualCheckCommonDto(individualCheckCommonDto,tipStr);
//
// }else if (CustomerTypeEnum.COMPANY.getItemValue().equals(dto.getCustomerType())){
// //客户类型为公司的字段校验
// if (StringUtils.isBlank(dto.getCompanyName())) {
// throw new BusinessException(tipStr+"第"+i+"项的公司名称不能为空");
// }
// if (StringUtils.isBlank(dto.getCompanyNameEn())) {
// throw new BusinessException(tipStr+"第"+i+"项的公司名称(英文)不能为空");
// }
// if (StringUtils.isBlank(dto.getCompanyBusinessNo())) {
// throw new BusinessException(tipStr+"第"+i+"项的公司商业登记号码不能为空");
// }
// if (Objects.isNull(dto.getCompanyRegisterTime())) {
// throw new BusinessException(tipStr+"第"+i+"项的公司注册日期不能为空");
// }
// if (Objects.isNull(dto.getCompanyMobile())) {
// throw new BusinessException(tipStr+"第"+i+"项的公司电话不能为空");
// }
// if (Objects.isNull(dto.getCompanyMobileCode())) {
// throw new BusinessException(tipStr+"第"+i+"项的公司电话区号不能为空");
// }
// if (Objects.isNull(dto.getCompanyRegisterRegion())) {
// throw new BusinessException(tipStr+"第"+i+"项的公司注册地区不能为空");
// }
//// CustomerTypeCompanyCheckCommonDto companyCheckCommonDto = new CustomerTypeCompanyCheckCommonDto();
//// BeanUtils.copyProperties(dto,companyCheckCommonDto);
//// //校验客户类型为公司类型的公共参数字段
//// checkCustomerTypeCompanyCheckCommonDto(companyCheckCommonDto,tipStr);
// }
// i++;
// }
return
Result
.
success
();
}
...
...
@@ -631,51 +631,51 @@ public class ApiAppointmentCheckServiceImpl implements ApiAppointmentCheckServic
* @return
*/
public
Result
checkAddApiBeneficiaryInfoDtoList
(
List
<
ApiBeneficiaryInfoDto
>
list
){
if
(
CollectionUtils
.
isEmpty
(
list
))
{
//如果对象集合空就放行不校验
return
Result
.
success
();
}
String
tipStr
=
"受益人-"
;
//列表下标标记位
int
i
=
1
;
for
(
ApiBeneficiaryInfoDto
dto
:
list
)
{
if
(
StringUtils
.
isBlank
(
dto
.
getCustomerType
()))
{
throw
new
BusinessException
(
tipStr
+
"第"
+
i
+
"项的客户类型不能为空"
);
}
if
(
StringUtils
.
isBlank
(
dto
.
getInsurantRel
()))
{
throw
new
BusinessException
(
tipStr
+
"第"
+
i
+
"项的与受保人关系不能为空"
);
}
if
(!
Objects
.
isNull
(
dto
.
getId
()))
{
throw
new
BusinessException
(
tipStr
+
"第"
+
i
+
"项的受益人信息主键id不传值"
);
}
// if (StringUtils.isBlank(dto.getAppointmentBizId())) {
// throw new BusinessException(tipStr+"第"+i+"项的预约信息主表唯一业务ID不能为空");
// if (CollectionUtils.isEmpty(list)) {
// //如果对象集合空就放行不校验
// return Result.success();
// }
// String tipStr = "受益人-";
// //列表下标标记位
// int i = 1;
// for (ApiBeneficiaryInfoDto dto : list) {
// if (StringUtils.isBlank(dto.getCustomerType())) {
// throw new BusinessException(tipStr+"第"+i+"项的客户类型不能为空");
// }
if
(
StringUtils
.
isNotBlank
(
dto
.
getBeneficiaryBizId
()))
{
throw
new
BusinessException
(
tipStr
+
"第"
+
i
+
"项的受益人信息表唯一业务ID不传值"
);
}
if
(
RelTypeEnum
.
MYSELF
.
getItemValue
().
equals
(
dto
.
getInsurantRel
()))
{
//如果对象与受保人关系为本人,就不校验下面的参数,继续循环下一个
continue
;
}
if
(
CustomerTypeEnum
.
INDIVIDUAL
.
getItemValue
().
equals
(
dto
.
getCustomerType
()))
{
//客户类型为个人的字段校验
//校验客户类型为个人类型的公共参数字段
CustomerTypeIndividualCheckCommonDto
individualCheckCommonDto
=
new
CustomerTypeIndividualCheckCommonDto
();
BeanUtils
.
copyProperties
(
dto
,
individualCheckCommonDto
);
checkCustomerTypeIndividualCheckCommonDto
(
individualCheckCommonDto
,
tipStr
);
}
else
if
(
CustomerTypeEnum
.
COMPANY
.
getItemValue
().
equals
(
dto
.
getCustomerType
())){
//客户类型为公司的字段校验
CustomerTypeCompanyCheckCommonDto
companyCheckCommonDto
=
new
CustomerTypeCompanyCheckCommonDto
();
BeanUtils
.
copyProperties
(
dto
,
companyCheckCommonDto
);
//校验客户类型为公司类型的公共参数字段
checkCustomerTypeCompanyCheckCommonDto
(
companyCheckCommonDto
,
tipStr
);
}
i
++;
}
// if (StringUtils.isBlank(dto.getInsurantRel())) {
// throw new BusinessException(tipStr+"第"+i+"项的与受保人关系不能为空");
// }
// if (!Objects.isNull(dto.getId())) {
// throw new BusinessException(tipStr+"第"+i+"项的受益人信息主键id不传值");
// }
//// if (StringUtils.isBlank(dto.getAppointmentBizId())) {
//// throw new BusinessException(tipStr+"第"+i+"项的预约信息主表唯一业务ID不能为空");
//// }
// if (StringUtils.isNotBlank(dto.getBeneficiaryBizId())) {
// throw new BusinessException(tipStr+"第"+i+"项的受益人信息表唯一业务ID不传值");
// }
//
// if (RelTypeEnum.MYSELF.getItemValue().equals(dto.getInsurantRel())) {
// //如果对象与受保人关系为本人,就不校验下面的参数,继续循环下一个
// continue;
// }
//
// if (CustomerTypeEnum.INDIVIDUAL.getItemValue().equals(dto.getCustomerType())) {
// //客户类型为个人的字段校验
// //校验客户类型为个人类型的公共参数字段
// CustomerTypeIndividualCheckCommonDto individualCheckCommonDto = new CustomerTypeIndividualCheckCommonDto();
// BeanUtils.copyProperties(dto,individualCheckCommonDto);
// checkCustomerTypeIndividualCheckCommonDto(individualCheckCommonDto,tipStr);
//
// }else if (CustomerTypeEnum.COMPANY.getItemValue().equals(dto.getCustomerType())){
// //客户类型为公司的字段校验
// CustomerTypeCompanyCheckCommonDto companyCheckCommonDto = new CustomerTypeCompanyCheckCommonDto();
// BeanUtils.copyProperties(dto,companyCheckCommonDto);
// //校验客户类型为公司类型的公共参数字段
// checkCustomerTypeCompanyCheckCommonDto(companyCheckCommonDto,tipStr);
// }
// i++;
// }
return
Result
.
success
();
}
...
...
@@ -685,45 +685,48 @@ public class ApiAppointmentCheckServiceImpl implements ApiAppointmentCheckServic
* @return
*/
public
Result
checkEditApiBeneficiaryInfoDto
(
ApiBeneficiaryInfoDto
dto
){
if
(!
Objects
.
isNull
(
dto
))
{
throw
new
BusinessException
(
"入参对象不能为空"
);
}
String
tipStr
=
"受益人-"
;
if
(
StringUtils
.
isBlank
(
dto
.
getCustomerType
()))
{
throw
new
BusinessException
(
tipStr
+
"客户类型不能为空"
);
}
if
(
StringUtils
.
isBlank
(
dto
.
getInsurantRel
()))
{
throw
new
BusinessException
(
tipStr
+
"与受保人关系不能为空"
);
}
if
(
Objects
.
isNull
(
dto
.
getId
()))
{
throw
new
BusinessException
(
tipStr
+
"受益人信息主键id不能为空"
);
}
if
(
StringUtils
.
isBlank
(
dto
.
getAppointmentBizId
()))
{
throw
new
BusinessException
(
tipStr
+
"预约信息主表唯一业务ID不能为空"
);
}
if
(
StringUtils
.
isBlank
(
dto
.
getBeneficiaryBizId
()))
{
throw
new
BusinessException
(
tipStr
+
"受益人信息表唯一业务ID不能为空"
);
}
if
(
RelTypeEnum
.
MYSELF
.
getItemValue
().
equals
(
dto
.
getInsurantRel
()))
{
//如果对象与受保人关系为本人,就不校验下面的了
return
Result
.
success
();
}
if
(
CustomerTypeEnum
.
INDIVIDUAL
.
getItemValue
().
equals
(
dto
.
getCustomerType
()))
{
//客户类型为个人的字段校验
//校验客户类型为个人类型的公共参数字段
CustomerTypeIndividualCheckCommonDto
individualCheckCommonDto
=
new
CustomerTypeIndividualCheckCommonDto
();
BeanUtils
.
copyProperties
(
dto
,
individualCheckCommonDto
);
checkCustomerTypeIndividualCheckCommonDto
(
individualCheckCommonDto
,
tipStr
);
}
else
if
(
CustomerTypeEnum
.
COMPANY
.
getItemValue
().
equals
(
dto
.
getCustomerType
())){
//客户类型为公司的字段校验
CustomerTypeCompanyCheckCommonDto
companyCheckCommonDto
=
new
CustomerTypeCompanyCheckCommonDto
();
BeanUtils
.
copyProperties
(
dto
,
companyCheckCommonDto
);
//校验客户类型为公司类型的公共参数字段
checkCustomerTypeCompanyCheckCommonDto
(
companyCheckCommonDto
,
tipStr
);
throw
new
BusinessException
(
"受益人信息表唯一业务ID不能为空"
);
}
// if (!Objects.isNull(dto)) {
// throw new BusinessException("入参对象不能为空");
// }
// String tipStr = "受益人-";
// if (StringUtils.isBlank(dto.getCustomerType())) {
// throw new BusinessException(tipStr+"客户类型不能为空");
// }
// if (StringUtils.isBlank(dto.getInsurantRel())) {
// throw new BusinessException(tipStr+"与受保人关系不能为空");
// }
// if (Objects.isNull(dto.getId())) {
// throw new BusinessException(tipStr+"受益人信息主键id不能为空");
// }
// if (StringUtils.isBlank(dto.getAppointmentBizId())) {
// throw new BusinessException(tipStr+"预约信息主表唯一业务ID不能为空");
// }
// if (StringUtils.isBlank(dto.getBeneficiaryBizId())) {
// throw new BusinessException(tipStr+"受益人信息表唯一业务ID不能为空");
// }
//
// if (RelTypeEnum.MYSELF.getItemValue().equals(dto.getInsurantRel())) {
// //如果对象与受保人关系为本人,就不校验下面的了
// return Result.success();
// }
//
// if (CustomerTypeEnum.INDIVIDUAL.getItemValue().equals(dto.getCustomerType())) {
// //客户类型为个人的字段校验
// //校验客户类型为个人类型的公共参数字段
// CustomerTypeIndividualCheckCommonDto individualCheckCommonDto = new CustomerTypeIndividualCheckCommonDto();
// BeanUtils.copyProperties(dto,individualCheckCommonDto);
// checkCustomerTypeIndividualCheckCommonDto(individualCheckCommonDto,tipStr);
//
// }else if (CustomerTypeEnum.COMPANY.getItemValue().equals(dto.getCustomerType())){
// //客户类型为公司的字段校验
// CustomerTypeCompanyCheckCommonDto companyCheckCommonDto = new CustomerTypeCompanyCheckCommonDto();
// BeanUtils.copyProperties(dto,companyCheckCommonDto);
// //校验客户类型为公司类型的公共参数字段
// checkCustomerTypeCompanyCheckCommonDto(companyCheckCommonDto,tipStr);
// }
return
Result
.
success
();
}
...
...
@@ -737,12 +740,12 @@ public class ApiAppointmentCheckServiceImpl implements ApiAppointmentCheckServic
//如果对象空就放行不校验
return
Result
.
success
();
}
if
(!
Objects
.
isNull
(
dto
.
getId
()))
{
throw
new
BusinessException
(
"第二持有人信息表主键id不传值"
);
}
if
(
StringUtils
.
isNotBlank
(
dto
.
getAppointmentBizId
()))
{
throw
new
BusinessException
(
"预约信息主表唯一业务ID不传值"
);
}
//
if (!Objects.isNull(dto.getId())) {
//
throw new BusinessException("第二持有人信息表主键id不传值");
//
}
//
if (StringUtils.isNotBlank(dto.getAppointmentBizId())) {
//
throw new BusinessException("预约信息主表唯一业务ID不传值");
//
}
if
(
StringUtils
.
isNotBlank
(
dto
.
getSecondHolderBizId
()))
{
throw
new
BusinessException
(
"第二持有人信息表唯一业务ID不传值"
);
}
...
...
@@ -761,12 +764,12 @@ public class ApiAppointmentCheckServiceImpl implements ApiAppointmentCheckServic
return
Result
.
success
();
}
if
(
StringUtils
.
isNotBlank
(
dto
.
getSecondHolderBizId
()))
{
if
(
Objects
.
isNull
(
dto
.
getId
()))
{
throw
new
BusinessException
(
"第二持有人信息表主键id不能为空"
);
}
if
(
StringUtils
.
isBlank
(
dto
.
getAppointmentBizId
()))
{
throw
new
BusinessException
(
"预约信息主表唯一业务ID不能为空"
);
}
//
if (Objects.isNull(dto.getId())) {
//
throw new BusinessException("第二持有人信息表主键id不能为空");
//
}
//
if (StringUtils.isBlank(dto.getAppointmentBizId())) {
//
throw new BusinessException("预约信息主表唯一业务ID不能为空");
//
}
}
return
Result
.
success
();
}
...
...
yd-csf-api/src/main/java/com/yd/csf/api/service/impl/ApiAppointmentLogServiceImpl.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
api
.
service
.
impl
;
import
com.yd.common.enums.CommonEnum
;
import
com.yd.common.result.Result
;
import
com.yd.common.utils.RandomStringGenerator
;
import
com.yd.csf.api.service.ApiAppointmentLogService
;
import
com.yd.csf.service.model.Appointment
;
import
com.yd.csf.service.model.AppointmentLog
;
import
com.yd.csf.service.service.IAppointmentLogService
;
import
lombok.extern.slf4j.Slf4j
;
import
org.springframework.beans.BeanUtils
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
@Service
@Slf4j
public
class
ApiAppointmentLogServiceImpl
implements
ApiAppointmentLogService
{
@Autowired
private
IAppointmentLogService
iAppointmentLogService
;
/**
* 保存预约日志信息
* @param appointment
* @return
*/
@Override
public
Result
<
String
>
saveAppointmentLog
(
Appointment
appointment
)
{
AppointmentLog
appointmentLog
=
new
AppointmentLog
();
BeanUtils
.
copyProperties
(
appointment
,
appointmentLog
);
appointmentLog
.
setAppointmentBizId
(
appointment
.
getAppointmentBizId
());
appointmentLog
.
setAppointmentLogBizId
(
RandomStringGenerator
.
generateBizId16
(
CommonEnum
.
UID_TYPE_APPOINTMENT_LOG
.
getCode
()));
iAppointmentLogService
.
saveOrUpdate
(
appointmentLog
);
return
Result
.
success
(
appointmentLog
.
getAppointmentLogBizId
());
}
}
yd-csf-api/src/main/java/com/yd/csf/api/service/impl/ApiAppointmentReferrerLogServiceImpl.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
api
.
service
.
impl
;
import
com.yd.common.enums.CommonEnum
;
import
com.yd.common.result.Result
;
import
com.yd.common.utils.RandomStringGenerator
;
import
com.yd.csf.api.service.ApiAppointmentReferrerLogService
;
import
com.yd.csf.feign.dto.appointment.ApiAppointmentReferrerDto
;
import
com.yd.csf.service.model.AppointmentReferrerLog
;
import
com.yd.csf.service.service.IAppointmentReferrerLogService
;
import
lombok.extern.slf4j.Slf4j
;
import
org.springframework.beans.BeanUtils
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
org.springframework.util.CollectionUtils
;
import
java.util.List
;
import
java.util.stream.Collectors
;
@Slf4j
@Service
public
class
ApiAppointmentReferrerLogServiceImpl
implements
ApiAppointmentReferrerLogService
{
@Autowired
private
IAppointmentReferrerLogService
iAppointmentReferrerLogService
;
/**
* 保存预约-转介人信息日志信息
* @param referrerDtoList
* @param appointmentLogBizId
* @return
*/
@Override
public
Result
saveAppointmentReferrerLogList
(
List
<
ApiAppointmentReferrerDto
>
referrerDtoList
,
String
appointmentLogBizId
)
{
if
(
CollectionUtils
.
isEmpty
(
referrerDtoList
))
{
return
Result
.
success
();
}
List
<
AppointmentReferrerLog
>
saveList
=
referrerDtoList
.
stream
().
map
(
dto
->
{
AppointmentReferrerLog
log
=
new
AppointmentReferrerLog
();
BeanUtils
.
copyProperties
(
dto
,
log
);
log
.
setAppointmentLogBizId
(
appointmentLogBizId
);
log
.
setAppointmentReferrerLogBizId
(
RandomStringGenerator
.
generateBizId16
(
CommonEnum
.
UID_TYPE_APPOINTMENT_REFERRER_LOG
.
getCode
()));
return
log
;
}).
collect
(
Collectors
.
toList
());
iAppointmentReferrerLogService
.
saveOrUpdateBatch
(
saveList
);
return
Result
.
success
();
}
}
yd-csf-api/src/main/java/com/yd/csf/api/service/impl/ApiAppointmentReferrerServiceImpl.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
api
.
service
.
impl
;
import
com.yd.common.enums.CommonEnum
;
import
com.yd.common.result.Result
;
import
com.yd.common.utils.RandomStringGenerator
;
import
com.yd.csf.api.service.ApiAppointmentReferrerService
;
import
com.yd.csf.feign.dto.appointment.ApiAppointmentReferrerDto
;
import
com.yd.csf.service.model.AppointmentReferrer
;
import
com.yd.csf.service.service.IAppointmentReferrerService
;
import
lombok.extern.slf4j.Slf4j
;
import
org.springframework.beans.BeanUtils
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
org.springframework.util.CollectionUtils
;
import
java.util.List
;
import
java.util.stream.Collectors
;
@Slf4j
@Service
public
class
ApiAppointmentReferrerServiceImpl
implements
ApiAppointmentReferrerService
{
@Autowired
private
IAppointmentReferrerService
iAppointmentReferrerService
;
/**
* 保存预约-转介人信息列表
* @param referrerDtoList
* @param appointmentBizId
* @return
*/
@Override
public
Result
saveAppointmentReferrerList
(
List
<
ApiAppointmentReferrerDto
>
referrerDtoList
,
String
appointmentBizId
)
{
if
(
CollectionUtils
.
isEmpty
(
referrerDtoList
))
{
return
Result
.
success
();
}
//先删后新增
iAppointmentReferrerService
.
delByAppointmentBizId
(
appointmentBizId
);
//新增
List
<
AppointmentReferrer
>
saveList
=
referrerDtoList
.
stream
().
map
(
dto
->
{
AppointmentReferrer
referrer
=
new
AppointmentReferrer
();
BeanUtils
.
copyProperties
(
dto
,
referrer
);
referrer
.
setAppointmentBizId
(
appointmentBizId
);
referrer
.
setAppointmentReferrerBizId
(
RandomStringGenerator
.
generateBizId16
(
CommonEnum
.
UID_TYPE_APPOINTMENT_REFERRER
.
getCode
()));
return
referrer
;
}).
collect
(
Collectors
.
toList
());
iAppointmentReferrerService
.
saveOrUpdateBatch
(
saveList
);
return
Result
.
success
();
}
}
yd-csf-api/src/main/java/com/yd/csf/api/service/impl/ApiAppointmentServiceImpl.java
View file @
7b943b2c
...
...
@@ -15,9 +15,7 @@ import com.yd.csf.api.service.*;
import
com.yd.csf.feign.dto.appointment.*
;
import
com.yd.csf.feign.dto.appointmentfile.ApiAppointmentFileDto
;
import
com.yd.csf.feign.request.appointment.*
;
import
com.yd.csf.feign.response.appointment.ApiAppointmentAddResponse
;
import
com.yd.csf.feign.response.appointment.ApiAppointmentDetailResponse
;
import
com.yd.csf.feign.response.appointment.ApiAppointmentPageResponse
;
import
com.yd.csf.feign.response.appointment.*
;
import
com.yd.csf.service.dto.PolicySigner
;
import
com.yd.csf.service.enums.AppointmentStatusEnum
;
import
com.yd.csf.service.enums.PolicyFollowStatusEnum
;
...
...
@@ -25,12 +23,15 @@ import com.yd.csf.service.enums.PolicyStatusEnum;
import
com.yd.csf.service.model.*
;
import
com.yd.csf.service.service.*
;
import
com.yd.csf.service.utils.GSONUtil
;
import
com.yd.oss.feign.client.ApiMaterialFeignClient
;
import
com.yd.oss.feign.client.ApiRelObjectMaterialFeignClient
;
import
com.yd.oss.feign.request.ApiMaterialListRequest
;
import
com.yd.oss.feign.request.ApiRelObjectMaterialListAddRequest
;
import
com.yd.oss.feign.response.ApiMaterialListResponse
;
import
com.yd.question.feign.client.ApiQuestionnairesFeignClient
;
import
com.yd.question.feign.dto.ApiAnswerSessionsDto
;
import
com.yd.question.feign.request.ApiAnswerSaveRequest
;
import
com.yd.question.feign.request.ApiBatchSaveAnswerRequest
;
import
com.yd.question.feign.request.ApiObjectSaveRequest
;
import
com.yd.question.feign.response.ApiAnswerSaveResponse
;
import
lombok.extern.slf4j.Slf4j
;
import
org.apache.commons.lang3.StringUtils
;
import
org.springframework.beans.BeanUtils
;
...
...
@@ -45,6 +46,7 @@ import java.util.ArrayList;
import
java.util.Date
;
import
java.util.List
;
import
java.util.Objects
;
import
java.util.stream.Collectors
;
/**
* 预约信息业务实现类
...
...
@@ -84,9 +86,39 @@ public class ApiAppointmentServiceImpl implements ApiAppointmentService {
private
FnaService
fnaService
;
@Autowired
private
ApiAppointmentReferrerService
appointmentReferrerService
;
@Autowired
private
ApiAppointmentLogService
appointmentLogService
;
@Autowired
private
ApiAppointmentReferrerLogService
apiAppointmentReferrerLogService
;
@Autowired
private
ApiAppointmentUserSignService
apiAppointmentUserSignService
;
@Autowired
private
ApiAppointmentUserSignLogService
apiAppointmentUserSignLogService
;
@Autowired
private
IAppointmentLogService
iAppointmentLogService
;
@Autowired
private
IAppointmentReferrerLogService
iAppointmentReferrerLogService
;
@Autowired
private
IAppointmentUserSignLogService
iAppointmentUserSignLogService
;
@Autowired
private
ApiQuestionnairesFeignClient
apiQuestionnairesFeignClient
;
@Autowired
private
ApiRelObjectMaterialFeignClient
apiRelObjectMaterialFeignClient
;
@Autowired
private
ApiMaterialFeignClient
apiMaterialFeignClient
;
@Autowired
private
PolicyFollowService
policyFollowService
;
@Resource
private
PolicyService
policyService
;
...
...
@@ -183,34 +215,38 @@ public class ApiAppointmentServiceImpl implements ApiAppointmentService {
@Override
@Transactional
(
rollbackFor
=
Exception
.
class
)
public
Result
<
ApiAppointmentAddResponse
>
add
(
ApiAppointmentAddRequest
request
)
{
//新增预约入参字段校验(非库校验)
apiAppointmentCheckService
.
checkAddRequest
(
request
);
//新增预约-添加预约信息主表数据 - 预约状态为待预约
Result
<
Appointment
>
appointmentResult
=
addAppointmentData
(
request
.
getApiAppointmentInfoDto
(),
AppointmentStatusEnum
.
DYY
.
getItemValue
());
if
(
Objects
.
isNull
(
request
.
getApiAppointmentInfoDto
()))
{
request
.
setApiAppointmentInfoDto
(
new
ApiAppointmentInfoDto
());
}
//提交 ——>流转状态为预约中
Result
<
Appointment
>
appointmentResult
=
addAppointmentData
(
request
.
getApiAppointmentInfoDto
(),
AppointmentStatusEnum
.
YYZ
.
getItemValue
());
Appointment
appointment
=
appointmentResult
.
getData
();
//添加预约日志信息
Result
<
String
>
result
=
appointmentLogService
.
saveAppointmentLog
(
appointment
);
//添加陪同转介人信息列表
appointmentReferrerService
.
saveAppointmentReferrerList
(
request
.
getApiAppointmentInfoDto
().
getReferrerDtoList
(),
appointment
.
getAppointmentBizId
());
//添加预约-陪同转介人日志信息
apiAppointmentReferrerLogService
.
saveAppointmentReferrerLogList
(
request
.
getApiAppointmentInfoDto
().
getReferrerDtoList
(),
result
.
getData
());
//添加产品计划信息表数据
Result
<
ProductPlan
>
productPlanResult
=
apiProductPlanService
.
addProductPlanData
(
request
.
getApiProductPlanInfoDto
(),
appointment
.
getAppointmentBizId
());
ProductPlan
productPlan
=
productPlanResult
.
getData
();
//批量添加产品计划-附加险信息表数据
apiAdditionalService
.
batchAddAdditionalData
(
request
.
getApiProductPlanInfoDto
(),
productPlan
.
getPlanBizId
());
//添加投保人信息表数据
apiPolicyholderService
.
addPolicyholderData
(
request
.
getApiPolicyholderInfoDto
(),
appointment
.
getAppointmentBizId
());
//添加受保人信息表数据
apiInsurantService
.
addInsurantData
(
request
.
getApiInsurantInfoDto
(),
appointment
.
getAppointmentBizId
());
//批量添加受益人信息表数据
apiBeneficiaryService
.
batchAddBeneficiaryData
(
request
.
getApiBeneficiaryInfoDtoList
(),
appointment
.
getAppointmentBizId
());
//添加第二持有人信息表数据
apiSecondHolderService
.
addSecondHolderData
(
request
.
getApiSecondHolderInfoDto
(),
appointment
.
getAppointmentBizId
());
//新增健康问卷和预约对象关系绑定
objectSaveJkQuestion
(
appointment
.
getAppointmentBizId
());
//新增对象材料关系信息
addRelObjectMaterialList
(
appointment
.
getAppointmentBizId
());
//预约编号和预约业务id更新到FNA表(提交待预约状态,预约信息的预约业务id和预约编号更新到Fna表的预约业务id和预约编号)
updateFnaBizIdAndNo
(
appointment
.
getFnaBizId
(),
appointment
.
getAppointmentBizId
(),
appointment
.
getAppointmentNo
());
ApiAppointmentAddResponse
response
=
new
ApiAppointmentAddResponse
();
...
...
@@ -219,6 +255,31 @@ public class ApiAppointmentServiceImpl implements ApiAppointmentService {
}
/**
* 新增对象材料关系信息
* @param appointmentBizId
* @return
*/
public
Result
addRelObjectMaterialList
(
String
appointmentBizId
)
{
ApiMaterialListRequest
request
=
new
ApiMaterialListRequest
();
request
.
setObjectType
(
CommonEnum
.
UID_TYPE_APPOINTMENT
.
getCode
());
//列表查询-材料基础信息
Result
<
List
<
ApiMaterialListResponse
>>
result
=
apiMaterialFeignClient
.
list
(
request
);
List
<
String
>
materialBizIdList
=
new
ArrayList
<>();
if
(!
CollectionUtils
.
isEmpty
(
result
.
getData
()))
{
materialBizIdList
=
result
.
getData
().
stream
().
map
(
ApiMaterialListResponse:
:
getMaterialBizId
).
collect
(
Collectors
.
toList
());
}
//添加-单个对象和材料列表关系信息
ApiRelObjectMaterialListAddRequest
addRequest
=
new
ApiRelObjectMaterialListAddRequest
();
addRequest
.
setMaterialBizIdList
(
materialBizIdList
);
addRequest
.
setObjectBizId
(
appointmentBizId
);
addRequest
.
setObjectName
(
CommonEnum
.
UID_TYPE_APPOINTMENT
.
getName
());
addRequest
.
setObjectTableName
(
CommonEnum
.
UID_TYPE_APPOINTMENT
.
getCode
());
addRequest
.
setObjectType
(
CommonEnum
.
UID_TYPE_APPOINTMENT
.
getCode
());
apiRelObjectMaterialFeignClient
.
addRelObjectMaterialList
(
addRequest
);
return
Result
.
success
();
}
/**
* 提交待预约状态,预约信息更新到Fna表的预约业务id和预约编号
*
* @return
...
...
@@ -237,7 +298,6 @@ public class ApiAppointmentServiceImpl implements ApiAppointmentService {
/**
* 新增预约暂存
*
* @param request
* @return
*/
...
...
@@ -247,34 +307,33 @@ public class ApiAppointmentServiceImpl implements ApiAppointmentService {
if
(
Objects
.
isNull
(
request
.
getApiAppointmentInfoDto
()))
{
request
.
setApiAppointmentInfoDto
(
new
ApiAppointmentInfoDto
());
}
//校验预约信息-客户和fna入参
apiAppointmentCheckService
.
checkCustomerAndFna
(
request
.
getApiAppointmentInfoDto
(),
"预约信息-"
);
//新增预约暂存-添加预约信息主表数据为
暂存
状态
Result
<
Appointment
>
appointmentResult
=
addAppointmentData
(
request
.
getApiAppointmentInfoDto
(),
AppointmentStatusEnum
.
ZC
.
getItemValue
());
//新增预约暂存-添加预约信息主表数据为
待完善
状态
Result
<
Appointment
>
appointmentResult
=
addAppointmentData
(
request
.
getApiAppointmentInfoDto
(),
AppointmentStatusEnum
.
DWS
.
getItemValue
());
Appointment
appointment
=
appointmentResult
.
getData
();
//添加预约日志信息
Result
<
String
>
result
=
appointmentLogService
.
saveAppointmentLog
(
appointment
);
//添加陪同转介人信息列表
appointmentReferrerService
.
saveAppointmentReferrerList
(
request
.
getApiAppointmentInfoDto
().
getReferrerDtoList
(),
appointment
.
getAppointmentBizId
());
//添加预约-陪同转介人日志信息
apiAppointmentReferrerLogService
.
saveAppointmentReferrerLogList
(
request
.
getApiAppointmentInfoDto
().
getReferrerDtoList
(),
result
.
getData
());
//添加产品计划信息表数据
Result
<
ProductPlan
>
productPlanResult
=
apiProductPlanService
.
addProductPlanData
(
request
.
getApiProductPlanInfoDto
(),
appointment
.
getAppointmentBizId
());
ProductPlan
productPlan
=
productPlanResult
.
getData
();
//批量添加产品计划-附加险信息表数据
apiAdditionalService
.
batchAddAdditionalData
(
request
.
getApiProductPlanInfoDto
(),
productPlan
.
getPlanBizId
());
//添加投保人信息表数据
apiPolicyholderService
.
addPolicyholderData
(
request
.
getApiPolicyholderInfoDto
(),
appointment
.
getAppointmentBizId
());
//添加受保人信息表数据
apiInsurantService
.
addInsurantData
(
request
.
getApiInsurantInfoDto
(),
appointment
.
getAppointmentBizId
());
//批量添加受益人信息表数据
apiBeneficiaryService
.
batchAddBeneficiaryData
(
request
.
getApiBeneficiaryInfoDtoList
(),
appointment
.
getAppointmentBizId
());
//添加第二持有人信息表数据
apiSecondHolderService
.
addSecondHolderData
(
request
.
getApiSecondHolderInfoDto
(),
appointment
.
getAppointmentBizId
());
//预约编号和预约业务id更新到FNA表(提交待预约状态,预约信息的预约业务id和预约编号更新到Fna表的预约业务id和预约编号)
updateFnaBizIdAndNo
(
appointment
.
getFnaBizId
(),
appointment
.
getAppointmentBizId
(),
appointment
.
getAppointmentNo
());
//新增健康问卷和预约对象关系绑定
objectSaveJkQuestion
(
appointment
.
getAppointmentBizId
());
...
...
@@ -317,8 +376,6 @@ public class ApiAppointmentServiceImpl implements ApiAppointmentService {
@Override
@Transactional
(
rollbackFor
=
Exception
.
class
)
public
Result
edit
(
ApiAppointmentEditRequest
request
)
{
//编辑预约入参字段校验(非库校验)
apiAppointmentCheckService
.
checkEditRequest
(
request
);
Integer
status
=
null
;
Appointment
appointmentCheck
=
null
;
...
...
@@ -326,48 +383,108 @@ public class ApiAppointmentServiceImpl implements ApiAppointmentService {
//校验预约信息是否存在
Result
<
Appointment
>
result
=
checkAppointmentIsExist
(
request
.
getApiAppointmentInfoDto
().
getAppointmentBizId
());
appointmentCheck
=
result
.
getData
();
if
(
AppointmentStatusEnum
.
ZC
.
getItemValue
().
equals
(
appointmentCheck
.
getStatus
()))
{
//当前为暂存状态——>提交更新为待预约状态
status
=
AppointmentStatusEnum
.
DYY
.
getItemValue
();
if
(
AppointmentStatusEnum
.
DWS
.
getItemValue
().
equals
(
appointmentCheck
.
getStatus
()))
{
//当前为待完善状态——>状态更新为预约中
status
=
AppointmentStatusEnum
.
YYZ
.
getItemValue
();
}
else
if
(
AppointmentStatusEnum
.
YQX
.
getItemValue
().
equals
(
appointmentCheck
.
getStatus
()))
{
//当前为已取消状态——>状态更新为预约中
status
=
AppointmentStatusEnum
.
YYZ
.
getItemValue
();
}
else
if
(
AppointmentStatusEnum
.
YYZ
.
getItemValue
().
equals
(
appointmentCheck
.
getStatus
()))
{
//当前状态为预约中 ——> 状态更新为预约成功 ——> 新增新单跟进记录
status
=
AppointmentStatusEnum
.
YY_CG
.
getItemValue
();
}
// else if (AppointmentStatusEnum.DYY.getItemValue().equals(appointmentCheck.getStatus())){
// if (Objects.isNull(request.getApiAppointmentInfoDto().getConfirmAppointmentTime())) {
// //待预约提交到待签署状态,确定预约时间不能为空
// throw new BusinessException("待预约提交确定预约时间不能为空!");
// }
// //当前为待预约状态——>提交更新为待签署状态-->到新单跟进
// status = AppointmentStatusEnum.DQS.getItemValue();
// }
//其他状态下都是单纯编辑数据不做状态流转更新
}
//编辑预约提交-编辑预约信息主表数据
if
(
Objects
.
isNull
(
request
.
getApiAppointmentInfoDto
()))
{
request
.
setApiAppointmentInfoDto
(
new
ApiAppointmentInfoDto
());
}
Result
<
Appointment
>
appointmentResult
=
editAppointmentData
(
request
.
getApiAppointmentInfoDto
(),
status
);
Appointment
appointment
=
appointmentResult
.
getData
();
//添加预约日志信息
Result
<
String
>
result
=
appointmentLogService
.
saveAppointmentLog
(
appointmentResult
.
getData
());
//添加陪同转介人信息列表
appointmentReferrerService
.
saveAppointmentReferrerList
(
request
.
getApiAppointmentInfoDto
().
getReferrerDtoList
(),
appointment
.
getAppointmentBizId
());
//添加预约-陪同转介人日志信息
apiAppointmentReferrerLogService
.
saveAppointmentReferrerLogList
(
request
.
getApiAppointmentInfoDto
().
getReferrerDtoList
(),
result
.
getData
());
//添加签单员列表信息
apiAppointmentUserSignService
.
saveAppointmentUserSignList
(
request
.
getApiAppointmentInfoDto
().
getUserSignDtoList
(),
appointment
.
getAppointmentBizId
());
//添加预约-签单员列表信息日志
apiAppointmentUserSignLogService
.
saveAppointmentUserSignLogList
(
request
.
getApiAppointmentInfoDto
().
getUserSignDtoList
(),
result
.
getData
());
//编辑产品计划信息表数据
Result
<
ProductPlan
>
productPlanResult
=
apiProductPlanService
.
editProductPlanData
(
request
.
getApiProductPlanInfoDto
(),
appointment
.
getAppointmentBizId
());
ProductPlan
productPlan
=
productPlanResult
.
getData
();
//批量编辑产品计划-附加险信息表数据
apiAdditionalService
.
batchEditAdditionalData
(
request
.
getApiProductPlanInfoDto
(),
productPlan
.
getPlanBizId
());
//编辑投保人信息表数据
apiPolicyholderService
.
editPolicyholderData
(
request
.
getApiPolicyholderInfoDto
(),
appointment
.
getAppointmentBizId
());
//编辑受保人信息表数据
apiInsurantService
.
editInsurantData
(
request
.
getApiInsurantInfoDto
(),
appointment
.
getAppointmentBizId
());
//批量编辑受益人信息表数据
apiBeneficiaryService
.
batchEditBeneficiaryData
(
request
.
getApiBeneficiaryInfoDtoList
(),
appointment
.
getAppointmentBizId
());
//编辑第二持有人信息表数据
apiSecondHolderService
.
editSecondHolderData
(
request
.
getApiSecondHolderInfoDto
(),
appointment
.
getAppointmentBizId
());
if
(!
Objects
.
isNull
(
status
)
&&
AppointmentStatusEnum
.
DYY
.
getItemValue
().
equals
(
status
))
{
//当前为暂存状态——>提交更新为待预约状态需要更新Fna表的编号和业务id完成绑定关联
//预约编号和预约业务id更新到FNA表(提交待预约状态,预约信息的预约业务id和预约编号更新到Fna表的预约业务id和预约编号)
//远程调用-问卷-答题提交接口
if
(!
CollectionUtils
.
isEmpty
(
request
.
getAnswerSessionsDtoList
()))
{
ApiAnswerSaveRequest
answerSaveRequest
=
new
ApiAnswerSaveRequest
();
answerSaveRequest
.
setObjectBizId
(
appointment
.
getAppointmentBizId
());
answerSaveRequest
.
setQuestionnaireBizId
(
"questionnaires_1001"
);
answerSaveRequest
.
setAnswerSessionsDtoList
(
request
.
getAnswerSessionsDtoList
());
apiQuestionnairesFeignClient
.
answerSave
(
answerSaveRequest
);
}
if
(!
Objects
.
isNull
(
appointmentCheck
)
&&
AppointmentStatusEnum
.
YYZ
.
getItemValue
().
equals
(
appointmentCheck
.
getStatus
()))
{
//当前状态为预约中 ——> 状态更新为预约成功 ——> 更新FNA预约业务id和预约编号、新增新单跟进记录
//更新FNA预约业务id和预约编号
updateFnaBizIdAndNo
(
appointment
.
getFnaBizId
(),
appointment
.
getAppointmentBizId
(),
appointment
.
getAppointmentNo
());
//新增新单跟进记录
savePolicyFollow
(
appointment
);
}
return
Result
.
success
();
}
/**
* 编辑预约暂存 (聚合信息编辑预约暂存)
* @param request
* @return
*/
@Override
public
Result
editStorage
(
ApiAppointmentEditStorageRequest
request
)
{
//校验预约信息-客户和fna入参
apiAppointmentCheckService
.
checkCustomerAndFna
(
request
.
getApiAppointmentInfoDto
(),
"预约信息-"
);
//编辑预约提交-编辑预约信息主表数据
if
(
Objects
.
isNull
(
request
.
getApiAppointmentInfoDto
()))
{
request
.
setApiAppointmentInfoDto
(
new
ApiAppointmentInfoDto
());
}
Result
<
Appointment
>
appointmentResult
=
editAppointmentData
(
request
.
getApiAppointmentInfoDto
(),
null
);
Appointment
appointment
=
appointmentResult
.
getData
();
//添加预约日志信息
Result
<
String
>
result
=
appointmentLogService
.
saveAppointmentLog
(
appointmentResult
.
getData
());
//添加陪同转介人信息列表
appointmentReferrerService
.
saveAppointmentReferrerList
(
request
.
getApiAppointmentInfoDto
().
getReferrerDtoList
(),
appointment
.
getAppointmentBizId
());
//添加预约-陪同转介人日志信息
apiAppointmentReferrerLogService
.
saveAppointmentReferrerLogList
(
request
.
getApiAppointmentInfoDto
().
getReferrerDtoList
(),
result
.
getData
());
//添加签单员列表信息
apiAppointmentUserSignService
.
saveAppointmentUserSignList
(
request
.
getApiAppointmentInfoDto
().
getUserSignDtoList
(),
appointment
.
getAppointmentBizId
());
//添加预约-签单员列表信息日志
apiAppointmentUserSignLogService
.
saveAppointmentUserSignLogList
(
request
.
getApiAppointmentInfoDto
().
getUserSignDtoList
(),
result
.
getData
());
//编辑产品计划信息表数据
Result
<
ProductPlan
>
productPlanResult
=
apiProductPlanService
.
editProductPlanData
(
request
.
getApiProductPlanInfoDto
(),
appointment
.
getAppointmentBizId
());
ProductPlan
productPlan
=
productPlanResult
.
getData
();
//批量编辑产品计划-附加险信息表数据
apiAdditionalService
.
batchEditAdditionalData
(
request
.
getApiProductPlanInfoDto
(),
productPlan
.
getPlanBizId
());
//编辑投保人信息表数据
apiPolicyholderService
.
editPolicyholderData
(
request
.
getApiPolicyholderInfoDto
(),
appointment
.
getAppointmentBizId
());
//编辑受保人信息表数据
apiInsurantService
.
editInsurantData
(
request
.
getApiInsurantInfoDto
(),
appointment
.
getAppointmentBizId
());
//批量编辑受益人信息表数据
apiBeneficiaryService
.
batchEditBeneficiaryData
(
request
.
getApiBeneficiaryInfoDtoList
(),
appointment
.
getAppointmentBizId
());
//编辑第二持有人信息表数据
apiSecondHolderService
.
editSecondHolderData
(
request
.
getApiSecondHolderInfoDto
(),
appointment
.
getAppointmentBizId
());
//远程调用-问卷-答题提交接口
if
(!
CollectionUtils
.
isEmpty
(
request
.
getAnswerSessionsDtoList
()))
{
...
...
@@ -377,7 +494,6 @@ public class ApiAppointmentServiceImpl implements ApiAppointmentService {
answerSaveRequest
.
setAnswerSessionsDtoList
(
request
.
getAnswerSessionsDtoList
());
apiQuestionnairesFeignClient
.
answerSave
(
answerSaveRequest
);
}
return
Result
.
success
();
}
...
...
@@ -391,25 +507,25 @@ public class ApiAppointmentServiceImpl implements ApiAppointmentService {
@Transactional
(
rollbackFor
=
Exception
.
class
)
public
Result
editConfirmTime
(
ApiAppointmentEditConfirmTimeRequest
request
)
{
//校验预约信息是否存在
Result
<
Appointment
>
result
=
checkAppointmentIsExist
(
request
.
getAppointmentBizId
());
Appointment
appointment
=
result
.
getData
();
if
(!
AppointmentStatusEnum
.
DYY
.
getItemValue
().
equals
(
appointment
.
getStatus
()))
{
//非待预约状态,不能更新
if
(
AppointmentStatusEnum
.
ZC
.
getItemValue
().
equals
(
appointment
.
getStatus
()))
{
//暂存
throw
new
BusinessException
(
"当前为暂存状态,不能提交到新单跟进!"
);
}
else
{
//其他状态
throw
new
BusinessException
(
"你已经提交到新单跟进,不能再次提交!"
);
}
}
appointment
.
setConfirmAppointmentTime
(
request
.
getConfirmAppointmentTime
());
//流转到新单跟进(这里的预约状态为待签署)
appointment
.
setStatus
(
AppointmentStatusEnum
.
DQS
.
getItemValue
());
iAppointmentService
.
saveOrUpdate
(
appointment
);
//确定预约时间提交 (流程流转到新单跟进) - 新增新单跟进记录
savePolicyFollow
(
appointment
);
//
Result<Appointment> result = checkAppointmentIsExist(request.getAppointmentBizId());
//
Appointment appointment = result.getData();
//
if (!AppointmentStatusEnum.DYY.getItemValue().equals(appointment.getStatus())) {
//
//非待预约状态,不能更新
//
if (AppointmentStatusEnum.ZC.getItemValue().equals(appointment.getStatus())) {
//
//暂存
//
throw new BusinessException("当前为暂存状态,不能提交到新单跟进!");
//
} else {
//
//其他状态
//
throw new BusinessException("你已经提交到新单跟进,不能再次提交!");
//
}
//
}
//
appointment.setConfirmAppointmentTime(request.getConfirmAppointmentTime());
//
//流转到新单跟进(这里的预约状态为待签署)
//
appointment.setStatus(AppointmentStatusEnum.DQS.getItemValue());
//
iAppointmentService.saveOrUpdate(appointment);
//
//
//确定预约时间提交 (流程流转到新单跟进) - 新增新单跟进记录
//
savePolicyFollow(appointment);
return
Result
.
success
();
}
...
...
@@ -478,7 +594,7 @@ public class ApiAppointmentServiceImpl implements ApiAppointmentService {
// follow.setPaymentPremium();
// 保單持有人
if
(
apiPolicyholderInfoDto
!=
null
)
{
follow
.
setPolicyHolder
(
apiPolicyholderInfoDto
.
getName
());
follow
.
setPolicyHolder
(
apiPolicyholderInfoDto
.
getName
Cn
());
}
//TODO 预缴年期
// follow.setPrepaidTerm();
...
...
@@ -494,7 +610,7 @@ public class ApiAppointmentServiceImpl implements ApiAppointmentService {
follow
.
setUserBizId
(
appointment
.
getCreatorId
());
if
(!
Objects
.
isNull
(
apiInsurantInfoDto
))
{
// 受保人
follow
.
setInsured
(
apiInsurantInfoDto
.
getName
());
follow
.
setInsured
(
apiInsurantInfoDto
.
getName
Cn
());
// 受保人与保單持有人关系
if
(
"MYSELF"
.
equals
(
apiInsurantInfoDto
.
getPolicyholderRel
()))
{
follow
.
setInsured
(
follow
.
getPolicyHolder
());
...
...
@@ -503,26 +619,26 @@ public class ApiAppointmentServiceImpl implements ApiAppointmentService {
if
(!
Objects
.
isNull
(
apiProductPlanMainInfoDto
))
{
//币种
follow
.
setCurrency
(
apiProductPlanMainInfoDto
.
getCurrency
());
follow
.
setCurrency
(
apiProductPlanMainInfoDto
.
get
Policy
Currency
());
//生效日期
if
(!
Objects
.
isNull
(
apiProductPlanMainInfoDto
.
getPolicyEffectiveDate
()))
{
follow
.
setEffectiveDate
(
Date
.
from
(
apiProductPlanMainInfoDto
.
getPolicyEffectiveDate
().
atZone
(
ZoneId
.
systemDefault
()).
toInstant
()));
}
//
if (!Objects.isNull(apiProductPlanMainInfoDto.getPolicyEffectiveDate())) {
//
follow.setEffectiveDate(Date.from(apiProductPlanMainInfoDto.getPolicyEffectiveDate().atZone(ZoneId.systemDefault()).toInstant()));
//
}
//首期保费(不含徽费,预缴保费)每期保费
follow
.
setInitialPremium
(
apiProductPlanMainInfoDto
.
getEachIssuePremium
());
//保险公司
follow
.
setInsurer
(
apiProductPlanMainInfoDto
.
getCompanyName
());
//是否预缴
follow
.
setIsPrepaid
(
apiProductPlanMainInfoDto
.
getIsPrepay
(
));
follow
.
setIsPrepaid
(
Integer
.
parseInt
(
apiProductPlanMainInfoDto
.
getIsPrepay
()
));
//供款年期
if
(
StringUtils
.
isNotBlank
(
apiProductPlanMainInfoDto
.
get
PaymentTerm
()))
{
follow
.
setPaymentTerm
(
Integer
.
getInteger
(
apiProductPlanMainInfoDto
.
getPaymentTerm
()
));
if
(
StringUtils
.
isNotBlank
(
apiProductPlanMainInfoDto
.
get
IssueNumber
()))
{
follow
.
setPaymentTerm
(
apiProductPlanMainInfoDto
.
getIssueNumber
(
));
if
(
follow
.
getPaymentTerm
()
==
null
)
{
follow
.
setPaymentTerm
(
productPlan
.
get
PaymentTerm
());
follow
.
setPaymentTerm
(
productPlan
.
get
IssueNumber
());
}
}
//产品名称
follow
.
setProductName
(
apiProductPlanMainInfoDto
.
getProductName
());
follow
.
setProductName
(
apiProductPlanMainInfoDto
.
getProduct
Launch
Name
());
//签单员列表
setSignerList
(
follow
,
appointment
);
}
...
...
@@ -631,9 +747,9 @@ public class ApiAppointmentServiceImpl implements ApiAppointmentService {
for
(
ApiBeneficiaryInfoDto
apiBeneficiaryInfoDto
:
apiBeneficiaryInfoDtoList
)
{
PolicyBeneficiary
policyBeneficiary
=
new
PolicyBeneficiary
();
BeanUtils
.
copyProperties
(
apiBeneficiaryInfoDto
,
policyBeneficiary
,
"addressList"
);
if
(!
CollectionUtils
.
isEmpty
(
apiBeneficiaryInfoDto
.
getAddressList
()))
{
policyBeneficiary
.
setAddressList
(
GSONUtil
.
toJson
(
apiBeneficiaryInfoDto
.
getAddressList
()));
}
//
if (!CollectionUtils.isEmpty(apiBeneficiaryInfoDto.getAddressList())) {
//
policyBeneficiary.setAddressList(GSONUtil.toJson(apiBeneficiaryInfoDto.getAddressList()));
//
}
policyBeneficiary
.
setId
(
null
);
policyBeneficiary
.
setPolicyBizId
(
policyBizId
);
policyBeneficiary
.
setPolicyBeneficiaryBizId
(
RandomStringGenerator
.
generateBizId16
(
"policy_beneficiary"
));
...
...
@@ -655,7 +771,7 @@ public class ApiAppointmentServiceImpl implements ApiAppointmentService {
policyInsurant
.
setId
(
null
);
policyInsurant
.
setPolicyBizId
(
policyBizId
);
policyInsurant
.
setPolicyInsurantBizId
(
RandomStringGenerator
.
generateBizId16
(
"policy_insurant"
));
policyInsurant
.
setName
(
apiInsurantInfoDto
.
getName
());
policyInsurant
.
setName
(
apiInsurantInfoDto
.
getName
Cn
());
return
policyInsurantService
.
saveOrUpdate
(
policyInsurant
);
}
...
...
@@ -672,7 +788,7 @@ public class ApiAppointmentServiceImpl implements ApiAppointmentService {
policyPolicyholder
.
setId
(
null
);
policyPolicyholder
.
setPolicyBizId
(
policyBizId
);
policyPolicyholder
.
setPolicyPolicyholderBizId
(
RandomStringGenerator
.
generateBizId16
(
"policy_policyholder"
));
policyPolicyholder
.
setName
(
apiPolicyholderInfoDto
.
getName
());
policyPolicyholder
.
setName
(
apiPolicyholderInfoDto
.
getName
Cn
());
return
policyPolicyholderService
.
saveOrUpdate
(
policyPolicyholder
);
}
...
...
@@ -684,7 +800,7 @@ public class ApiAppointmentServiceImpl implements ApiAppointmentService {
String
policyBizId
,
String
policyTransfer
)
{
String
appointmentBizId
=
apiProductPlanMainInfoDto
.
getAppointmentBizId
();
//
String appointmentBizId = apiProductPlanMainInfoDto.getAppointmentBizId();
String
planBizId
=
apiProductPlanMainInfoDto
.
getPlanBizId
();
if
(
productPlan
==
null
)
{
return
false
;
...
...
@@ -699,16 +815,16 @@ public class ApiAppointmentServiceImpl implements ApiAppointmentService {
policy
.
setStatus
(
PolicyStatusEnum
.
INFORCE
.
getItemValue
());
// 投保人姓名
if
(
Objects
.
nonNull
(
apiPolicyholderInfoDto
))
{
policy
.
setPolicyHolder
(
apiPolicyholderInfoDto
.
getName
());
policy
.
setPolicyHolder
(
apiPolicyholderInfoDto
.
getName
Cn
());
}
// 被保人姓名
if
(
Objects
.
nonNull
(
apiInsurantInfoDto
))
{
policy
.
setInsured
(
apiInsurantInfoDto
.
getName
());
policy
.
setInsured
(
apiInsurantInfoDto
.
getName
Cn
());
}
// 保额
policy
.
setSumInsured
(
productPlan
.
getSumInsured
());
// 供款年期
policy
.
setPaymentTerm
(
productPlan
.
get
PaymentTerm
());
policy
.
setPaymentTerm
(
productPlan
.
get
IssueNumber
());
// 付款频率(字典)
policy
.
setPaymentFrequency
(
productPlan
.
getPaymentFrequency
());
// 每期保费
...
...
@@ -718,7 +834,7 @@ public class ApiAppointmentServiceImpl implements ApiAppointmentService {
// 保险公司
policy
.
setInsurer
(
productPlan
.
getCompanyName
());
// 是否预缴
policy
.
setIsPrepaid
(
productPlan
.
getIsPrepay
(
));
policy
.
setIsPrepaid
(
Integer
.
parseInt
(
productPlan
.
getIsPrepay
()
));
// 转保声明选项(字典)
policy
.
setPolicyTransfer
(
policyTransfer
);
policy
.
setInsurer
(
productPlan
.
getCompanyName
());
...
...
@@ -743,7 +859,17 @@ public class ApiAppointmentServiceImpl implements ApiAppointmentService {
apiAppointmentCheckService
.
checkEditApiAppointmentInfoDto
(
apiAppointmentInfoDto
);
//编辑预约-编辑预约信息主表数据
editAppointmentData
(
apiAppointmentInfoDto
,
null
);
Result
<
Appointment
>
appointmentResult
=
editAppointmentData
(
apiAppointmentInfoDto
,
null
);
//添加预约日志信息
Result
<
String
>
result
=
appointmentLogService
.
saveAppointmentLog
(
appointmentResult
.
getData
());
//添加陪同转介人信息列表
appointmentReferrerService
.
saveAppointmentReferrerList
(
apiAppointmentInfoDto
.
getReferrerDtoList
(),
apiAppointmentInfoDto
.
getAppointmentBizId
());
//添加预约-陪同转介人日志信息
apiAppointmentReferrerLogService
.
saveAppointmentReferrerLogList
(
apiAppointmentInfoDto
.
getReferrerDtoList
(),
result
.
getData
());
//添加签单员列表信息
apiAppointmentUserSignService
.
saveAppointmentUserSignList
(
apiAppointmentInfoDto
.
getUserSignDtoList
(),
apiAppointmentInfoDto
.
getAppointmentBizId
());
//添加预约-签单员列表信息日志
apiAppointmentUserSignLogService
.
saveAppointmentUserSignLogList
(
apiAppointmentInfoDto
.
getUserSignDtoList
(),
result
.
getData
());
return
Result
.
success
();
}
...
...
@@ -759,15 +885,20 @@ public class ApiAppointmentServiceImpl implements ApiAppointmentService {
//预约信息对象不能为空
throw
new
BusinessException
(
"预约信息对象不能为空"
);
}
if
(
StringUtils
.
isBlank
(
dto
.
getAppointmentBizId
()))
{
throw
new
BusinessException
(
"预约信息主表唯一业务ID不能为空"
);
}
//校验预约信息是否存在
Result
<
Appointment
>
result
=
checkAppointmentIsExist
(
dto
.
getAppointmentBizId
());
Appointment
appointment
=
result
.
getData
();
String
appointmentNo
=
appointment
.
getAppointmentNo
();
BeanUtils
.
copyProperties
(
dto
,
appointment
);
if
(!
Objects
.
isNull
(
status
))
{
//不为空设置状态
appointment
.
setStatus
(
status
);
}
appointment
.
setAppointmentNo
(
appointmentNo
);
iAppointmentService
.
saveOrUpdate
(
appointment
);
return
Result
.
success
(
appointment
);
}
...
...
@@ -871,6 +1002,23 @@ public class ApiAppointmentServiceImpl implements ApiAppointmentService {
}
/**
* 编辑预约状态
* @param request
* @return
*/
@Override
public
Result
editStatus
(
ApiAppointmentEditStatusRequest
request
)
{
//校验预约信息是否存在
Result
<
Appointment
>
result
=
checkAppointmentIsExist
(
request
.
getAppointmentBizId
());
Appointment
appointment
=
result
.
getData
();
if
(
1
==
request
.
getOprType
()
||
2
==
request
.
getOprType
())
{
appointment
.
setStatus
(
AppointmentStatusEnum
.
YYZ
.
getItemValue
());
}
iAppointmentService
.
saveOrUpdate
(
appointment
);
return
Result
.
success
();
}
/**
* 删除预约信息
*
* @param appointmentBizId
...
...
@@ -887,6 +1035,56 @@ public class ApiAppointmentServiceImpl implements ApiAppointmentService {
}
/**
* 历史记录 - 签约信息
* @param request
* @return
*/
@Override
public
Result
<
IPage
<
ApiAppointmentLogPageResponse
>>
logPage
(
ApiAppointmentLogPageRequest
request
)
{
Page
<
ApiAppointmentLogPageResponse
>
page
=
new
Page
<>(
request
.
getPageNo
(),
request
.
getPageSize
());
IPage
<
ApiAppointmentLogPageResponse
>
iPage
=
iAppointmentService
.
logPage
(
page
,
request
);
return
Result
.
success
(
iPage
);
}
/**
* 历史记录 - 签约信息 - 详情
* @param appointmentLogBizId
* @return
*/
@Override
public
Result
<
ApiAppointmentLogDetailResponse
>
logDetail
(
String
appointmentLogBizId
)
{
AppointmentLog
appointmentLog
=
iAppointmentLogService
.
queryOne
(
appointmentLogBizId
);
if
(!
Objects
.
isNull
(
appointmentLog
))
{
//预约信息日志表信息
ApiAppointmentLogDetailResponse
response
=
new
ApiAppointmentLogDetailResponse
();
BeanUtils
.
copyProperties
(
appointmentLog
,
response
);
//预约-转介人信息日志列表
List
<
AppointmentReferrerLog
>
referrerLogList
=
iAppointmentReferrerLogService
.
queryList
(
appointmentLogBizId
);
if
(!
CollectionUtils
.
isEmpty
(
referrerLogList
))
{
List
<
ApiAppointmentReferrerLogDto
>
referrerLogDtoList
=
referrerLogList
.
stream
().
map
(
dto
->
{
ApiAppointmentReferrerLogDto
logDto
=
new
ApiAppointmentReferrerLogDto
();
BeanUtils
.
copyProperties
(
dto
,
logDto
);
return
logDto
;
}).
collect
(
Collectors
.
toList
());
response
.
setReferrerLogDtoList
(
referrerLogDtoList
);
}
//预约-签单员信息日志列表
List
<
AppointmentUserSignLog
>
userSignLogList
=
iAppointmentUserSignLogService
.
queryList
(
appointmentLogBizId
);
if
(!
CollectionUtils
.
isEmpty
(
userSignLogList
))
{
List
<
ApiAppointmentUserSignLogDto
>
userSignLogDtoList
=
referrerLogList
.
stream
().
map
(
dto
->
{
ApiAppointmentUserSignLogDto
logDto
=
new
ApiAppointmentUserSignLogDto
();
BeanUtils
.
copyProperties
(
dto
,
logDto
);
return
logDto
;
}).
collect
(
Collectors
.
toList
());
response
.
setUserSignLogDtoList
(
userSignLogDtoList
);
}
}
return
Result
.
success
();
}
/**
* 新增健康问卷和预约对象关系绑定
*
* @return
...
...
yd-csf-api/src/main/java/com/yd/csf/api/service/impl/ApiAppointmentUserSignLogServiceImpl.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
api
.
service
.
impl
;
import
com.yd.common.enums.CommonEnum
;
import
com.yd.common.result.Result
;
import
com.yd.common.utils.RandomStringGenerator
;
import
com.yd.csf.api.service.ApiAppointmentUserSignLogService
;
import
com.yd.csf.feign.dto.appointment.ApiAppointmentUserSignDto
;
import
com.yd.csf.service.model.AppointmentUserSignLog
;
import
com.yd.csf.service.service.IAppointmentUserSignLogService
;
import
lombok.extern.slf4j.Slf4j
;
import
org.springframework.beans.BeanUtils
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
org.springframework.util.CollectionUtils
;
import
java.util.List
;
import
java.util.stream.Collectors
;
@Slf4j
@Service
public
class
ApiAppointmentUserSignLogServiceImpl
implements
ApiAppointmentUserSignLogService
{
@Autowired
private
IAppointmentUserSignLogService
iAppointmentUserSignLogService
;
/**
* 保存预约签单员列表日志
* @param userSignDtoList
* @param appointmentLogBizId
* @return
*/
@Override
public
Result
saveAppointmentUserSignLogList
(
List
<
ApiAppointmentUserSignDto
>
userSignDtoList
,
String
appointmentLogBizId
)
{
if
(
CollectionUtils
.
isEmpty
(
userSignDtoList
))
{
return
Result
.
success
();
}
List
<
AppointmentUserSignLog
>
saveList
=
userSignDtoList
.
stream
().
map
(
dto
->
{
AppointmentUserSignLog
log
=
new
AppointmentUserSignLog
();
BeanUtils
.
copyProperties
(
dto
,
log
);
log
.
setAppointmentLogBizId
(
appointmentLogBizId
);
log
.
setAppointmentUserSignLogBizId
(
RandomStringGenerator
.
generateBizId16
(
CommonEnum
.
UID_TYPE_APPOINTMENT_USER_SIGN_LOG
.
getCode
()));
return
log
;
}).
collect
(
Collectors
.
toList
());
iAppointmentUserSignLogService
.
saveOrUpdateBatch
(
saveList
);
return
Result
.
success
();
}
}
yd-csf-api/src/main/java/com/yd/csf/api/service/impl/ApiAppointmentUserSignServiceImpl.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
api
.
service
.
impl
;
import
com.yd.common.enums.CommonEnum
;
import
com.yd.common.result.Result
;
import
com.yd.common.utils.RandomStringGenerator
;
import
com.yd.csf.api.service.ApiAppointmentUserSignService
;
import
com.yd.csf.feign.dto.appointment.ApiAppointmentUserSignDto
;
import
com.yd.csf.service.model.AppointmentReferrer
;
import
com.yd.csf.service.model.AppointmentUserSign
;
import
com.yd.csf.service.service.IAppointmentUserSignService
;
import
lombok.extern.slf4j.Slf4j
;
import
org.springframework.beans.BeanUtils
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
org.springframework.util.CollectionUtils
;
import
java.util.List
;
import
java.util.stream.Collectors
;
@Slf4j
@Service
public
class
ApiAppointmentUserSignServiceImpl
implements
ApiAppointmentUserSignService
{
@Autowired
private
IAppointmentUserSignService
iAppointmentUserSignService
;
/**
* 保存签单员列表信息
* @param userSignDtoList
* @param appointmentBizId
* @return
*/
@Override
public
Result
saveAppointmentUserSignList
(
List
<
ApiAppointmentUserSignDto
>
userSignDtoList
,
String
appointmentBizId
)
{
if
(
CollectionUtils
.
isEmpty
(
userSignDtoList
))
{
return
Result
.
success
();
}
//先删后新增
iAppointmentUserSignService
.
delByAppointmentBizId
(
appointmentBizId
);
//新增
List
<
AppointmentUserSign
>
saveList
=
userSignDtoList
.
stream
().
map
(
dto
->
{
AppointmentUserSign
userSign
=
new
AppointmentUserSign
();
BeanUtils
.
copyProperties
(
dto
,
userSign
);
userSign
.
setAppointmentBizId
(
appointmentBizId
);
userSign
.
setAppointmentUserSignBizId
(
RandomStringGenerator
.
generateBizId16
(
CommonEnum
.
UID_TYPE_APPOINTMENT_USER_SIGN
.
getCode
()));
return
userSign
;
}).
collect
(
Collectors
.
toList
());
iAppointmentUserSignService
.
saveOrUpdateBatch
(
saveList
);
return
Result
.
success
();
}
}
yd-csf-api/src/main/java/com/yd/csf/api/service/impl/ApiBeneficiaryServiceImpl.java
View file @
7b943b2c
...
...
@@ -54,8 +54,6 @@ public class ApiBeneficiaryServiceImpl implements ApiBeneficiaryService {
dtoList
=
list
.
stream
().
map
(
dto
->
{
ApiBeneficiaryInfoDto
infoDto
=
new
ApiBeneficiaryInfoDto
();
BeanUtils
.
copyProperties
(
dto
,
infoDto
);
//地址列表
infoDto
.
setAddressList
(
CommonUtil
.
getAddressList
(
dto
.
getAddressList
()));
return
infoDto
;
}).
collect
(
Collectors
.
toList
());
}
...
...
@@ -74,8 +72,6 @@ public class ApiBeneficiaryServiceImpl implements ApiBeneficiaryService {
Beneficiary
beneficiary
=
result
.
getData
();
ApiBeneficiaryInfoDto
dto
=
new
ApiBeneficiaryInfoDto
();
BeanUtils
.
copyProperties
(
beneficiary
,
dto
);
//地址列表
dto
.
setAddressList
(
CommonUtil
.
getAddressList
(
beneficiary
.
getAddressList
()));
return
Result
.
success
(
dto
);
}
...
...
@@ -88,7 +84,7 @@ public class ApiBeneficiaryServiceImpl implements ApiBeneficiaryService {
public
Result
add
(
ApiBeneficiaryInfoDto
apiBeneficiaryInfoDto
)
{
List
<
ApiBeneficiaryInfoDto
>
list
=
new
ArrayList
<>();
list
.
add
(
apiBeneficiaryInfoDto
);
apiAppointmentCheckService
.
checkAddApiBeneficiaryInfoDtoList
(
list
);
//
apiAppointmentCheckService.checkAddApiBeneficiaryInfoDtoList(list);
//批量添加受益人信息表数据
batchAddBeneficiaryData
(
list
,
apiBeneficiaryInfoDto
.
getAppointmentBizId
());
...
...
@@ -104,10 +100,13 @@ public class ApiBeneficiaryServiceImpl implements ApiBeneficiaryService {
public
Result
edit
(
ApiBeneficiaryInfoDto
apiBeneficiaryInfoDto
)
{
//编辑预约入参字段校验 - 编辑单个受益人信息字段校验
apiAppointmentCheckService
.
checkEditApiBeneficiaryInfoDto
(
apiBeneficiaryInfoDto
);
List
<
ApiBeneficiaryInfoDto
>
list
=
new
ArrayList
<>();
list
.
add
(
apiBeneficiaryInfoDto
);
//批量编辑受益人信息表数据
batchEditBeneficiaryData
(
list
,
apiBeneficiaryInfoDto
.
getAppointmentBizId
());
//校验受益人信息是否存在
Result
<
Beneficiary
>
result
=
checkBeneficiaryIsExist
(
apiBeneficiaryInfoDto
.
getBeneficiaryBizId
());
Beneficiary
beneficiary
=
result
.
getData
();
BeanUtils
.
copyProperties
(
apiBeneficiaryInfoDto
,
beneficiary
);
beneficiary
.
setId
(
result
.
getData
().
getId
());
beneficiary
.
setAppointmentBizId
(
result
.
getData
().
getAppointmentBizId
());
iBeneficiaryService
.
saveOrUpdate
(
beneficiary
);
return
Result
.
success
();
}
...
...
@@ -160,8 +159,6 @@ public class ApiBeneficiaryServiceImpl implements ApiBeneficiaryService {
beneficiary
.
setBeneficiaryBizId
(
RandomStringGenerator
.
generateBizId16
(
CommonEnum
.
UID_TYPE_BENEFICIARY
.
getCode
()));
//预约信息主表唯一业务ID
beneficiary
.
setAppointmentBizId
(
appointmentBizId
);
//地址列表(json串)
beneficiary
.
setAddressList
(
CommonUtil
.
getAddressListJsonStr
(
dto
.
getAddressList
()));
return
beneficiary
;
}).
collect
(
Collectors
.
toList
());
...
...
@@ -177,68 +174,23 @@ public class ApiBeneficiaryServiceImpl implements ApiBeneficiaryService {
* @return
*/
@Override
public
Result
batchEditBeneficiaryData
(
List
<
ApiBeneficiaryInfoDto
>
list
,
String
appointmentBizId
)
{
public
Result
batchEditBeneficiaryData
(
List
<
ApiBeneficiaryInfoDto
>
list
,
String
appointmentBizId
)
{
if
(
CollectionUtils
.
isEmpty
(
list
)){
//为空放行
return
Result
.
success
();
}
// //获取不为空的受益人信息表唯一业务ID列表
// List<String> beneficiaryBizIdList = list.stream()
// .filter(dto -> StringUtils.isNotBlank(dto.getBeneficiaryBizId()))
// .map(ApiBeneficiaryInfoDto::getBeneficiaryBizId)
// .collect(Collectors.toList());
//
// if (!CollectionUtils.isEmpty(beneficiaryBizIdList)) {
// //入参的受益人业务id列表至少一个不为空就走表数据校验,全部为空是全部新增操作,不走表数据校验
//
// //根据受益人信息表唯一业务ID列表查询表里面的列表信息
// List<Beneficiary> beneficiarys = iBeneficiaryService.queryList(BeneficiaryDto.builder()
// .beneficiaryBizIdList(beneficiaryBizIdList).build());
//
// //过滤入参的受益人列表信息在表里不存在的集合,然后抛出这些不存在的列表信息
// // 提取 existingBeneficiaryBizIds:从 beneficiarys 中获取所有已存在的 beneficiaryBizId 集合
// Set<String> existingBeneficiaryBizIds = beneficiarys.stream()
// .map(Beneficiary::getBeneficiaryBizId)
// .collect(Collectors.toSet());
// // 过滤 list:保留 beneficiaryBizId 不在 existingBeneficiaryBizIds 中的对象
// List<ApiBeneficiaryInfoDto> filteredList = list.stream()
// .filter(dto -> StringUtils.isNotBlank(dto.getBeneficiaryBizId()) && !existingBeneficiaryBizIds.contains(dto.getBeneficiaryBizId()))
// .collect(Collectors.toList());
// if (!CollectionUtils.isEmpty(filteredList)) {
// //入参对象列表中有传值的业务id在库中不存在的对象,提示
// List<String> beneficiaryProductNameList = filteredList
// .stream()
// .map(ApiBeneficiaryInfoDto::getName)
// .collect(Collectors.toList());
// throw new BusinessException("以下是在库里不存在的受益人数据的名字:"+String.join(" ;",beneficiaryProductNameList));
// }
// }
//先删后增加
iBeneficiaryService
.
del
(
appointmentBizId
);
//构造需要新增或者更新数据的对象集合
List
<
Beneficiary
>
updateList
=
list
.
stream
().
map
(
dto
->
{
//新增
List
<
Beneficiary
>
saveList
=
list
.
stream
().
map
(
dto
->
{
Beneficiary
beneficiary
=
new
Beneficiary
();
BeanUtils
.
copyProperties
(
dto
,
beneficiary
);
beneficiary
.
setAppointmentBizId
(
appointmentBizId
);
if
(
StringUtils
.
isBlank
(
dto
.
getBeneficiaryBizId
()))
{
//为空表示新增数据
//生成受益人信息表唯一业务ID
beneficiary
.
setBeneficiaryBizId
(
RandomStringGenerator
.
generateBizId16
(
CommonEnum
.
UID_TYPE_BENEFICIARY
.
getCode
()));
}
//地址列表(json串)
beneficiary
.
setAddressList
(
CommonUtil
.
getAddressListJsonStr
(
dto
.
getAddressList
()));
beneficiary
.
setId
(
null
);
beneficiary
.
setBeneficiaryBizId
(
RandomStringGenerator
.
generateBizId16
(
CommonEnum
.
UID_TYPE_BENEFICIARY
.
getCode
()));
return
beneficiary
;
}).
collect
(
Collectors
.
toList
());
//批量新增或者更新
iBeneficiaryService
.
saveOrUpdateBatch
(
updateList
);
//批量新增
iBeneficiaryService
.
saveOrUpdateBatch
(
saveList
);
return
Result
.
success
();
}
...
...
yd-csf-api/src/main/java/com/yd/csf/api/service/impl/ApiCsfCommonServiceImpl.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
api
.
service
.
impl
;
import
com.yd.common.result.Result
;
import
com.yd.csf.api.service.ApiCsfCommonService
;
import
com.yd.csf.feign.request.common.ApiCsfCalculateRequest
;
import
com.yd.csf.feign.response.common.ApiCsfCalculateResponse
;
import
lombok.extern.slf4j.Slf4j
;
import
net.sourceforge.pinyin4j.PinyinHelper
;
import
net.sourceforge.pinyin4j.format.HanyuPinyinCaseType
;
import
net.sourceforge.pinyin4j.format.HanyuPinyinOutputFormat
;
import
net.sourceforge.pinyin4j.format.HanyuPinyinToneType
;
import
net.sourceforge.pinyin4j.format.exception.BadHanyuPinyinOutputFormatCombination
;
import
org.springframework.beans.BeanUtils
;
import
org.springframework.stereotype.Service
;
import
org.apache.commons.lang3.StringUtils
;
import
java.time.LocalDate
;
import
java.time.Period
;
import
java.time.format.DateTimeFormatter
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.regex.Pattern
;
@Slf4j
@Service
public
class
ApiCsfCommonServiceImpl
implements
ApiCsfCommonService
{
// 身份证号码正则表达式(15位或18位)
private
static
final
Pattern
ID_CARD_PATTERN
=
Pattern
.
compile
(
"(^\\d{15}$)|(^\\d{17}([0-9]|X|x)$)"
);
// 日期格式
private
static
final
DateTimeFormatter
DATE_FORMATTER
=
DateTimeFormatter
.
ofPattern
(
"yyyy-MM-dd"
);
/**
* 计算-字段值
* @param request
* @return
*/
@Override
public
Result
<
List
<
ApiCsfCalculateResponse
>>
calculate
(
ApiCsfCalculateRequest
request
)
{
List
<
ApiCsfCalculateResponse
>
responses
=
new
ArrayList
<>();
try
{
// 参数校验
if
(
request
==
null
)
{
return
Result
.
fail
(
"请求参数不能为空"
);
}
if
(
request
.
getCalculateType
()
==
null
)
{
return
Result
.
fail
(
"计算类型不能为空"
);
}
// 创建响应对象
ApiCsfCalculateResponse
response
=
new
ApiCsfCalculateResponse
();
response
.
setCalculateType
(
request
.
getCalculateType
());
response
.
setRequestValue
(
request
.
getRequestValue
());
response
.
setRequestValueList
(
request
.
getRequestValueList
());
String
result
;
switch
(
request
.
getCalculateType
())
{
case
1
:
// 1-通过中文自动加载全部大写的拼音
result
=
calculatePinyin
(
request
.
getRequestValue
());
response
.
setResponseValue
(
result
);
responses
.
add
(
response
);
break
;
case
2
:
// 2-身份证号码计算性别
result
=
calculateGenderFromIdCard
(
request
.
getRequestValue
());
response
.
setResponseValue
(
result
);
responses
.
add
(
response
);
break
;
case
3
:
// 3-身份证号码计算生日
result
=
calculateBirthdayFromIdCard
(
request
.
getRequestValue
());
response
.
setResponseValue
(
result
);
responses
.
add
(
response
);
break
;
case
4
:
// 4-生日计算年龄
result
=
calculateAgeFromBirthday
(
request
.
getRequestValue
());
response
.
setResponseValue
(
result
);
responses
.
add
(
response
);
break
;
case
5
:
// 5-身高和体重计算BMI指数
result
=
calculateBMI
(
request
.
getRequestValueList
());
response
.
setResponseValue
(
result
);
responses
.
add
(
response
);
break
;
case
6
:
// 6-身份证号码计算性别/生日/年龄
//性别
ApiCsfCalculateResponse
response1
=
new
ApiCsfCalculateResponse
();
//生日
ApiCsfCalculateResponse
response2
=
new
ApiCsfCalculateResponse
();
//年龄
ApiCsfCalculateResponse
response3
=
new
ApiCsfCalculateResponse
();
BeanUtils
.
copyProperties
(
request
,
response1
);
response1
.
setCalculateType
(
2
);
response1
.
setRequestValue
(
calculateGenderFromIdCard
(
request
.
getRequestValue
()));
responses
.
add
(
response1
);
BeanUtils
.
copyProperties
(
request
,
response2
);
response2
.
setCalculateType
(
3
);
response2
.
setRequestValue
(
calculateBirthdayFromIdCard
(
request
.
getRequestValue
()));
responses
.
add
(
response2
);
BeanUtils
.
copyProperties
(
request
,
response3
);
response3
.
setCalculateType
(
4
);
response3
.
setRequestValue
(
calculateAgeFromBirthday
(
request
.
getRequestValue
()));
responses
.
add
(
response3
);
break
;
default
:
return
Result
.
fail
(
"不支持的计算类型: "
+
request
.
getCalculateType
());
}
return
Result
.
success
(
responses
);
}
catch
(
Exception
e
)
{
log
.
error
(
"计算服务异常: "
,
e
);
return
Result
.
fail
(
"计算失败: "
+
e
.
getMessage
());
}
}
/**
* 通过中文自动加载全部大写的拼音
* @param chinese
* @return
*/
private
String
calculatePinyin
(
String
chinese
)
{
if
(
StringUtils
.
isBlank
(
chinese
))
{
throw
new
IllegalArgumentException
(
"中文内容不能为空"
);
}
// 中文转拼音
return
convertChineseToPinyin
(
chinese
).
toUpperCase
();
}
/**
* 身份证号码计算性别
* @param idCard
* @return
*/
private
String
calculateGenderFromIdCard
(
String
idCard
)
{
if
(
StringUtils
.
isBlank
(
idCard
))
{
throw
new
IllegalArgumentException
(
"身份证号码不能为空"
);
}
if
(!
ID_CARD_PATTERN
.
matcher
(
idCard
).
matches
())
{
throw
new
IllegalArgumentException
(
"身份证号码格式不正确"
);
}
// 获取性别位
String
genderCode
;
if
(
idCard
.
length
()
==
15
)
{
// 15位身份证:最后一位是性别位(奇数为男,偶数为女)
genderCode
=
idCard
.
substring
(
14
,
15
);
}
else
{
// 18位身份证:倒数第二位是性别位(奇数为男,偶数为女)
genderCode
=
idCard
.
substring
(
16
,
17
);
}
int
code
=
Integer
.
parseInt
(
genderCode
);
return
code
%
2
==
1
?
"男"
:
"女"
;
}
/**
* 身份证号码计算生日
* @param idCard
* @return
*/
private
String
calculateBirthdayFromIdCard
(
String
idCard
)
{
if
(
StringUtils
.
isBlank
(
idCard
))
{
throw
new
IllegalArgumentException
(
"身份证号码不能为空"
);
}
if
(!
ID_CARD_PATTERN
.
matcher
(
idCard
).
matches
())
{
throw
new
IllegalArgumentException
(
"身份证号码格式不正确"
);
}
String
birthdayStr
;
if
(
idCard
.
length
()
==
15
)
{
// 15位身份证:第7-12位是生日(yyMMdd)
birthdayStr
=
"19"
+
idCard
.
substring
(
6
,
12
);
}
else
{
// 18位身份证:第7-14位是生日(yyyyMMdd)
birthdayStr
=
idCard
.
substring
(
6
,
14
);
}
// 格式化为yyyy-MM-dd
try
{
LocalDate
birthday
=
LocalDate
.
parse
(
birthdayStr
,
DateTimeFormatter
.
ofPattern
(
"yyyyMMdd"
));
return
birthday
.
format
(
DATE_FORMATTER
);
}
catch
(
Exception
e
)
{
throw
new
IllegalArgumentException
(
"身份证生日信息异常: "
+
birthdayStr
);
}
}
/**
* 生日计算年龄
* @param birthday
* @return
*/
private
String
calculateAgeFromBirthday
(
String
birthday
)
{
if
(
StringUtils
.
isBlank
(
birthday
))
{
throw
new
IllegalArgumentException
(
"生日不能为空"
);
}
try
{
LocalDate
birthDate
=
LocalDate
.
parse
(
birthday
,
DATE_FORMATTER
);
LocalDate
currentDate
=
LocalDate
.
now
();
if
(
birthDate
.
isAfter
(
currentDate
))
{
throw
new
IllegalArgumentException
(
"生日日期不能晚于当前日期"
);
}
Period
period
=
Period
.
between
(
birthDate
,
currentDate
);
return
String
.
valueOf
(
period
.
getYears
());
}
catch
(
Exception
e
)
{
throw
new
IllegalArgumentException
(
"生日格式不正确,应为yyyy-MM-dd格式"
);
}
}
/**
* 身高和体重计算BMI指数
* @param requestValueList
* @return
*/
private
String
calculateBMI
(
List
<
String
>
requestValueList
)
{
if
(
requestValueList
==
null
||
requestValueList
.
size
()
<
2
)
{
throw
new
IllegalArgumentException
(
"身高和体重参数不能为空"
);
}
try
{
// 身高(米)和体重(千克)
double
height
=
Double
.
parseDouble
(
requestValueList
.
get
(
0
));
double
weight
=
Double
.
parseDouble
(
requestValueList
.
get
(
1
));
if
(
height
<=
0
||
weight
<=
0
)
{
throw
new
IllegalArgumentException
(
"身高和体重必须为正数"
);
}
if
(
height
>
3
)
{
// 如果身高输入的是厘米,转换为米
height
=
height
/
100
;
}
double
bmi
=
weight
/
(
height
*
height
);
// 保留两位小数
return
String
.
format
(
"%.2f"
,
bmi
);
}
catch
(
NumberFormatException
e
)
{
throw
new
IllegalArgumentException
(
"身高和体重必须是有效数字"
);
}
}
/**
* 中文转拼音辅助方法
* @param chinese
* @return
*/
private
String
convertChineseToPinyin
(
String
chinese
)
{
HanyuPinyinOutputFormat
format
=
new
HanyuPinyinOutputFormat
();
format
.
setCaseType
(
HanyuPinyinCaseType
.
UPPERCASE
);
format
.
setToneType
(
HanyuPinyinToneType
.
WITHOUT_TONE
);
StringBuilder
pinyin
=
new
StringBuilder
();
for
(
char
c
:
chinese
.
toCharArray
())
{
if
(
Character
.
toString
(
c
).
matches
(
"[\\u4E00-\\u9FA5]"
))
{
try
{
String
[]
pinyinArray
=
PinyinHelper
.
toHanyuPinyinStringArray
(
c
,
format
);
if
(
pinyinArray
!=
null
&&
pinyinArray
.
length
>
0
)
{
pinyin
.
append
(
pinyinArray
[
0
]);
}
}
catch
(
BadHanyuPinyinOutputFormatCombination
e
)
{
pinyin
.
append
(
c
);
}
}
else
{
pinyin
.
append
(
c
);
}
}
return
pinyin
.
toString
();
}
}
yd-csf-api/src/main/java/com/yd/csf/api/service/impl/ApiInsurantServiceImpl.java
View file @
7b943b2c
...
...
@@ -9,10 +9,13 @@ import com.yd.csf.api.service.ApiAppointmentCheckService;
import
com.yd.csf.api.service.ApiInsurantService
;
import
com.yd.csf.feign.dto.appointment.ApiInsurantInfoDto
;
import
com.yd.csf.feign.utils.CommonUtil
;
import
com.yd.csf.feign.enums.RelTypeEnum
;
import
com.yd.csf.service.model.Insurant
;
import
com.yd.csf.service.model.Policyholder
;
import
com.yd.csf.service.service.IInsurantService
;
import
com.yd.csf.service.service.IPolicyholderService
;
import
lombok.extern.slf4j.Slf4j
;
import
org.apache.commons.lang3.StringUtils
;
import
org.springframework.beans.BeanUtils
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
...
...
@@ -29,6 +32,9 @@ public class ApiInsurantServiceImpl implements ApiInsurantService {
private
IInsurantService
iInsurantService
;
@Autowired
private
IPolicyholderService
iPolicyholderService
;
@Autowired
private
ApiAppointmentCheckService
apiAppointmentCheckService
;
/**
...
...
@@ -61,7 +67,7 @@ public class ApiInsurantServiceImpl implements ApiInsurantService {
apiAppointmentCheckService
.
checkEditApiInsurantInfoDto
(
apiInsurantInfoDto
);
//编辑受保人信息表数据
editInsurantData
(
apiInsurantInfoDto
,
apiInsurantInfoDto
.
getAppointmentBizId
());
//
editInsurantData(apiInsurantInfoDto,apiInsurantInfoDto.getAppointmentBizId());
return
Result
.
success
();
}
...
...
@@ -77,8 +83,21 @@ public class ApiInsurantServiceImpl implements ApiInsurantService {
//为空设置,方便新建暂存公用方法
dto
=
new
ApiInsurantInfoDto
();
}
//受保人信息信息
Insurant
insurant
=
new
Insurant
();
//与投保人关系
if
(
RelTypeEnum
.
MYSELF
.
getItemValue
().
equals
(
dto
.
getPolicyholderRel
()))
{
//与投保人关系如果是本人,直接查询投保人信息表新增数据到受保人信息表中
Policyholder
policyholder
=
iPolicyholderService
.
queryOne
(
appointmentBizId
,
""
);
if
(!
Objects
.
isNull
(
policyholder
))
{
BeanUtils
.
copyProperties
(
policyholder
,
insurant
);
insurant
.
setId
(
null
);
insurant
.
setAppointmentBizId
(
appointmentBizId
);
insurant
.
setInsurantBizId
(
RandomStringGenerator
.
generateBizId16
(
CommonEnum
.
UID_TYPE_INSURANT
.
getCode
()));
iInsurantService
.
saveOrUpdate
(
insurant
);
return
Result
.
success
(
insurant
);
}
}
//受保人信息信息
BeanUtils
.
copyProperties
(
dto
,
insurant
);
//生成受保人信息表唯一业务ID
insurant
.
setInsurantBizId
(
RandomStringGenerator
.
generateBizId16
(
CommonEnum
.
UID_TYPE_INSURANT
.
getCode
()));
...
...
@@ -102,10 +121,26 @@ public class ApiInsurantServiceImpl implements ApiInsurantService {
//受保人信息对象不能为空
throw
new
BusinessException
(
"受保人信息不能为空"
);
}
if
(
StringUtils
.
isBlank
(
dto
.
getInsurantBizId
()))
{
throw
new
BusinessException
(
"受保人信息表唯一业务ID不能为空"
);
}
Result
<
Insurant
>
result
=
checkInsurantIsExist
(
dto
.
getInsurantBizId
());
//受保人信息信息
Insurant
insurant
=
result
.
getData
();
//与投保人关系
if
(
RelTypeEnum
.
MYSELF
.
getItemValue
().
equals
(
dto
.
getPolicyholderRel
()))
{
//与投保人关系如果是本人,直接查询投保人信息表更新数据到受保人信息表中
Policyholder
policyholder
=
iPolicyholderService
.
queryOne
(
appointmentBizId
,
""
);
if
(!
Objects
.
isNull
(
policyholder
))
{
BeanUtils
.
copyProperties
(
policyholder
,
insurant
);
insurant
.
setId
(
result
.
getData
().
getId
());
insurant
.
setAppointmentBizId
(
appointmentBizId
);
iInsurantService
.
saveOrUpdate
(
insurant
);
return
Result
.
success
(
insurant
);
}
}
BeanUtils
.
copyProperties
(
dto
,
insurant
);
//预约信息主表唯一业务ID
insurant
.
setAppointmentBizId
(
appointmentBizId
);
...
...
yd-csf-api/src/main/java/com/yd/csf/api/service/impl/ApiPolicyholderServiceImpl.java
View file @
7b943b2c
...
...
@@ -12,6 +12,7 @@ import com.yd.csf.feign.utils.CommonUtil;
import
com.yd.csf.service.model.Policyholder
;
import
com.yd.csf.service.service.IPolicyholderService
;
import
lombok.extern.slf4j.Slf4j
;
import
org.apache.commons.lang3.StringUtils
;
import
org.springframework.beans.BeanUtils
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
...
...
@@ -60,7 +61,7 @@ public class ApiPolicyholderServiceImpl implements ApiPolicyholderService {
//编辑预约入参字段校验 - 投保人信息字段校验
apiAppointmentCheckService
.
checkEditApiPolicyholderInfoDto
(
apiPolicyholderInfoDto
);
//编辑投保人信息表数据
editPolicyholderData
(
apiPolicyholderInfoDto
,
apiPolicyholderInfoDto
.
getAppointmentBizId
());
//
editPolicyholderData(apiPolicyholderInfoDto,apiPolicyholderInfoDto.getAppointmentBizId());
return
Result
.
success
();
}
...
...
@@ -101,6 +102,9 @@ public class ApiPolicyholderServiceImpl implements ApiPolicyholderService {
//投保人信息对象不能为空
throw
new
BusinessException
(
"投保人信息对象不能为空"
);
}
if
(
StringUtils
.
isBlank
(
dto
.
getPolicyholderBizId
()))
{
throw
new
BusinessException
(
"投保人信息表唯一业务ID不能为空"
);
}
//校验投保人信息是否存在
Result
<
Policyholder
>
result
=
checkPolicyholderIsExist
(
dto
.
getPolicyholderBizId
());
Policyholder
policyholder
=
result
.
getData
();
...
...
yd-csf-api/src/main/java/com/yd/csf/api/service/impl/ApiProductPlanServiceImpl.java
View file @
7b943b2c
...
...
@@ -14,6 +14,7 @@ import com.yd.csf.feign.dto.appointment.ApiProductPlanMainInfoDto;
import
com.yd.csf.service.model.ProductPlan
;
import
com.yd.csf.service.service.IProductPlanService
;
import
lombok.extern.slf4j.Slf4j
;
import
org.apache.commons.lang3.StringUtils
;
import
org.springframework.beans.BeanUtils
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
...
...
@@ -85,11 +86,11 @@ public class ApiProductPlanServiceImpl implements ApiProductPlanService {
ApiProductPlanInfoDto
productPlanInfoDto
=
new
ApiProductPlanInfoDto
();
productPlanInfoDto
.
setApiProductPlanMainInfoDto
(
apiProductPlanMainInfoDto
);
Result
<
ProductPlan
>
result
=
editProductPlanData
(
productPlanInfoDto
,
apiProductPlanMainInfoDto
.
getAppointmentBizId
());
//
Result<ProductPlan> result = editProductPlanData(productPlanInfoDto,apiProductPlanMainInfoDto.getAppointmentBizId());
String
planBizId
=
""
;
if
(!
Objects
.
isNull
(
result
.
getData
()))
{
planBizId
=
result
.
getData
().
getPlanBizId
();
}
//
if (!Objects.isNull(result.getData())) {
//
planBizId = result.getData().getPlanBizId();
//
}
return
Result
.
success
(
planBizId
);
}
...
...
@@ -147,6 +148,12 @@ public class ApiProductPlanServiceImpl implements ApiProductPlanService {
//不能为空
throw
new
BusinessException
(
"产品计划主信息对象不能为空"
);
}
if
(!
Objects
.
isNull
(
productPlanInfoDto
)
&&
!
Objects
.
isNull
(
productPlanInfoDto
.
getApiProductPlanMainInfoDto
())
&&
StringUtils
.
isNotBlank
(
productPlanInfoDto
.
getApiProductPlanMainInfoDto
().
getPlanBizId
())){
//不能为空
throw
new
BusinessException
(
"产品计划信息表唯一业务ID不能为空"
);
}
//产品计划主信息
ApiProductPlanMainInfoDto
dto
=
productPlanInfoDto
.
getApiProductPlanMainInfoDto
();
Result
<
ProductPlan
>
result
=
checkProductPlanIsExist
(
dto
.
getPlanBizId
());
...
...
yd-csf-api/src/main/java/com/yd/csf/api/service/impl/ApiSecondHolderServiceImpl.java
View file @
7b943b2c
...
...
@@ -60,7 +60,7 @@ public class ApiSecondHolderServiceImpl implements ApiSecondHolderService {
if
(
Objects
.
isNull
(
apiSecondHolderInfoDto
))
{
apiSecondHolderInfoDto
=
new
ApiSecondHolderInfoDto
();
}
editSecondHolderData
(
apiSecondHolderInfoDto
,
apiSecondHolderInfoDto
.
getAppointmentBizId
());
//
editSecondHolderData(apiSecondHolderInfoDto,apiSecondHolderInfoDto.getAppointmentBizId());
return
Result
.
success
();
}
...
...
yd-csf-feign/pom.xml
View file @
7b943b2c
...
...
@@ -41,5 +41,11 @@
<artifactId>
yd-user-feign
</artifactId>
<version>
${project.version}
</version>
</dependency>
<dependency>
<groupId>
com.yd
</groupId>
<artifactId>
yd-base-feign
</artifactId>
<version>
${project.version}
</version>
</dependency>
</dependencies>
</project>
yd-csf-feign/src/main/java/com/yd/csf/feign/client/appointment/ApiAppointmentFeignClient.java
View file @
7b943b2c
...
...
@@ -7,6 +7,7 @@ import com.yd.csf.feign.fallback.appointment.ApiAppointmentFeignFallbackFactory;
import
com.yd.csf.feign.request.appointment.*
;
import
com.yd.csf.feign.response.appointment.ApiAppointmentAddResponse
;
import
com.yd.csf.feign.response.appointment.ApiAppointmentDetailResponse
;
import
com.yd.csf.feign.response.appointment.ApiAppointmentLogDetailResponse
;
import
org.springframework.cloud.openfeign.FeignClient
;
import
org.springframework.validation.annotation.Validated
;
import
org.springframework.web.bind.annotation.*
;
...
...
@@ -57,7 +58,7 @@ public interface ApiAppointmentFeignClient {
* @return
*/
@PostMapping
(
"/add/storage"
)
Result
addStorage
(
@
Validated
@
RequestBody
ApiAppointmentAddStorageRequest
request
);
Result
addStorage
(
@RequestBody
ApiAppointmentAddStorageRequest
request
);
/**
* 编辑预约提交 (聚合信息编辑预约提交)
...
...
@@ -68,6 +69,14 @@ public interface ApiAppointmentFeignClient {
Result
edit
(
@Validated
@RequestBody
ApiAppointmentEditRequest
request
);
/**
* 编辑预约暂存 (聚合信息编辑预约暂存)
* @param request
* @return
*/
@PutMapping
(
"/edit/storage"
)
Result
editStorage
(
@RequestBody
ApiAppointmentEditStorageRequest
request
);
/**
* 确定预约时间提交 (流程流转到新单跟进)
* @param request
* @return
...
...
@@ -124,10 +133,35 @@ public interface ApiAppointmentFeignClient {
Result
editPolicyTransfer
(
@Validated
@RequestBody
ApiPolicyTransferRequest
request
);
/**
* 编辑预约状态
* @param request
* @return
*/
@PutMapping
(
"/edit/status"
)
Result
editStatus
(
@Validated
@RequestBody
ApiAppointmentEditStatusRequest
request
);
/**
* 删除预约信息
* @param appointmentBizId
* @return
*/
@DeleteMapping
(
"/del"
)
Result
del
(
@NotBlank
(
message
=
"预约信息主表唯一业务ID不能为空"
)
@RequestParam
(
value
=
"appointmentBizId"
)
String
appointmentBizId
);
/**
* 历史记录 - 签约信息
* @param request
* @return
*/
@PostMapping
(
"/log/page"
)
Result
logPage
(
@Validated
@RequestBody
ApiAppointmentLogPageRequest
request
);
/**
* 历史记录 - 签约信息 - 详情
* @param appointmentLogBizId
* @return
*/
@GetMapping
(
"/log/detail"
)
Result
<
ApiAppointmentLogDetailResponse
>
logDetail
(
@NotBlank
(
message
=
"预约信息日志表唯一业务ID不能为空"
)
@RequestParam
(
value
=
"appointmentLogBizId"
)
String
appointmentLogBizId
);
}
yd-csf-feign/src/main/java/com/yd/csf/feign/client/common/ApiCsfCommonFeignClient.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
feign
.
client
.
common
;
import
com.yd.common.result.Result
;
import
com.yd.csf.feign.fallback.common.ApiCsfCommonFeignFallbackFactory
;
import
com.yd.csf.feign.request.common.ApiCsfCalculateRequest
;
import
com.yd.csf.feign.response.common.ApiCsfCalculateResponse
;
import
org.springframework.cloud.openfeign.FeignClient
;
import
org.springframework.validation.annotation.Validated
;
import
org.springframework.web.bind.annotation.PostMapping
;
import
org.springframework.web.bind.annotation.RequestBody
;
import
java.util.List
;
/**
* 香港保险服务-公共接口信息Feign客户端
*/
@FeignClient
(
name
=
"yd-csf-api"
,
fallbackFactory
=
ApiCsfCommonFeignFallbackFactory
.
class
)
public
interface
ApiCsfCommonFeignClient
{
/**
* 计算-字段值
* @param request
* @return
*/
@PostMapping
(
"/calculate/fieldValue"
)
Result
<
List
<
ApiCsfCalculateResponse
>>
calculate
(
@Validated
@RequestBody
ApiCsfCalculateRequest
request
);
}
yd-csf-feign/src/main/java/com/yd/csf/feign/dto/appointment/ApiAppointmentInfoDto.java
View file @
7b943b2c
...
...
@@ -2,7 +2,11 @@ package com.yd.csf.feign.dto.appointment;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
lombok.Data
;
import
javax.validation.constraints.NotBlank
;
import
javax.validation.constraints.NotNull
;
import
java.time.LocalDateTime
;
import
java.util.List
;
/**
* 预约信息
...
...
@@ -11,38 +15,37 @@ import java.time.LocalDateTime;
public
class
ApiAppointmentInfoDto
{
/**
* 预约信息表主键id(新增不需要传值,修改需要传值)
*/
private
Long
id
;
/**
* 预约信息主表唯一业务ID(新增不需要传值,修改需要传值)
*/
private
String
appointmentBizId
;
/**
* 预约编号
(和预约信息主表唯一业务ID是一对,唯一,冗余字段)
* 预约编号
*/
private
String
appointmentNo
;
/**
* 关联客户信息表唯一业务ID(冗余字段)
*/
@NotBlank
(
message
=
"关联客户信息表唯一业务ID不能为空"
)
private
String
customerBizId
;
/**
* 关联客户编号(和客户信息表唯一业务ID是一对,唯一,冗余字段)
*/
@NotBlank
(
message
=
"关联客户编号不能为空"
)
private
String
customerNo
;
/**
* 关联FNA信息表唯一业务ID(冗余字段)
*/
@NotBlank
(
message
=
"关联FNA信息表唯一业务ID不能为空"
)
private
String
fnaBizId
;
/**
* 关联FNA编号(和FNA信息表唯一业务ID是一对,唯一,冗余字段)
*/
@NotBlank
(
message
=
"关联FNA编号不能为空"
)
private
String
fnaNo
;
/**
...
...
@@ -58,51 +61,15 @@ public class ApiAppointmentInfoDto {
/**
* 申请类型(字典)
*/
//
@NotBlank(message = "申请类型不能为空")
@NotBlank
(
message
=
"申请类型不能为空"
)
private
String
applyType
;
/**
* 业务编号
*/
private
String
businessNo
;
/**
* 确定预约时间
*/
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
)
private
LocalDateTime
confirmAppointmentTime
;
/**
* 意向预约时间
* 签单日
*/
// @NotNull(message = "意向预约时间
不能为空")
@NotNull
(
message
=
"签单日
不能为空"
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
)
private
LocalDateTime
intentionAppointmentTime
;
/**
* 顾问是否陪同: 0-否, 1-是(字典)
*/
private
Integer
isAccompany
;
/**
* 陪同顾问姓名(FNA Form有填写,可带入)
*/
private
String
accompanyName
;
/**
* 陪同顾问手机区号
*/
private
String
accompanyMobileCode
;
/**
* 陪同顾问手机
*/
private
String
accompanyMobile
;
/**
* 陪同顾问邮箱
*/
private
String
accompanyEmail
;
private
LocalDateTime
signDate
;
/**
* 到港时间
...
...
@@ -122,7 +89,7 @@ public class ApiAppointmentInfoDto {
private
String
meetingPoint
;
/**
* 签单地址
* 签单地址
(签单地点)
*/
private
String
signingAddress
;
...
...
@@ -189,37 +156,28 @@ public class ApiAppointmentInfoDto {
private
String
policyTransfer
;
/**
* 业务代表1账号
*/
private
String
businessRepresentAccount1
;
/**
* 业务代表1姓名
*/
private
String
businessRepresentName1
;
/**
* 业务代表1电话号码区号
* 是否有用车服务:0-否, 1-是(字典)
*/
private
String
businessRepresentMobile1Code
;
private
Integer
isUseCar
;
/**
*
业务代表1电话号码
*
是否法定受益人
*/
private
String
businessRepresentMobile1
;
@NotBlank
(
message
=
"是否法定受益人不能为空"
)
private
String
isLegalBeneficiary
;
/**
*
业务代表1邮箱
*
创建人用户名
*/
private
String
businessRepresentEmail1
;
private
String
creatorName
;
/**
*
是否有用车服务:0-否, 1-是(字典)
*
陪同转介人信息列表
*/
private
Integer
isUseCar
;
private
List
<
ApiAppointmentReferrerDto
>
referrerDtoList
;
/**
*
创建人用户名
*
签单员信息列表
*/
private
String
creatorName
;
private
List
<
ApiAppointmentUserSignDto
>
userSignDtoList
;
}
yd-csf-feign/src/main/java/com/yd/csf/feign/dto/appointment/ApiAppointmentReferrerDto.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
feign
.
dto
.
appointment
;
import
lombok.Data
;
@Data
public
class
ApiAppointmentReferrerDto
{
/**
* 系统用户-销售用户扩展表唯一业务ID(转介人,冗余)
*/
private
String
userSaleBizId
;
/**
* 系统用户唯一业务ID(冗余)
*/
private
String
userBizId
;
/**
* 姓名
*/
private
String
realName
;
/**
* 手机号
*/
private
String
phone
;
/**
* 邮箱
*/
private
String
email
;
}
yd-csf-feign/src/main/java/com/yd/csf/feign/dto/appointment/ApiAppointmentReferrerLogDto.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
feign
.
dto
.
appointment
;
import
lombok.Data
;
import
java.time.LocalDateTime
;
@Data
public
class
ApiAppointmentReferrerLogDto
{
/**
* 预约-转介人信息日志表主键ID
*/
private
Long
id
;
/**
* 预约-转介人信息日志表唯一业务ID
*/
private
String
appointmentReferrerLogBizId
;
/**
* 预约信息日志表唯一业务ID
*/
private
String
appointmentLogBizId
;
/**
* 系统用户-销售用户扩展表唯一业务ID(转介人,冗余)
*/
private
String
userSaleBizId
;
/**
* 系统用户唯一业务ID(冗余)
*/
private
String
userBizId
;
/**
* 姓名
*/
private
String
realName
;
/**
* 手机号
*/
private
String
phone
;
/**
* 邮箱
*/
private
String
email
;
/**
* 通用备注
*/
private
String
remark
;
/**
* 删除标识: 0-正常, 1-删除
*/
private
Integer
isDeleted
;
/**
* 创建人ID
*/
private
String
creatorId
;
/**
* 更新人ID
*/
private
String
updaterId
;
/**
* 创建时间
*/
private
LocalDateTime
createTime
;
/**
* 更新时间
*/
private
LocalDateTime
updateTime
;
}
yd-csf-feign/src/main/java/com/yd/csf/feign/dto/appointment/ApiAppointmentUserSignDto.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
feign
.
dto
.
appointment
;
import
lombok.Data
;
@Data
public
class
ApiAppointmentUserSignDto
{
/**
* 签单用户扩展唯一业务ID(冗余)
*/
private
String
userSignBizId
;
/**
* 系统用户唯一业务ID(冗余)
*/
private
String
userBizId
;
/**
* 姓名
*/
private
String
realName
;
/**
* 执业编码
*/
private
String
practiceCode
;
/**
* 手机号
*/
private
String
phone
;
/**
* 证件类型
*/
private
String
cardType
;
/**
* 证件号码
*/
private
String
cardNo
;
/**
* 邮箱
*/
private
String
email
;
}
yd-csf-feign/src/main/java/com/yd/csf/feign/dto/appointment/ApiAppointmentUserSignLogDto.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
feign
.
dto
.
appointment
;
import
lombok.Data
;
import
java.time.LocalDateTime
;
@Data
public
class
ApiAppointmentUserSignLogDto
{
/**
* 预约-签单员信息日志表主键ID
*/
private
Long
id
;
/**
* 预约-签单员信息日志表唯一业务ID
*/
private
String
appointmentUserSignLogBizId
;
/**
* 预约信息日志表唯一业务ID
*/
private
String
appointmentLogBizId
;
/**
* 签单用户扩展唯一业务ID(冗余)
*/
private
String
userSignBizId
;
/**
* 系统用户唯一业务ID(冗余)
*/
private
String
userBizId
;
/**
* 姓名
*/
private
String
realName
;
/**
* 执业编码
*/
private
String
practiceCode
;
/**
* 手机号
*/
private
String
phone
;
/**
* 证件类型
*/
private
String
cardType
;
/**
* 证件号码
*/
private
String
cardNo
;
/**
* 邮箱
*/
private
String
email
;
/**
* 通用备注
*/
private
String
remark
;
/**
* 删除标识: 0-正常, 1-删除
*/
private
Integer
isDeleted
;
/**
* 创建人ID
*/
private
String
creatorId
;
/**
* 更新人ID
*/
private
String
updaterId
;
/**
* 创建时间
*/
private
LocalDateTime
createTime
;
/**
* 更新时间
*/
private
LocalDateTime
updateTime
;
}
yd-csf-feign/src/main/java/com/yd/csf/feign/dto/appointment/ApiBeneficiaryInfoDto.java
View file @
7b943b2c
package
com
.
yd
.
csf
.
feign
.
dto
.
appointment
;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
com.yd.csf.feign.dto.AddressDto
;
import
lombok.Data
;
import
javax.validation.constraints.NotBlank
;
import
java.math.BigDecimal
;
import
java.time.LocalDateTime
;
import
java.util.List
;
/**
* 受益人信息
...
...
@@ -16,54 +12,37 @@ import java.util.List;
public
class
ApiBeneficiaryInfoDto
{
/**
* 受益人信息
主键id(新增不需要传值,修改需要传值)
* 受益人信息
表主键ID
*/
private
Long
id
;
/**
* 预约信息主表唯一业务ID
(新增不需要传值,修改需要传值)
* 预约信息主表唯一业务ID
*/
private
String
appointmentBizId
;
/**
* 受益人信息表唯一业务ID
(新增不需要传值,修改需要传值)
* 受益人信息表唯一业务ID
*/
private
String
beneficiaryBizId
;
/**
* 客户类型(字典)(个人或者公司)
*/
// @NotBlank(message = "客户类型不能为空")
private
String
customerType
;
/**
* 与受保人关系(字典)
*/
// @NotBlank(message = "与受保人关系不能为空")
private
String
insurantRel
;
/**
* 受益比例
*/
private
BigDecimal
benefitRatio
;
/**
* 名字
*/
private
String
name
;
/**
* 名字-英文
* 姓名-中文
*/
private
String
name
E
n
;
private
String
name
C
n
;
/**
*
性别(字典
)
*
姓名-(拼音/英文,通过中文自动加载全部大写的拼音
)
*/
private
String
gender
;
private
String
namePyEn
;
/**
* 证件类型(字典)
* 证件类型(字典
,下拉选择
)
*/
private
String
documentType
;
...
...
@@ -73,99 +52,24 @@ public class ApiBeneficiaryInfoDto {
private
String
idNumber
;
/**
* 护照号码
*/
private
String
passportNumber
;
/**
* 出生日期
* 性别(字典,如果是身份证,自动获取性别和生日)
*/
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
)
private
LocalDateTime
birthTime
;
/**
* 公司名称
*/
private
String
companyName
;
/**
* 公司名称(英文)
*/
private
String
companyNameEn
;
/**
* 公司商业登记号码
*/
private
String
companyBusinessNo
;
private
String
gender
;
/**
*
公司注册日期
*
出生日期(生日,如果是身份证,自动获取性别和生日)
*/
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
)
private
LocalDateTime
companyRegisterTime
;
private
LocalDateTime
birthday
;
/**
*
公司注册地区(字典
)
*
国籍(下拉选择
)
*/
private
String
companyRegisterRegion
;
private
String
nationality
;
/**
* 公司电话区号
*/
private
String
companyMobileCode
;
/**
* 公司电话
*/
private
String
companyMobile
;
/**
* 公司邮箱
*/
private
String
companyEmail
;
/**
* 公司登记地址
*/
private
String
companyEnterAddress
;
/**
* 通讯地址
*/
private
String
mailingAddress
;
/**
* 授权代表姓名中文-名字
*/
private
String
authNameCn
;
/**
* 授权代表姓名英文-名字
*/
private
String
authNameEn
;
/**
* 授权代表职称
*/
private
String
authProfessional
;
/**
* 授权代表电话区号
*/
private
String
authMobileCode
;
/**
* 授权代表电话
*/
private
String
authMobile
;
/**
* 地址列表
* 受益比例
*/
private
List
<
AddressDto
>
addressList
;
private
BigDecimal
benefitRatio
;
/**
* 备注
*/
private
String
remark
;
}
yd-csf-feign/src/main/java/com/yd/csf/feign/dto/appointment/ApiInsurantInfoDto.java
View file @
7b943b2c
...
...
@@ -2,11 +2,17 @@ package com.yd.csf.feign.dto.appointment;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
com.yd.csf.feign.dto.AddressDto
;
import
com.yd.csf.feign.dto.taxation.ApiTaxationDto
;
import
com.yd.csf.feign.enums.RelTypeEnum
;
import
com.yd.csf.feign.valid.GroupValid
;
import
lombok.Data
;
import
javax.validation.constraints.AssertTrue
;
import
javax.validation.constraints.NotBlank
;
import
javax.validation.constraints.NotNull
;
import
javax.validation.constraints.Pattern
;
import
java.math.BigDecimal
;
import
java.time.LocalDateTime
;
import
java.time.Period
;
import
java.util.List
;
/**
...
...
@@ -16,257 +22,248 @@ import java.util.List;
public
class
ApiInsurantInfoDto
{
/**
* 受保人信息表主键id(新增不需要传值,修改需要传值)
*/
private
Long
id
;
/**
* 预约信息主表唯一业务ID(新增不需要传值,修改需要传值)
*/
private
String
appointmentBizId
;
/**
* 受保人信息表唯一业务ID(新增不需要传值,修改需要传值)
* 受保人信息表唯一业务ID
*/
private
String
insurantBizId
;
/**
* 客户类型(字典)
*/
// @NotBlank(message = "客户类型不能为空")
private
String
customerType
;
/**
* 关联客户信息表唯一业务ID(冗余字段)
*/
@NotBlank
(
message
=
"关联客户信息表唯一业务ID不能为空"
,
groups
=
GroupValid
.
NotSelf
.
class
)
private
String
customerBizId
;
/**
* 关联客户编号(和客户信息表唯一业务ID是一对,唯一,冗余字段)
*/
@NotBlank
(
message
=
"关联客户编号不能为空"
,
groups
=
GroupValid
.
NotSelf
.
class
)
private
String
customerNo
;
/**
* 与投保人关系(字典)
*/
// @NotBlank(message = "与投保人关系不能为空"
)
@NotBlank
(
message
=
"与投保人关系不能为空"
,
groups
=
GroupValid
.
Always
.
class
)
private
String
policyholderRel
;
//-- 以下基础信息
/**
* 名字
*/
private
String
name
;
/**
* 名字-英文
* 姓名-中文
*/
private
String
nameEn
;
@NotBlank
(
message
=
"姓名(中文)不能为空"
,
groups
=
GroupValid
.
NotSelf
.
class
)
@Pattern
(
regexp
=
"^[\u4e00-\u9fa5]{2,6}$"
,
message
=
"姓名(中文)必须为2-6位汉字"
,
groups
=
GroupValid
.
NotSelf
.
class
)
private
String
nameCn
;
/**
*
性别(字典
)
*
姓名-(拼音/英文,通过中文自动加载全部大写的拼音
)
*/
private
String
gender
;
@NotBlank
(
message
=
"姓名(拼音/英文)不能为空"
,
groups
=
GroupValid
.
NotSelf
.
class
)
private
String
namePyEn
;
/**
* 证件类型(字典)
* 证件类型(字典
,下拉选择
)
*/
@NotBlank
(
message
=
"证件类型不能为空"
,
groups
=
GroupValid
.
NotSelf
.
class
)
private
String
documentType
;
/**
* 证件号码
*/
@NotBlank
(
message
=
"证件号码不能为空"
,
groups
=
GroupValid
.
NotSelf
.
class
)
private
String
idNumber
;
/**
*
出生日期
*
性别(字典,如果是身份证,自动获取性别和生日)
*/
@
JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
)
private
LocalDateTime
birthday
;
@
NotBlank
(
message
=
"性别不能为空"
,
groups
=
GroupValid
.
NotSelf
.
class
)
private
String
gender
;
/**
*
年龄
*
出生日期(生日,如果是身份证,自动获取性别和生日)
*/
@NotNull
(
message
=
"生日不能为空"
,
groups
=
GroupValid
.
NotSelf
.
class
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
)
private
LocalDateTime
birthday
;
@AssertTrue
(
message
=
"必须大于18周岁"
,
groups
=
GroupValid
.
NotSelf
.
class
)
public
boolean
isBirthdayValid
()
{
if
(
birthday
==
null
)
{
// @NotNull 会处理空值
return
true
;
}
LocalDateTime
now
=
LocalDateTime
.
now
();
// 计算年龄
int
age
=
Period
.
between
(
birthday
.
toLocalDate
(),
now
.
toLocalDate
()).
getYears
();
return
age
>
18
;
}
/**
* 年龄(通过生日自动获取年龄)
*/
@NotBlank
(
message
=
"年龄不能为空"
,
groups
=
GroupValid
.
NotSelf
.
class
)
private
String
age
;
/**
* 居住地址
*/
private
String
residentialAddress
;
/**
* 移动电话区号
*/
private
String
mobileCode
;
/**
* 移动电话
*/
private
String
mobile
;
/**
* 邮箱
*/
private
String
email
;
/**
* 行业
*/
private
String
industry
;
/**
* 职位
* 国籍(下拉选择)
*/
private
String
position
;
@NotBlank
(
message
=
"国籍不能为空"
,
groups
=
GroupValid
.
NotSelf
.
class
)
private
String
nationality
;
/**
*
风险偏好(字典)
*
出生地
*/
private
String
riskAppetit
e
;
private
String
birthplac
e
;
/**
* 是否
VIP
: 0-否, 1-是(字典)
* 是否
拥有其他国家公民身份(如美国、日本等)
: 0-否, 1-是(字典)
*/
private
Integer
isVip
;
private
String
isOtherCountry
;
/**
*
vip备注
*
吸烟情况(字典)
*/
private
String
vipRemark
;
@NotBlank
(
message
=
"吸烟情况不能为空"
,
groups
=
GroupValid
.
NotSelf
.
class
)
private
String
smokingStatus
;
/**
*
称谓
(字典)
*
婚姻情况
(字典)
*/
private
String
appellation
;
@NotBlank
(
message
=
"婚姻情况不能为空"
,
groups
=
GroupValid
.
NotSelf
.
class
)
private
String
maritalStatus
;
/**
*
是否区分吸烟
(字典)
*
教育程度
(字典)
*/
private
String
smokingAllowed
;
@NotBlank
(
message
=
"教育程度不能为空"
,
groups
=
GroupValid
.
NotSelf
.
class
)
private
String
educationLevel
;
/**
*
吸烟量(支/天)
*
是否退休(字典)
*/
private
String
smokingVolume
;
@NotBlank
(
message
=
"是否退休不能为空"
,
groups
=
GroupValid
.
NotSelf
.
class
)
private
String
isRetirement
;
/**
*
出生地(省市
)
*
退休年龄(如已退休,再显示
)
*/
private
String
birthplac
e
;
private
String
retirementAg
e
;
/**
*
国籍
*
身高(CM)
*/
private
String
nationality
;
private
String
height
;
/**
*
护照号码
*
体重(KG)
*/
private
String
passportNo
;
private
String
weight
;
/**
*
通行证号码
*
BMI指数(根据身高和体重自动计算)
*/
private
String
passNo
;
private
String
bmi
;
/**
*
身高
*
风险偏好(字典,下拉选择)
*/
private
String
height
;
private
String
riskAppetite
;
/**
*
体重
*
受供养人数目(通过FNA带入)
*/
private
String
weight
;
private
Integer
dependentsNum
;
//-- 以下是联系信息
/**
*
BMI
*
移动电话区号
*/
private
String
bmi
;
@NotBlank
(
message
=
"移动电话区号不能为空"
,
groups
=
GroupValid
.
NotSelf
.
class
)
private
String
mobileCode
;
/**
*
受雇于现职年期
*
移动电话
*/
private
BigDecimal
currentTenure
;
@NotBlank
(
message
=
"移动电话不能为空"
,
groups
=
GroupValid
.
NotSelf
.
class
)
private
String
mobile
;
/**
*
总负债额
*
住宅电话区号
*/
private
BigDecimal
totalDebt
;
private
String
residenceMobileCode
;
/**
*
受供养人数目
*
住宅电话
*/
private
Integer
dependentsNum
;
private
String
residenceMobile
;
/**
*
婚姻状况(字典)
*
固定电话区号
*/
private
String
maritalStatus
;
private
String
landlineCode
;
/**
*
教育程度(字典)
*
固定电话
*/
private
String
educationLevel
;
private
String
landline
;
/**
*
总工作年期
*
邮箱
*/
private
BigDecimal
totalWorkingYears
;
private
String
email
;
/**
*
货币(字典)
*
证件地址
*/
private
String
currency
;
@NotBlank
(
message
=
"证件地址不能为空"
,
groups
=
GroupValid
.
NotSelf
.
class
)
private
String
certificateAddress
;
/**
*
现时每月收入
*
通讯地址
*/
private
BigDecimal
currentMonthlyIncome
;
private
String
mailingAddress
;
/**
*
固定电话
*
居住地址(住宅地址)
*/
private
String
landline
;
private
String
residentialAddress
;
/**
*
过往一年是否所属国家以外地区居住超过182日: 0-否, 1-是(字典)
*
通讯地址邮政编号
*/
private
Integer
isExceed
;
private
String
mailingAddressCode
;
//-- 以下是工作信息
/**
*
是否拥有其他国家公民身份(如美国、日本等): 0-否, 1-是(字典
)
*
就业情况(字典,下拉选择
)
*/
private
Integer
isOtherCountry
;
private
String
employmentStatus
;
/**
*
旅行(字典)
*
公司/学校名称
*/
private
String
travel
;
private
String
csName
;
/**
*
运动(字典)
*
行业
*/
private
String
exercise
;
private
String
industry
;
/**
*
游戏(字典)
*
现时每月收入(HKD)
*/
private
String
ga
me
;
private
BigDecimal
currentMonthlyInco
me
;
/**
*
电影/戏剧(字典)
*
总工作年期
*/
private
String
movieDrama
;
private
BigDecimal
totalWorkingYears
;
/**
*
美食(字典)
*
受雇于现职年期
*/
private
String
delicacy
;
private
BigDecimal
currentTenure
;
/**
*
公司名称
*
职位
*/
private
String
companyName
;
private
String
position
;
/**
* 公司地址
...
...
@@ -284,78 +281,69 @@ public class ApiInsurantInfoDto {
private
String
companyMobile
;
/**
* 公司
名称(英文)
* 公司
地址邮政编号
*/
private
String
companyNameEn
;
/**
* 公司商业登记号码
*/
private
String
companyBusinessNo
;
/**
* 公司注册日期
*/
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
)
private
LocalDateTime
companyRegisterTime
;
private
String
companyAddressCode
;
//-- 以下是财务信息
/**
*
公司注册地区(字典
)
*
平均每月收入(HKD
)
*/
private
String
companyRegisterRegion
;
private
BigDecimal
monthIncome
;
/**
*
公司邮箱
*
平均每月支出(HKD)
*/
private
String
companyEmail
;
private
BigDecimal
monthExpenditure
;
/**
*
公司登记地址
*
总流动资产(HKD)
*/
private
String
companyEnterAddres
s
;
private
BigDecimal
totalCurrentAsset
s
;
/**
*
通讯地址
*
总负债额(HKD)
*/
private
String
mailingAddress
;
private
BigDecimal
totalDebt
;
//-- 其他信息(非必填)
/**
*
授权代表姓名中文-名字
*
旅行(字典)
*/
private
String
authNameCn
;
private
String
travel
;
/**
*
授权代表姓名英文-名字
*
运动(字典,下拉选择)
*/
private
String
authNameEn
;
private
String
exercise
;
/**
*
授权代表职称
*
游戏(字典,下拉选择)
*/
private
String
authProfessional
;
private
String
game
;
/**
*
授权代表电话区号
*
电影/戏剧(字典,下拉选择)
*/
private
String
authMobileCode
;
private
String
movieDrama
;
/**
*
授权代表电话
*
美食(输入)
*/
private
String
authMobile
;
private
String
delicacy
;
/**
*
其他电话
*
地址列表
*/
private
String
otherMobile
;
private
List
<
AddressDto
>
addressList
;
/**
*
是否接受推广信息: 0-否, 1-是(字典)
*
税务信息列表
*/
private
Integer
isPromotion
;
private
List
<
ApiTaxationDto
>
apiTaxationDtoList
;
/
**
* 地址列表
*/
private
List
<
AddressDto
>
addressList
;
/
/ 判断与投保人关系是否为本人关系
public
boolean
isSelf
()
{
return
RelTypeEnum
.
MYSELF
.
getItemValue
().
equals
(
policyholderRel
);
}
}
yd-csf-feign/src/main/java/com/yd/csf/feign/dto/appointment/ApiPolicyholderInfoDto.java
View file @
7b943b2c
...
...
@@ -2,11 +2,16 @@ package com.yd.csf.feign.dto.appointment;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
com.yd.csf.feign.dto.AddressDto
;
import
io.swagger.v3.oas.annotations.media.Schema
;
import
com.yd.csf.feign.dto.taxation.ApiTaxationDto
;
import
lombok.Data
;
import
javax.validation.constraints.AssertTrue
;
import
javax.validation.constraints.NotBlank
;
import
javax.validation.constraints.NotNull
;
import
javax.validation.constraints.Pattern
;
import
java.math.BigDecimal
;
import
java.time.LocalDateTime
;
import
java.time.Period
;
import
java.util.List
;
/**
...
...
@@ -16,271 +21,242 @@ import java.util.List;
public
class
ApiPolicyholderInfoDto
{
/**
* 投保人信息主键id(新增不需要传值,修改需要传值)
*/
private
Long
id
;
/**
* 预约信息主表唯一业务ID(新增不需要传值,修改需要传值)
*/
private
String
appointmentBizId
;
/**
* 投保人信息表唯一业务ID(新增不需要传值,修改需要传值)
* 投保人信息表唯一业务ID
*/
private
String
policyholderBizId
;
/**
* 客户类型(字典)
*/
// @NotBlank(message = "客户类型不能为空")
private
String
customerType
;
/**
* 关联客户信息表唯一业务ID(冗余字段)
*/
@NotBlank
(
message
=
"关联客户信息表唯一业务ID不能为空"
)
private
String
customerBizId
;
/**
* 关联客户编号(和客户信息表唯一业务ID是一对,唯一,冗余字段)
*/
@NotBlank
(
message
=
"关联客户编号不能为空"
)
private
String
customerNo
;
//-- 以下基础信息
/**
* 名字
*/
private
String
name
;
/**
* 名字-英文
* 姓名-中文
*/
private
String
nameEn
;
@NotBlank
(
message
=
"姓名(中文)不能为空"
)
@Pattern
(
regexp
=
"^[\u4e00-\u9fa5]{2,6}$"
,
message
=
"姓名(中文)必须为2-6位汉字"
)
private
String
nameCn
;
/**
*
性别(字典
)
*
姓名-(拼音/英文,通过中文自动加载全部大写的拼音
)
*/
private
String
gender
;
@NotBlank
(
message
=
"姓名(拼音/英文)不能为空"
)
private
String
namePyEn
;
/**
* 证件类型(字典)
* 证件类型(字典
,下拉选择
)
*/
@NotBlank
(
message
=
"证件类型不能为空"
)
private
String
documentType
;
/**
* 证件号码
*/
@NotBlank
(
message
=
"证件号码不能为空"
)
private
String
idNumber
;
/**
*
出生日期
*
性别(字典,如果是身份证,自动获取性别和生日)
*/
@
JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss
"
)
private
LocalDateTime
birthday
;
@
NotBlank
(
message
=
"性别不能为空
"
)
private
String
gender
;
/**
*
年龄
*
出生日期(生日,如果是身份证,自动获取性别和生日)
*/
@NotNull
(
message
=
"生日不能为空"
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
)
private
LocalDateTime
birthday
;
@AssertTrue
(
message
=
"必须大于18周岁"
)
public
boolean
isBirthdayValid
()
{
if
(
birthday
==
null
)
{
// @NotNull 会处理空值
return
true
;
}
LocalDateTime
now
=
LocalDateTime
.
now
();
// 计算年龄
int
age
=
Period
.
between
(
birthday
.
toLocalDate
(),
now
.
toLocalDate
()).
getYears
();
return
age
>
18
;
}
/**
* 年龄(通过生日自动获取年龄)
*/
@NotBlank
(
message
=
"年龄不能为空"
)
private
String
age
;
/**
* 居住地址
*/
private
String
residentialAddress
;
/**
* 移动电话区号
*/
private
String
mobileCode
;
/**
* 移动电话
*/
private
String
mobile
;
/**
* 邮箱
*/
private
String
email
;
/**
* 行业
*/
private
String
industry
;
/**
* 职位
*/
private
String
position
;
/**
* 风险偏好(字典)
*/
private
String
riskAppetite
;
/**
* 是否VIP: 0-否, 1-是(字典)
* 国籍(下拉选择)
*/
private
Integer
isVip
;
/**
* vip备注
*/
private
String
vipRemark
;
@NotBlank
(
message
=
"国籍不能为空"
)
private
String
nationality
;
/**
*
称谓(字典)
*
出生地
*/
private
String
appellation
;
private
String
birthplace
;
/**
* 是否
区分吸烟
(字典)
* 是否
拥有其他国家公民身份(如美国、日本等): 0-否, 1-是
(字典)
*/
private
String
smokingAllowed
;
private
String
isOtherCountry
;
/**
* 吸烟
量(支/天)
* 吸烟
情况(字典)
*/
private
String
smokingVolume
;
@NotBlank
(
message
=
"吸烟情况不能为空"
)
private
String
smokingStatus
;
/**
*
出生地(省市
)
*
婚姻情况(字典
)
*/
private
String
birthplace
;
@NotBlank
(
message
=
"婚姻情况不能为空"
)
private
String
maritalStatus
;
/**
*
国籍
*
教育程度(字典)
*/
private
String
nationality
;
@NotBlank
(
message
=
"教育程度不能为空"
)
private
String
educationLevel
;
/**
*
护照号码
*
是否退休(字典)
*/
private
String
passportNo
;
@NotBlank
(
message
=
"是否退休不能为空"
)
private
String
isRetirement
;
/**
*
通行证号码
*
退休年龄(如已退休,再显示)
*/
private
String
passNo
;
private
String
retirementAge
;
/**
* 身高
* 身高
(CM)
*/
private
String
height
;
/**
* 体重
* 体重
(KG)
*/
private
String
weight
;
/**
* BMI
* BMI
指数(根据身高和体重自动计算)
*/
private
String
bmi
;
/**
* 货币(字典)
*/
private
String
currency
;
/**
* 平均每月支出
* 风险偏好(字典,下拉选择)
*/
private
BigDecimal
monthExpenditur
e
;
private
String
riskAppetit
e
;
/**
*
平均每月收入
*
受供养人数目(通过FNA带入)
*/
private
BigDecimal
monthIncome
;
private
Integer
dependentsNum
;
//-- 以下是联系信息
/**
*
受雇于现职年期
*
移动电话区号
*/
private
BigDecimal
currentTenure
;
@NotBlank
(
message
=
"移动电话区号不能为空"
)
private
String
mobileCode
;
/**
*
总流动资产
*
移动电话
*/
private
BigDecimal
totalCurrentAssets
;
@NotBlank
(
message
=
"移动电话不能为空"
)
private
String
mobile
;
/**
*
总负债额
*
住宅电话区号
*/
private
BigDecimal
totalDebt
;
private
String
residenceMobileCode
;
/**
*
受供养人数目
*
住宅电话
*/
private
Integer
dependentsNum
;
private
String
residenceMobile
;
/**
*
婚姻状况(字典)
*
固定电话区号
*/
private
String
maritalStatus
;
private
String
landlineCode
;
/**
*
教育程度(字典)
*
固定电话
*/
private
String
educationLevel
;
private
String
landline
;
/**
*
总工作年期
*
邮箱
*/
private
BigDecimal
totalWorkingYears
;
private
String
email
;
/**
*
现时每月收入
*
证件地址
*/
private
BigDecimal
currentMonthlyIncome
;
@NotBlank
(
message
=
"证件地址不能为空"
)
private
String
certificateAddress
;
/**
*
固定电话
*
通讯地址
*/
private
String
landline
;
private
String
mailingAddress
;
/**
*
过往一年是否所属国家以外地区居住超过182日: 0-否, 1-是(字典
)
*
居住地址(住宅地址
)
*/
private
Integer
isExceed
;
private
String
residentialAddress
;
/**
*
是否拥有其他国家公民身份(如美国、日本等): 0-否, 1-是(字典)
*
通讯地址邮政编号
*/
private
Integer
isOtherCountry
;
private
String
mailingAddressCode
;
//-- 以下是工作信息
/**
*
投保人邮政编码
*
就业情况(字典,下拉选择)
*/
private
String
postalCode
;
private
String
employmentStatus
;
/**
*
旅行(字典)
*
公司/学校名称
*/
private
String
travel
;
private
String
csName
;
/**
*
运动(字典)
*
行业
*/
private
String
exercise
;
private
String
industry
;
/**
*
游戏(字典)
*
现时每月收入(HKD)
*/
private
String
ga
me
;
private
BigDecimal
currentMonthlyInco
me
;
/**
*
电影/戏剧(字典)
*
总工作年期
*/
private
String
movieDrama
;
private
BigDecimal
totalWorkingYears
;
/**
*
美食(字典)
*
受雇于现职年期
*/
private
String
delicacy
;
private
BigDecimal
currentTenure
;
/**
*
公司名称
*
职位
*/
private
String
companyName
;
private
String
position
;
/**
* 公司地址
...
...
@@ -298,78 +274,64 @@ public class ApiPolicyholderInfoDto {
private
String
companyMobile
;
/**
* 公司名称(英文)
*/
private
String
companyNameEn
;
/**
* 公司商业登记号码
*/
private
String
companyBusinessNo
;
/**
* 公司注册日期
*/
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
)
private
LocalDateTime
companyRegisterTime
;
/**
* 公司注册地区(字典)
* 公司地址邮政编号
*/
private
String
company
RegisterRegion
;
private
String
company
AddressCode
;
//-- 以下是财务信息
/**
*
公司邮箱
*
平均每月收入(HKD)
*/
private
String
companyEmail
;
private
BigDecimal
monthIncome
;
/**
*
公司登记地址
*
平均每月支出(HKD)
*/
private
String
companyEnterAddress
;
private
BigDecimal
monthExpenditure
;
/**
*
通讯地址
*
总流动资产(HKD)
*/
private
String
mailingAddres
s
;
private
BigDecimal
totalCurrentAsset
s
;
/**
*
授权代表姓名中文-名字
*
总负债额(HKD)
*/
private
String
authNameCn
;
private
BigDecimal
totalDebt
;
//-- 其他信息(非必填)
/**
*
授权代表姓名英文-名字
*
旅行(字典)
*/
private
String
authNameEn
;
private
String
travel
;
/**
*
授权代表职称
*
运动(字典,下拉选择)
*/
private
String
authProfessional
;
private
String
exercise
;
/**
*
授权代表电话区号
*
游戏(字典,下拉选择)
*/
private
String
authMobileCod
e
;
private
String
gam
e
;
/**
*
授权代表电话
*
电影/戏剧(字典,下拉选择)
*/
private
String
authMobile
;
private
String
movieDrama
;
/**
*
其他电话
*
美食(输入)
*/
private
String
otherMobile
;
private
String
delicacy
;
/**
*
是否接受推广信息: 0-否, 1-是(字典)
*
地址列表
*/
private
Integer
isPromotion
;
private
List
<
AddressDto
>
addressList
;
/**
*
地址
列表
*
税务信息
列表
*/
private
List
<
A
ddressDto
>
address
List
;
private
List
<
A
piTaxationDto
>
apiTaxationDto
List
;
}
yd-csf-feign/src/main/java/com/yd/csf/feign/dto/appointment/ApiProductPlanInfoDto.java
View file @
7b943b2c
...
...
@@ -2,6 +2,7 @@ package com.yd.csf.feign.dto.appointment;
import
lombok.Data
;
import
javax.validation.Valid
;
import
java.util.List
;
/**
...
...
@@ -13,6 +14,7 @@ public class ApiProductPlanInfoDto {
/**
* 产品计划主信息
*/
@Valid
private
ApiProductPlanMainInfoDto
apiProductPlanMainInfoDto
;
/**
...
...
yd-csf-feign/src/main/java/com/yd/csf/feign/dto/appointment/ApiProductPlanMainInfoDto.java
View file @
7b943b2c
package
com
.
yd
.
csf
.
feign
.
dto
.
appointment
;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
lombok.Data
;
import
javax.validation.constraints.NotBlank
;
import
java.math.BigDecimal
;
import
java.time.LocalDateTime
;
/**
* 产品计划主信息
...
...
@@ -12,82 +11,71 @@ import java.time.LocalDateTime;
public
class
ApiProductPlanMainInfoDto
{
/**
* 产品计划
表主键id(新增不需要传值,编辑需要传值)
* 产品计划
信息表唯一业务ID
*/
private
Long
i
d
;
private
String
planBizI
d
;
/**
*
预约信息主表唯一业务ID(新增不需要传值,编辑需要传值
)
*
保险公司ID(产品上架信息绑定的保险公司参数
)
*/
private
String
appointmentBiz
Id
;
private
String
company
Id
;
/**
*
产品计划信息表唯一业务ID(新增不需要传值,编辑需要传值)
*
保险公司名称
*/
private
String
planBizId
;
private
String
companyName
;
/**
* 保险
产品唯一业务ID(中台保险产品业务id,冗余
)
* 保险
险种ID(产品上架信息绑定的保险险种参数
)
*/
// @NotBlank(message = "保险产品唯一业务ID不能为空")
private
String
productBizId
;
private
String
insuranceTypeId
;
/**
* 保险
产品名称(中台保险产品名称,冗余)
* 保险
险种名称
*/
// @NotBlank(message = "保险产品名称不能为空")
private
String
productName
;
private
String
insuranceTypeName
;
/**
*
保险公司名称(冗余字段)
*
产品上架信息表唯一业务ID
*/
private
String
companyName
;
@NotBlank
(
message
=
"产品ID不能为空"
)
private
String
productLaunchBizId
;
/**
*
地区
*
产品上架信息表名称(标题)
*/
private
String
region
;
@NotBlank
(
message
=
"产品名称不能为空"
)
private
String
productLaunchName
;
/**
*
货币(字典)
*
供款期数
*/
// @NotBlank(message = "货币不能为空")
private
String
currency
;
private
String
issueNumber
;
/**
*
供款年期(字典)
*
保障年期
*/
// @NotBlank(message = "供款年期不能为空")
private
String
paymentTerm
;
private
String
guaranteePeriod
;
/**
*
付款频率(字典)
*
保单币种
*/
// @NotBlank(message = "付款频率不能为空")
private
String
paymentFrequency
;
private
String
policyCurrency
;
/**
*
每期保费
*
保单额度(重疾)
*/
// @NotNull(message = "每期保费不能为空")
private
BigDecimal
eachIssuePremium
;
/**
* 保额
*/
// @NotNull(message = "保额不能为空")
private
BigDecimal
sumInsured
;
/**
*
是否预缴保费: 0-否, 1-是
(字典)
*
付款频率
(字典)
*/
// @NotNull(message = "是否预缴保费不能为空")
private
Integer
isPrepay
;
private
String
paymentFrequency
;
/**
*
预付额
*
每期保费
*/
private
BigDecimal
deductibles
;
private
BigDecimal
eachIssuePremium
;
/**
* 首期付款方式(字典)
...
...
@@ -95,33 +83,37 @@ public class ApiProductPlanMainInfoDto {
private
String
initialPaymentMethod
;
/**
*
续期付款方式(字典)
*
保单征费
*/
private
String
renewalPaymentMethod
;
private
BigDecimal
policyLevy
;
/**
*
红利分配方式
(字典)
*
是否预缴保费: 0-否, 1-是
(字典)
*/
private
String
dividendDistributionMethod
;
private
String
isPrepay
;
/**
*
保单日期回
溯: 0-否, 1-是(字典)
*
是否追
溯: 0-否, 1-是(字典)
*/
private
Integer
isBacktrack
;
private
String
isTraceable
;
/**
* 保单
生效日
* 保单
日期回溯: 0-否, 1-是(字典)
*/
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
)
private
LocalDateTime
policyEffectiveDate
;
private
String
isBacktrack
;
/**
* 是否参加递增保障权益: 0-否, 1-是(字典)
*/
private
Integer
isJoin
;
private
String
isJoin
;
/**
*
保单征费
*
红利分配方式(字典)
*/
private
BigDecimal
policyLevy
;
private
String
dividendDistributionMethod
;
/**
* 续期付款方式(字典)
*/
private
String
renewalPaymentMethod
;
}
yd-csf-feign/src/main/java/com/yd/csf/feign/dto/appointment/ApiSecondHolderInfoDto.java
View file @
7b943b2c
...
...
@@ -2,7 +2,6 @@ package com.yd.csf.feign.dto.appointment;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
lombok.Data
;
import
java.time.LocalDateTime
;
/**
...
...
@@ -12,17 +11,7 @@ import java.time.LocalDateTime;
public
class
ApiSecondHolderInfoDto
{
/**
* 第二持有人信息表主键id(新增不需要传值,修改需要传值)
*/
private
Long
id
;
/**
* 预约信息主表唯一业务ID(新增不需要传值,修改需要传值)
*/
private
String
appointmentBizId
;
/**
* 第二持有人信息表唯一业务ID(新增不需要传值,修改需要传值)
* 第二持有人信息表唯一业务ID
*/
private
String
secondHolderBizId
;
...
...
@@ -32,22 +21,17 @@ public class ApiSecondHolderInfoDto {
private
String
insurantRel
;
/**
*
名字
*
姓名-中文
*/
private
String
name
;
private
String
name
Cn
;
/**
*
名字-英文
*
姓名-(拼音/英文,通过中文自动加载全部大写的拼音)
*/
private
String
nameEn
;
private
String
name
Py
En
;
/**
* 性别(字典)
*/
private
String
gender
;
/**
* 证件类型(字典)
* 证件类型(字典,下拉选择)
*/
private
String
documentType
;
...
...
@@ -57,18 +41,13 @@ public class ApiSecondHolderInfoDto {
private
String
idNumber
;
/**
*
护照号码
*
性别(字典,如果是身份证,自动获取性别和生日)
*/
private
String
passportNumb
er
;
private
String
gend
er
;
/**
* 出生日期
* 出生日期
(生日,如果是身份证,自动获取性别和生日)
*/
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
)
private
LocalDateTime
birthTime
;
/**
* 年龄
*/
private
String
age
;
private
LocalDateTime
birthday
;
}
yd-csf-feign/src/main/java/com/yd/csf/feign/dto/excel/ApiExcelAppointmentMainDto.java
View file @
7b943b2c
...
...
@@ -69,15 +69,15 @@ public class ApiExcelAppointmentMainDto {
return
mainDto
;
}
/**
* ApiExcelAppointmentMainDto构造ApiAppointmentInfoDto用于保存到表
* @param dto
* @return
*/
public
static
ApiAppointmentInfoDto
setApiAppointmentInfoDto
(
ApiExcelAppointmentMainDto
dto
)
{
ApiAppointmentInfoDto
infoDto
=
new
ApiAppointmentInfoDto
();
infoDto
.
setIntentionAppointmentTime
(
DateUtil
.
getLocalDateTime
(
dto
.
getMainIntentionAppointmentDate
()
+
" "
+
dto
.
getMainIntentionAppointmentTime
()));
infoDto
.
setIsTj
(
dto
.
getIsTj
());
return
infoDto
;
}
//
/**
//
* ApiExcelAppointmentMainDto构造ApiAppointmentInfoDto用于保存到表
//
* @param dto
//
* @return
//
*/
//
public static ApiAppointmentInfoDto setApiAppointmentInfoDto(ApiExcelAppointmentMainDto dto) {
//
ApiAppointmentInfoDto infoDto = new ApiAppointmentInfoDto();
//
infoDto.setIntentionAppointmentTime(DateUtil.getLocalDateTime(dto.getMainIntentionAppointmentDate() + " " + dto.getMainIntentionAppointmentTime()));
//
infoDto.setIsTj(dto.getIsTj());
//
return infoDto;
//
}
}
yd-csf-feign/src/main/java/com/yd/csf/feign/dto/excel/ApiExcelImportAppointmentDto.java
View file @
7b943b2c
...
...
@@ -510,9 +510,9 @@ public class ApiExcelImportAppointmentDto {
//到港时间
infoDto
.
setArrivalTime
(
DateUtil
.
getLocalDateTime
(
dto
.
getHkArrivalTime
()));
//业务编号->介绍人编号 TODO
infoDto
.
setBusinessNo
(
dto
.
getMainReferrerId
());
//
infoDto.setBusinessNo(dto.getMainReferrerId());
//确定预约时间->预约日期 (西元 年/月/日) + 預約時間
infoDto
.
setConfirmAppointmentTime
(
DateUtil
.
getLocalDateTime
(
dto
.
getMainIntentionAppointmentDate
()
+
" "
+
dto
.
getMainIntentionAppointmentTime
()));
//
infoDto.setConfirmAppointmentTime(DateUtil.getLocalDateTime(dto.getMainIntentionAppointmentDate() + " " + dto.getMainIntentionAppointmentTime()));
//离港时间->离港(澳)日期及时间(离港时间)(预约信息主表)
infoDto
.
setDepartureTime
(
DateUtil
.
getLocalDateTime
(
dto
.
getHkDepartureTime
()));
//客户在港期间联络电话->客户在港期间联络电话(预约信息主表)区号+号码
...
...
@@ -540,7 +540,7 @@ public class ApiExcelImportAppointmentDto {
//保险公司名称
infoDto
.
setCompanyName
(
dto
.
getPlanCompanyName
());
//货币(字典)
infoDto
.
setCurrency
(
dto
.
getPlanCurrency
());
infoDto
.
set
Policy
Currency
(
dto
.
getPlanCurrency
());
//预付额 TODO
// infoDto.setDeductibles();
//红利分配方式(字典)
...
...
@@ -552,17 +552,17 @@ public class ApiExcelImportAppointmentDto {
infoDto
.
setInitialPaymentMethod
(
GetDictItemListByDictTypeResponse
.
getItemValue
(
dictTypeResponses
,
DictTypeEnum
.
CSF_AP_FIRST_ISSUE
.
getItemValue
(),
dto
.
getPlanInitialPaymentMethod
()));
//是否参加递增保障权益->是否參加遞增保障權益/通脹加保權益
infoDto
.
setIsJoin
(
Integer
.
getInteger
(
GetDictItemListByDictTypeResponse
.
getItemValue
(
dictTypeResponses
,
DictTypeEnum
.
SYS_NO_YES
.
getItemValue
(),
dto
.
getPlanIsJoin
()))
)
;
infoDto
.
setIsJoin
(
GetDictItemListByDictTypeResponse
.
getItemValue
(
dictTypeResponses
,
DictTypeEnum
.
SYS_NO_YES
.
getItemValue
(),
dto
.
getPlanIsJoin
()));
//是否预缴保费->是否預繳保費 (如是,請填寫首期保費以外的剩餘保費)(是否预缴保费: 0-否, 1-是(字典)(产品计划信息表))
infoDto
.
setIsPrepay
(
Integer
.
getInteger
(
GetDictItemListByDictTypeResponse
.
getItemValue
(
dictTypeResponses
,
DictTypeEnum
.
SYS_NO_YES
.
getItemValue
(),
dto
.
getPlanIsPrepay
()))
)
;
infoDto
.
setIsPrepay
(
GetDictItemListByDictTypeResponse
.
getItemValue
(
dictTypeResponses
,
DictTypeEnum
.
SYS_NO_YES
.
getItemValue
(),
dto
.
getPlanIsPrepay
()));
//付款频率
infoDto
.
setPaymentFrequency
(
dto
.
getPlanPaymentFrequency
());
//供款年期
infoDto
.
set
PaymentTerm
(
dto
.
getPlanPaymentTerm
());
infoDto
.
set
IssueNumber
(
dto
.
getPlanPaymentTerm
());
//保险产品名称->基本計劃名稱
infoDto
.
setProductName
(
dto
.
getPlanProductName
());
infoDto
.
setProduct
Launch
Name
(
dto
.
getPlanProductName
());
//续期付款方式
infoDto
.
setRenewalPaymentMethod
(
GetDictItemListByDictTypeResponse
.
getItemValue
(
dictTypeResponses
,
DictTypeEnum
.
CSF_AP_FIRST_ISSUE
.
getItemValue
(),
dto
.
getPlanRenewalPaymentMethod
()));
...
...
@@ -610,14 +610,14 @@ public class ApiExcelImportAppointmentDto {
infoDto
.
setMobile
(
StringUtil
.
getSplitStr
(
dto
.
getPolicyholderMobile
(),
"-"
,
1
));
infoDto
.
setMobileCode
(
StringUtil
.
getSplitStr
(
dto
.
getPolicyholderMobile
(),
"-"
,
0
));
//名字->中文姓名(投保人信息表:名字)
infoDto
.
setName
(
dto
.
getPolicyholderName
());
infoDto
.
setName
Cn
(
dto
.
getPolicyholderName
());
//名字-英文->英文姓名 (同护照)(投保人信息表:名字-英文)
infoDto
.
setNameEn
(
dto
.
getPolicyholderNameEn
());
infoDto
.
setName
Py
En
(
dto
.
getPolicyholderNameEn
());
//国籍
infoDto
.
setNationality
(
dto
.
getPolicyholderNationality
());
//通行证号码->港澳通行证号码(投保人信息表:通行证号码)
infoDto
.
setPassNo
(
dto
.
getPolicyholderPassNo
());
infoDto
.
setPassportNo
(
dto
.
getPolicyholderPassportNo
());
//
infoDto.setPassNo(dto.getPolicyholderPassNo());
//
infoDto.setPassportNo(dto.getPolicyholderPassportNo());
//职位
infoDto
.
setPosition
(
dto
.
getPolicyholderPosition
());
//居住地址->永久(住宅)地址(投保人信息表:居住地址)
...
...
@@ -666,14 +666,14 @@ public class ApiExcelImportAppointmentDto {
infoDto
.
setMobile
(
StringUtil
.
getSplitStr
(
dto
.
getInsurantMobile
(),
"-"
,
1
));
infoDto
.
setMobileCode
(
StringUtil
.
getSplitStr
(
dto
.
getInsurantMobile
(),
"-"
,
0
));
//名字->中文姓名(投保人信息表:名字)
infoDto
.
setName
(
dto
.
getInsurantName
());
infoDto
.
setName
Cn
(
dto
.
getInsurantName
());
//名字-英文->英文姓名 (同护照)(投保人信息表:名字-英文)
infoDto
.
setNameEn
(
dto
.
getInsurantNameEn
());
infoDto
.
setName
Py
En
(
dto
.
getInsurantNameEn
());
//国籍
infoDto
.
setNationality
(
dto
.
getInsurantNationality
());
//通行证号码->港澳通行证号码(投保人信息表:通行证号码)
infoDto
.
setPassNo
(
dto
.
getInsurantPassNo
());
infoDto
.
setPassportNo
(
dto
.
getInsurantPassportNo
());
//
infoDto.setPassNo(dto.getInsurantPassNo());
//
infoDto.setPassportNo(dto.getInsurantPassportNo());
//职位
infoDto
.
setPosition
(
dto
.
getInsurantPosition
());
//居住地址->永久(住宅)地址(投保人信息表:居住地址)
...
...
@@ -693,7 +693,7 @@ public class ApiExcelImportAppointmentDto {
ApiSecondHolderInfoDto
infoDto
,
List
<
GetDictItemListByDictTypeResponse
>
dictTypeResponses
)
{
//出生日期
infoDto
.
setBirth
Time
(
DateUtil
.
getYMDLocalDateTime
(
dto
.
getSecondHolderBirthTime
()));
infoDto
.
setBirth
day
(
DateUtil
.
getYMDLocalDateTime
(
dto
.
getSecondHolderBirthTime
()));
//性别(字典)
infoDto
.
setGender
(
GetDictItemListByDictTypeResponse
.
getItemValue
(
dictTypeResponses
,
DictTypeEnum
.
SYS_GENDER
.
getItemValue
(),
dto
.
getSecondHolderGender
()));
...
...
@@ -703,9 +703,9 @@ public class ApiExcelImportAppointmentDto {
infoDto
.
setInsurantRel
(
GetDictItemListByDictTypeResponse
.
getItemValue
(
dictTypeResponses
,
DictTypeEnum
.
CSF_AP_REL
.
getItemValue
(),
ChineseTextConverter
.
traditionalToSimplified
(
dto
.
getSecondHolderInsurantRel
())));
//名字
infoDto
.
setName
(
dto
.
getSecondHolderName
());
infoDto
.
setName
Cn
(
dto
.
getSecondHolderName
());
//名字-英文
infoDto
.
setNameEn
(
dto
.
getSecondHolderNameEn
());
infoDto
.
setName
Py
En
(
dto
.
getSecondHolderNameEn
());
return
infoDto
;
}
...
...
@@ -727,11 +727,11 @@ public class ApiExcelImportAppointmentDto {
//受益比例
infoDto
.
setBenefitRatio
(
dto
.
getBeneficiaryBenefitRatio
());
//出生日期
infoDto
.
setBirth
Time
(
DateUtil
.
getYMDLocalDateTime
(
dto
.
getBeneficiaryBirthTime
()));
infoDto
.
setBirth
day
(
DateUtil
.
getYMDLocalDateTime
(
dto
.
getBeneficiaryBirthTime
()));
//中文姓名
infoDto
.
setName
(
dto
.
getBeneficiaryName
());
infoDto
.
setName
Cn
(
dto
.
getBeneficiaryName
());
//名字-英文
infoDto
.
setNameEn
(
dto
.
getBeneficiaryNameEn
());
infoDto
.
setName
Py
En
(
dto
.
getBeneficiaryNameEn
());
//证件号码
infoDto
.
setIdNumber
(
dto
.
getBeneficiaryIdNumber
());
//与受保人关系
...
...
yd-csf-feign/src/main/java/com/yd/csf/feign/dto/taxation/ApiTaxationDto.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
feign
.
dto
.
taxation
;
import
lombok.Data
;
@Data
public
class
ApiTaxationDto
{
/**
* 税务国家
*/
private
String
taxCountry
;
/**
* 税务编号
*/
private
String
taxId
;
}
yd-csf-
service/src/main/java/com/yd/csf/service
/enums/RelTypeEnum.java
→
yd-csf-
feign/src/main/java/com/yd/csf/feign
/enums/RelTypeEnum.java
View file @
7b943b2c
package
com
.
yd
.
csf
.
service
.
enums
;
package
com
.
yd
.
csf
.
feign
.
enums
;
/**
* 用户关系枚举
...
...
yd-csf-feign/src/main/java/com/yd/csf/feign/fallback/appointment/ApiAppointmentFeignFallbackFactory.java
View file @
7b943b2c
...
...
@@ -6,6 +6,7 @@ import com.yd.csf.feign.dto.appointment.ApiAppointmentInfoDto;
import
com.yd.csf.feign.request.appointment.*
;
import
com.yd.csf.feign.response.appointment.ApiAppointmentAddResponse
;
import
com.yd.csf.feign.response.appointment.ApiAppointmentDetailResponse
;
import
com.yd.csf.feign.response.appointment.ApiAppointmentLogDetailResponse
;
import
lombok.extern.slf4j.Slf4j
;
import
org.springframework.cloud.openfeign.FallbackFactory
;
import
org.springframework.stereotype.Component
;
...
...
@@ -57,6 +58,11 @@ public class ApiAppointmentFeignFallbackFactory implements FallbackFactory<ApiAp
}
@Override
public
Result
editStorage
(
ApiAppointmentEditStorageRequest
request
)
{
return
null
;
}
@Override
public
Result
editConfirmTime
(
ApiAppointmentEditConfirmTimeRequest
request
)
{
return
null
;
}
...
...
@@ -87,9 +93,24 @@ public class ApiAppointmentFeignFallbackFactory implements FallbackFactory<ApiAp
}
@Override
public
Result
editStatus
(
ApiAppointmentEditStatusRequest
request
)
{
return
null
;
}
@Override
public
Result
del
(
String
appointmentBizId
)
{
return
null
;
}
@Override
public
Result
logPage
(
ApiAppointmentLogPageRequest
request
)
{
return
null
;
}
@Override
public
Result
<
ApiAppointmentLogDetailResponse
>
logDetail
(
String
appointmentLogBizId
)
{
return
null
;
}
};
}
}
yd-csf-feign/src/main/java/com/yd/csf/feign/fallback/common/ApiCsfCommonFeignFallbackFactory.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
feign
.
fallback
.
common
;
import
com.yd.common.result.Result
;
import
com.yd.csf.feign.client.common.ApiCsfCommonFeignClient
;
import
com.yd.csf.feign.request.common.ApiCsfCalculateRequest
;
import
com.yd.csf.feign.response.common.ApiCsfCalculateResponse
;
import
lombok.extern.slf4j.Slf4j
;
import
org.springframework.cloud.openfeign.FallbackFactory
;
import
org.springframework.stereotype.Component
;
import
java.util.List
;
/**
* 香港保险服务-公共接口信息Feign降级处理
*/
@Slf4j
@Component
public
class
ApiCsfCommonFeignFallbackFactory
implements
FallbackFactory
<
ApiCsfCommonFeignClient
>
{
@Override
public
ApiCsfCommonFeignClient
create
(
Throwable
cause
)
{
return
new
ApiCsfCommonFeignClient
()
{
@Override
public
Result
<
List
<
ApiCsfCalculateResponse
>>
calculate
(
ApiCsfCalculateRequest
request
)
{
return
null
;
}
};
}
}
yd-csf-feign/src/main/java/com/yd/csf/feign/request/appointment/ApiAppointmentAddRequest.java
View file @
7b943b2c
...
...
@@ -3,6 +3,8 @@ package com.yd.csf.feign.request.appointment;
import
com.yd.csf.feign.dto.appointment.*
;
import
com.yd.question.feign.dto.ApiAnswerSessionsDto
;
import
lombok.Data
;
import
javax.validation.Valid
;
import
java.util.List
;
/**
...
...
@@ -12,18 +14,21 @@ import java.util.List;
public
class
ApiAppointmentAddRequest
{
/**
* 预约信息
* 预约信息
(包含签约信息)
*/
@Valid
private
ApiAppointmentInfoDto
apiAppointmentInfoDto
;
/**
* 产品计划信息
*/
@Valid
private
ApiProductPlanInfoDto
apiProductPlanInfoDto
;
/**
* 投保人信息
*/
@Valid
private
ApiPolicyholderInfoDto
apiPolicyholderInfoDto
;
/**
...
...
yd-csf-feign/src/main/java/com/yd/csf/feign/request/appointment/ApiAppointmentEditRequest.java
View file @
7b943b2c
...
...
@@ -4,6 +4,7 @@ import com.yd.csf.feign.dto.appointment.*;
import
com.yd.question.feign.dto.ApiAnswerSessionsDto
;
import
lombok.Data
;
import
javax.validation.Valid
;
import
java.util.List
;
/**
...
...
@@ -15,16 +16,19 @@ public class ApiAppointmentEditRequest {
/**
* 预约信息
*/
@Valid
private
ApiAppointmentInfoDto
apiAppointmentInfoDto
;
/**
* 产品计划信息
*/
@Valid
private
ApiProductPlanInfoDto
apiProductPlanInfoDto
;
/**
* 投保人信息
*/
@Valid
private
ApiPolicyholderInfoDto
apiPolicyholderInfoDto
;
/**
...
...
yd-csf-feign/src/main/java/com/yd/csf/feign/request/appointment/ApiAppointmentEditStatusRequest.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
feign
.
request
.
appointment
;
import
lombok.Data
;
import
javax.validation.constraints.NotBlank
;
import
javax.validation.constraints.NotNull
;
@Data
public
class
ApiAppointmentEditStatusRequest
{
/**
* 操作类型 1-取消申请 2-取消预约
*/
@NotNull
(
message
=
"操作类型不能为空"
)
private
Integer
oprType
;
/**
* 预约信息主表唯一业务ID
*/
@NotBlank
(
message
=
"预约信息主表唯一业务ID不能为空"
)
private
String
appointmentBizId
;
/**
* 预约状态
*/
@NotNull
(
message
=
"预约状态不能为空"
)
private
Integer
status
;
/**
* 通用备注
*/
private
String
remark
;
}
yd-csf-feign/src/main/java/com/yd/csf/feign/request/appointment/ApiAppointmentEditStorageRequest.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
feign
.
request
.
appointment
;
import
com.yd.csf.feign.dto.appointment.*
;
import
com.yd.question.feign.dto.ApiAnswerSessionsDto
;
import
lombok.Data
;
import
java.util.List
;
@Data
public
class
ApiAppointmentEditStorageRequest
{
/**
* 预约信息
*/
private
ApiAppointmentInfoDto
apiAppointmentInfoDto
;
/**
* 产品计划信息
*/
private
ApiProductPlanInfoDto
apiProductPlanInfoDto
;
/**
* 投保人信息
*/
private
ApiPolicyholderInfoDto
apiPolicyholderInfoDto
;
/**
* 受保人信息
*/
private
ApiInsurantInfoDto
apiInsurantInfoDto
;
/**
* 受益人列表信息
*/
private
List
<
ApiBeneficiaryInfoDto
>
apiBeneficiaryInfoDtoList
;
/**
* 第二持有人信息
*/
private
ApiSecondHolderInfoDto
apiSecondHolderInfoDto
;
/**
* 健康信息 - 答题会话对象(实际回答问题的内容)集合,对象即ApiAnswerSessionsDto,一个对象一个问卷问题
*/
private
List
<
ApiAnswerSessionsDto
>
answerSessionsDtoList
;
}
yd-csf-feign/src/main/java/com/yd/csf/feign/request/appointment/ApiAppointmentLogPageRequest.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
feign
.
request
.
appointment
;
import
com.yd.common.dto.PageDto
;
import
lombok.Data
;
@Data
public
class
ApiAppointmentLogPageRequest
extends
PageDto
{
}
yd-csf-feign/src/main/java/com/yd/csf/feign/request/common/ApiCsfCalculateRequest.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
feign
.
request
.
common
;
import
lombok.Data
;
import
javax.validation.constraints.NotNull
;
import
java.util.List
;
@Data
public
class
ApiCsfCalculateRequest
{
/**
* 计算类型 1-通过中文自动加载全部大写的拼音 2-身份证号码计算性别 3-身份证号码计算生日 4-生日计算年龄 5-身高和体重计算BMI指数 6-身份证号码计算性别/生日/年龄
*/
@NotNull
(
message
=
"计算类型不能为空"
)
private
Integer
calculateType
;
/**
* 计算请求值(单个请求参数值)
*/
private
String
requestValue
;
/**
* 计算请求值列表(多个请求参数值)
*/
private
List
<
String
>
requestValueList
;
}
yd-csf-feign/src/main/java/com/yd/csf/feign/response/appointment/ApiAppointmentDetailResponse.java
View file @
7b943b2c
...
...
@@ -11,7 +11,7 @@ import java.util.List;
public
class
ApiAppointmentDetailResponse
{
/**
* 预约状态
: 0-暂存 1-待预约, 2-待签署 3-已签署 4-已取消(字典)
* 预约状态
*/
private
Integer
status
;
...
...
yd-csf-feign/src/main/java/com/yd/csf/feign/response/appointment/ApiAppointmentLogDetailResponse.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
feign
.
response
.
appointment
;
import
com.yd.csf.feign.dto.appointment.ApiAppointmentReferrerLogDto
;
import
com.yd.csf.feign.dto.appointment.ApiAppointmentUserSignLogDto
;
import
lombok.Data
;
import
java.time.LocalDateTime
;
import
java.util.List
;
@Data
public
class
ApiAppointmentLogDetailResponse
{
/**
* 预约信息日志表主键ID
*/
private
Long
id
;
/**
* 预约信息日志表唯一业务ID
*/
private
String
appointmentLogBizId
;
/**
* 预约信息主表唯一业务ID
*/
private
String
appointmentBizId
;
/**
* 预约编号
*/
private
String
appointmentNo
;
/**
* 关联客户信息表唯一业务ID(冗余字段)
*/
private
String
customerBizId
;
/**
* 关联客户编号(和客户信息表唯一业务ID是一对,唯一,冗余字段)
*/
private
String
customerNo
;
/**
* 关联FNA信息表唯一业务ID(冗余字段)
*/
private
String
fnaBizId
;
/**
* 关联FNA编号(和FNA信息表唯一业务ID是一对,唯一,冗余字段)
*/
private
String
fnaNo
;
/**
* 关联计划书信息表唯一业务ID(冗余字段)
*/
private
String
proposalBizId
;
/**
* 关联计划书编号(和计划书信息表唯一业务ID是一对,唯一,冗余字段)
*/
private
String
proposalNo
;
/**
* 预约状态: 0-暂存 1-待预约, 2-待签署 3-已签署 4-已取消(字典)
*/
private
Integer
status
;
/**
* 申请类型(字典)
*/
private
String
applyType
;
/**
* 到港时间
*/
private
LocalDateTime
arrivalTime
;
/**
* 离港时间
*/
private
LocalDateTime
departureTime
;
/**
* 会面地点(字典)
*/
private
String
meetingPoint
;
/**
* 签单地址
*/
private
String
signingAddress
;
/**
* 客户在港期间联络电话区号
*/
private
String
hkMobileCode
;
/**
* 客户在港期间联络电话
*/
private
String
hkMobile
;
/**
* 是否开户: 0-否, 1-是(字典)
*/
private
Integer
isOpenAccount
;
/**
* 开户行名称
*/
private
String
bankName
;
/**
* 开户行支行(分行)
*/
private
String
bankBranchName
;
/**
* 开户时间段(开始)
*/
private
LocalDateTime
openAccountStartTime
;
/**
* 开户时间段(结束)
*/
private
LocalDateTime
openAccountEndTime
;
/**
* 开户地点
*/
private
String
openAccountLocation
;
/**
* 开户须知
*/
private
String
openAccountNotice
;
/**
* 是否体检: 0-否, 1-是(字典)
*/
private
Integer
isTj
;
/**
* 是否购买过香港保险: 0-否, 1-是(字典)
*/
private
Integer
isBuy
;
/**
* 转保声明选项(字典)
*/
private
String
policyTransfer
;
/**
* 是否有用车服务:0-否, 1-是(字典)
*/
private
Integer
isUseCar
;
/**
* 通用备注
*/
private
String
remark
;
/**
* 删除标识: 0-正常, 1-删除
*/
private
Integer
isDeleted
;
/**
* 创建人ID
*/
private
String
creatorId
;
/**
* 创建人用户名
*/
private
String
creatorName
;
/**
* 更新人ID
*/
private
String
updaterId
;
/**
* 创建时间
*/
private
LocalDateTime
createTime
;
/**
* 更新时间
*/
private
LocalDateTime
updateTime
;
/**
* 预约-转介人信息日志列表
*/
private
List
<
ApiAppointmentReferrerLogDto
>
referrerLogDtoList
;
/**
* 预约-签单员信息日志列表
*/
private
List
<
ApiAppointmentUserSignLogDto
>
userSignLogDtoList
;
}
yd-csf-feign/src/main/java/com/yd/csf/feign/response/appointment/ApiAppointmentLogPageResponse.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
feign
.
response
.
appointment
;
import
lombok.Data
;
import
java.time.LocalDateTime
;
@Data
public
class
ApiAppointmentLogPageResponse
{
/**
* 预约信息日志表主键ID
*/
private
Long
id
;
/**
* 预约信息日志表唯一业务ID
*/
private
String
appointmentLogBizId
;
/**
* 预约信息主表唯一业务ID
*/
private
String
appointmentBizId
;
/**
* 预约状态
*/
private
Integer
status
;
/**
* 通用备注
*/
private
String
remark
;
/**
* 创建人ID
*/
private
String
creatorId
;
/**
* 创建人用户名
*/
private
String
creatorName
;
/**
* 创建时间
*/
private
LocalDateTime
createTime
;
}
yd-csf-feign/src/main/java/com/yd/csf/feign/response/common/ApiCsfCalculateResponse.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
feign
.
response
.
common
;
import
lombok.Data
;
import
javax.validation.constraints.NotNull
;
import
java.util.List
;
@Data
public
class
ApiCsfCalculateResponse
{
/**
* 计算类型 1-通过中文自动加载全部大写的拼音 2-身份证号码计算性别 3-身份证号码计算生日 4-生日计算年龄 5-身高和体重计算BMI指数 6-身份证号码计算性别/生日/年龄
*/
@NotNull
(
message
=
"计算类型不能为空"
)
private
Integer
calculateType
;
/**
* 计算请求值(单个请求参数值)
*/
private
String
requestValue
;
/**
* 计算请求值列表(多个请求参数值)
*/
private
List
<
String
>
requestValueList
;
/**
* 计算返回值
*/
private
String
responseValue
;
}
yd-csf-feign/src/main/java/com/yd/csf/feign/valid/GroupValid.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
feign
.
valid
;
/**
* 分组校验接口
*/
public
interface
GroupValid
{
// 非本人时需要校验的组
interface
NotSelf
{}
// 总是需要校验的组
interface
Always
{}
}
\ No newline at end of file
yd-csf-service/src/main/java/com/yd/csf/service/dao/AppointmentLogMapper.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
service
.
dao
;
import
com.yd.csf.service.model.AppointmentLog
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
/**
* <p>
* 预约信息日志表(快照表) Mapper 接口
* </p>
*
* @author zxm
* @since 2025-12-15
*/
public
interface
AppointmentLogMapper
extends
BaseMapper
<
AppointmentLog
>
{
}
yd-csf-service/src/main/java/com/yd/csf/service/dao/AppointmentMapper.java
View file @
7b943b2c
...
...
@@ -2,7 +2,9 @@ package com.yd.csf.service.dao;
import
com.baomidou.mybatisplus.core.metadata.IPage
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.yd.csf.feign.request.appointment.ApiAppointmentLogPageRequest
;
import
com.yd.csf.feign.request.appointment.ApiAppointmentPageRequest
;
import
com.yd.csf.feign.response.appointment.ApiAppointmentLogPageResponse
;
import
com.yd.csf.feign.response.appointment.ApiAppointmentPageResponse
;
import
com.yd.csf.feign.dto.appointmentfile.ItineraryDto
;
import
com.yd.csf.service.model.Appointment
;
...
...
@@ -26,4 +28,7 @@ public interface AppointmentMapper extends BaseMapper<Appointment> {
ItineraryDto
getItineraryDto
(
@Param
(
"appointmentBizId"
)
String
appointmentBizId
);
Integer
updateDelStatus
(
@Param
(
"appointmentBizId"
)
String
appointmentBizId
);
IPage
<
ApiAppointmentLogPageResponse
>
logPage
(
@Param
(
"page"
)
Page
<
ApiAppointmentLogPageResponse
>
page
,
@Param
(
"request"
)
ApiAppointmentLogPageRequest
request
);
}
yd-csf-service/src/main/java/com/yd/csf/service/dao/AppointmentReferrerLogMapper.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
service
.
dao
;
import
com.yd.csf.service.model.AppointmentReferrerLog
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
/**
* <p>
* 预约-转介人信息日志表(快照表) Mapper 接口
* </p>
*
* @author zxm
* @since 2025-12-15
*/
public
interface
AppointmentReferrerLogMapper
extends
BaseMapper
<
AppointmentReferrerLog
>
{
}
yd-csf-service/src/main/java/com/yd/csf/service/dao/AppointmentReferrerMapper.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
service
.
dao
;
import
com.yd.csf.service.model.AppointmentReferrer
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
/**
* <p>
* 预约-转介人信息表 Mapper 接口
* </p>
*
* @author zxm
* @since 2025-12-15
*/
public
interface
AppointmentReferrerMapper
extends
BaseMapper
<
AppointmentReferrer
>
{
}
yd-csf-service/src/main/java/com/yd/csf/service/dao/AppointmentUserSignLogMapper.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
service
.
dao
;
import
com.yd.csf.service.model.AppointmentUserSignLog
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
/**
* <p>
* 预约-签单员信息日志表(快照表) Mapper 接口
* </p>
*
* @author zxm
* @since 2025-12-15
*/
public
interface
AppointmentUserSignLogMapper
extends
BaseMapper
<
AppointmentUserSignLog
>
{
}
yd-csf-service/src/main/java/com/yd/csf/service/dao/AppointmentUserSignMapper.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
service
.
dao
;
import
com.yd.csf.service.model.AppointmentUserSign
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
/**
* <p>
* 预约-签单员信息表 Mapper 接口
* </p>
*
* @author zxm
* @since 2025-12-15
*/
public
interface
AppointmentUserSignMapper
extends
BaseMapper
<
AppointmentUserSign
>
{
}
yd-csf-service/src/main/java/com/yd/csf/service/dao/TaxationMapper.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
service
.
dao
;
import
com.yd.csf.service.model.Taxation
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
/**
* <p>
* 税务信息表 Mapper 接口
* </p>
*
* @author zxm
* @since 2025-12-17
*/
public
interface
TaxationMapper
extends
BaseMapper
<
Taxation
>
{
}
yd-csf-service/src/main/java/com/yd/csf/service/enums/AppointmentStatusEnum.java
View file @
7b943b2c
...
...
@@ -6,10 +6,16 @@ package com.yd.csf.service.enums;
public
enum
AppointmentStatusEnum
{
//预约状态枚举
ZC
(
"暂存"
,
0
),
DYY
(
"待预约"
,
1
),
DQS
(
"待签署"
,
2
),
YQS
(
"已签署"
,
3
),
// ZC("暂存",0),
// DYY("待预约",1),
// DQS("待签署",2),
// YQS("已签署",3),
// YQX("已取消",4),
DWS
(
"待完善"
,
0
),
YYZ
(
"预约中"
,
1
),
YY_CG
(
"预约成功"
,
2
),
YQD
(
"已签单"
,
3
),
YQX
(
"已取消"
,
4
),
;
...
...
yd-csf-service/src/main/java/com/yd/csf/service/model/Appointment.java
View file @
7b943b2c
...
...
@@ -125,6 +125,12 @@ public class Appointment implements Serializable {
private
LocalDateTime
confirmAppointmentTime
;
/**
* 签单日
*/
@TableField
(
"sign_date"
)
private
LocalDateTime
signDate
;
/**
* 顾问是否陪同: 0-否, 1-是(字典)
*/
@TableField
(
"is_accompany"
)
...
...
@@ -287,6 +293,12 @@ public class Appointment implements Serializable {
private
Integer
isUseCar
;
/**
* 是否法定受益人
*/
@TableField
(
"is_legal_beneficiary"
)
private
String
isLegalBeneficiary
;
/**
* 通用备注
*/
@TableField
(
"remark"
)
...
...
yd-csf-service/src/main/java/com/yd/csf/service/model/AppointmentLog.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
service
.
model
;
import
com.baomidou.mybatisplus.annotation.IdType
;
import
com.baomidou.mybatisplus.annotation.TableField
;
import
com.baomidou.mybatisplus.annotation.TableId
;
import
com.baomidou.mybatisplus.annotation.TableName
;
import
java.io.Serializable
;
import
java.time.LocalDateTime
;
import
lombok.Getter
;
import
lombok.Setter
;
/**
* <p>
* 预约信息日志表(快照表)
* </p>
*
* @author zxm
* @since 2025-12-15
*/
@Getter
@Setter
@TableName
(
"appointment_log"
)
public
class
AppointmentLog
implements
Serializable
{
private
static
final
long
serialVersionUID
=
1L
;
@TableId
(
value
=
"id"
,
type
=
IdType
.
AUTO
)
private
Long
id
;
/**
* 预约信息日志表唯一业务ID
*/
@TableField
(
"appointment_log_biz_id"
)
private
String
appointmentLogBizId
;
/**
* 预约信息主表唯一业务ID
*/
@TableField
(
"appointment_biz_id"
)
private
String
appointmentBizId
;
/**
* 预约编号
*/
@TableField
(
"appointment_no"
)
private
String
appointmentNo
;
/**
* 关联客户信息表唯一业务ID(冗余字段)
*/
@TableField
(
"customer_biz_id"
)
private
String
customerBizId
;
/**
* 关联客户编号(和客户信息表唯一业务ID是一对,唯一,冗余字段)
*/
@TableField
(
"customer_no"
)
private
String
customerNo
;
/**
* 关联FNA信息表唯一业务ID(冗余字段)
*/
@TableField
(
"fna_biz_id"
)
private
String
fnaBizId
;
/**
* 关联FNA编号(和FNA信息表唯一业务ID是一对,唯一,冗余字段)
*/
@TableField
(
"fna_no"
)
private
String
fnaNo
;
/**
* 关联计划书信息表唯一业务ID(冗余字段)
*/
@TableField
(
"proposal_biz_id"
)
private
String
proposalBizId
;
/**
* 关联计划书编号(和计划书信息表唯一业务ID是一对,唯一,冗余字段)
*/
@TableField
(
"proposal_no"
)
private
String
proposalNo
;
/**
* 是否有其他预约同时进行: 0-否, 1-是(字典)
*/
@TableField
(
"is_together"
)
private
Integer
isTogether
;
/**
* 进行同时预约的分组编号
*/
@TableField
(
"together_group_no"
)
private
String
togetherGroupNo
;
/**
* 进行同时预约的预约编号
*/
@TableField
(
"together_appointment_no"
)
private
String
togetherAppointmentNo
;
/**
* 预约状态: 0-暂存 1-待预约, 2-待签署 3-已签署 4-已取消(字典)
*/
@TableField
(
"status"
)
private
Integer
status
;
/**
* 申请类型(字典)
*/
@TableField
(
"apply_type"
)
private
String
applyType
;
/**
* 业务编号
*/
@TableField
(
"business_no"
)
private
String
businessNo
;
/**
* 意向预约时间
*/
@TableField
(
"intention_appointment_time"
)
private
LocalDateTime
intentionAppointmentTime
;
/**
* 确定预约时间
*/
@TableField
(
"confirm_appointment_time"
)
private
LocalDateTime
confirmAppointmentTime
;
/**
* 顾问是否陪同: 0-否, 1-是(字典)
*/
@TableField
(
"is_accompany"
)
private
Integer
isAccompany
;
/**
* 陪同顾问姓名(FNA Form有填写,可带入)
*/
@TableField
(
"accompany_name"
)
private
String
accompanyName
;
/**
* 陪同顾问手机区号
*/
@TableField
(
"accompany_mobile_code"
)
private
String
accompanyMobileCode
;
/**
* 陪同顾问手机
*/
@TableField
(
"accompany_mobile"
)
private
String
accompanyMobile
;
/**
* 陪同顾问邮箱
*/
@TableField
(
"accompany_email"
)
private
String
accompanyEmail
;
/**
* 业务代表1账号
*/
@TableField
(
"business_represent_account1"
)
private
String
businessRepresentAccount1
;
/**
* 业务代表1姓名
*/
@TableField
(
"business_represent_name1"
)
private
String
businessRepresentName1
;
/**
* 业务代表1电话号码区号
*/
@TableField
(
"business_represent_mobile1_code"
)
private
String
businessRepresentMobile1Code
;
/**
* 业务代表1电话号码
*/
@TableField
(
"business_represent_mobile1"
)
private
String
businessRepresentMobile1
;
/**
* 业务代表1邮箱
*/
@TableField
(
"business_represent_email1"
)
private
String
businessRepresentEmail1
;
/**
* 到港时间
*/
@TableField
(
"arrival_time"
)
private
LocalDateTime
arrivalTime
;
/**
* 离港时间
*/
@TableField
(
"departure_time"
)
private
LocalDateTime
departureTime
;
/**
* 会面地点(字典)
*/
@TableField
(
"meeting_point"
)
private
String
meetingPoint
;
/**
* 签单地址
*/
@TableField
(
"signing_address"
)
private
String
signingAddress
;
/**
* 客户在港期间联络电话区号
*/
@TableField
(
"hk_mobile_code"
)
private
String
hkMobileCode
;
/**
* 客户在港期间联络电话
*/
@TableField
(
"hk_mobile"
)
private
String
hkMobile
;
/**
* 是否开户: 0-否, 1-是(字典)
*/
@TableField
(
"is_open_account"
)
private
Integer
isOpenAccount
;
/**
* 开户行名称
*/
@TableField
(
"bank_name"
)
private
String
bankName
;
/**
* 开户行支行(分行)
*/
@TableField
(
"bank_branch_name"
)
private
String
bankBranchName
;
/**
* 开户时间段(开始)
*/
@TableField
(
"open_account_start_time"
)
private
LocalDateTime
openAccountStartTime
;
/**
* 开户时间段(结束)
*/
@TableField
(
"open_account_end_time"
)
private
LocalDateTime
openAccountEndTime
;
/**
* 开户地点
*/
@TableField
(
"open_account_location"
)
private
String
openAccountLocation
;
/**
* 开户须知
*/
@TableField
(
"open_account_notice"
)
private
String
openAccountNotice
;
/**
* 是否体检: 0-否, 1-是(字典)
*/
@TableField
(
"is_tj"
)
private
Integer
isTj
;
/**
* 是否购买过香港保险: 0-否, 1-是(字典)
*/
@TableField
(
"is_buy"
)
private
Integer
isBuy
;
/**
* 转保声明选项(字典)
*/
@TableField
(
"policy_transfer"
)
private
String
policyTransfer
;
/**
* 是否有用车服务:0-否, 1-是(字典)
*/
@TableField
(
"is_use_car"
)
private
Integer
isUseCar
;
/**
* 通用备注
*/
@TableField
(
"remark"
)
private
String
remark
;
/**
* 删除标识: 0-正常, 1-删除
*/
@TableField
(
"is_deleted"
)
private
Integer
isDeleted
;
/**
* 创建人ID
*/
@TableField
(
"creator_id"
)
private
String
creatorId
;
/**
* 创建人用户名
*/
@TableField
(
"creator_name"
)
private
String
creatorName
;
/**
* 更新人ID
*/
@TableField
(
"updater_id"
)
private
String
updaterId
;
/**
* 创建时间
*/
@TableField
(
"create_time"
)
private
LocalDateTime
createTime
;
/**
* 更新时间
*/
@TableField
(
"update_time"
)
private
LocalDateTime
updateTime
;
}
yd-csf-service/src/main/java/com/yd/csf/service/model/AppointmentReferrer.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
service
.
model
;
import
com.baomidou.mybatisplus.annotation.IdType
;
import
com.baomidou.mybatisplus.annotation.TableField
;
import
com.baomidou.mybatisplus.annotation.TableId
;
import
com.baomidou.mybatisplus.annotation.TableName
;
import
java.io.Serializable
;
import
java.time.LocalDateTime
;
import
lombok.Getter
;
import
lombok.Setter
;
/**
* <p>
* 预约-转介人信息表
* </p>
*
* @author zxm
* @since 2025-12-15
*/
@Getter
@Setter
@TableName
(
"appointment_referrer"
)
public
class
AppointmentReferrer
implements
Serializable
{
private
static
final
long
serialVersionUID
=
1L
;
@TableId
(
value
=
"id"
,
type
=
IdType
.
AUTO
)
private
Long
id
;
/**
* 预约-转介人信息表唯一业务ID
*/
@TableField
(
"appointment_referrer_biz_id"
)
private
String
appointmentReferrerBizId
;
/**
* 预约信息主表唯一业务ID(关联)
*/
@TableField
(
"appointment_biz_id"
)
private
String
appointmentBizId
;
/**
* 系统用户-销售用户扩展表唯一业务ID(转介人,冗余)
*/
@TableField
(
"user_sale_biz_id"
)
private
String
userSaleBizId
;
/**
* 系统用户唯一业务ID(冗余)
*/
@TableField
(
"user_biz_id"
)
private
String
userBizId
;
/**
* 姓名
*/
@TableField
(
"real_name"
)
private
String
realName
;
/**
* 手机号
*/
@TableField
(
"phone"
)
private
String
phone
;
/**
* 邮箱
*/
@TableField
(
"email"
)
private
String
email
;
/**
* 通用备注
*/
@TableField
(
"remark"
)
private
String
remark
;
/**
* 删除标识: 0-正常, 1-删除
*/
@TableField
(
"is_deleted"
)
private
Integer
isDeleted
;
/**
* 创建人ID
*/
@TableField
(
"creator_id"
)
private
String
creatorId
;
/**
* 更新人ID
*/
@TableField
(
"updater_id"
)
private
String
updaterId
;
/**
* 创建时间
*/
@TableField
(
"create_time"
)
private
LocalDateTime
createTime
;
/**
* 更新时间
*/
@TableField
(
"update_time"
)
private
LocalDateTime
updateTime
;
}
yd-csf-service/src/main/java/com/yd/csf/service/model/AppointmentReferrerLog.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
service
.
model
;
import
com.baomidou.mybatisplus.annotation.IdType
;
import
com.baomidou.mybatisplus.annotation.TableField
;
import
com.baomidou.mybatisplus.annotation.TableId
;
import
com.baomidou.mybatisplus.annotation.TableName
;
import
java.io.Serializable
;
import
java.time.LocalDateTime
;
import
lombok.Getter
;
import
lombok.Setter
;
/**
* <p>
* 预约-转介人信息日志表(快照表)
* </p>
*
* @author zxm
* @since 2025-12-15
*/
@Getter
@Setter
@TableName
(
"appointment_referrer_log"
)
public
class
AppointmentReferrerLog
implements
Serializable
{
private
static
final
long
serialVersionUID
=
1L
;
@TableId
(
value
=
"id"
,
type
=
IdType
.
AUTO
)
private
Long
id
;
/**
* 预约-转介人信息日志表唯一业务ID
*/
@TableField
(
"appointment_referrer_log_biz_id"
)
private
String
appointmentReferrerLogBizId
;
/**
* 预约信息日志表唯一业务ID
*/
@TableField
(
"appointment_log_biz_id"
)
private
String
appointmentLogBizId
;
/**
* 系统用户-销售用户扩展表唯一业务ID(转介人,冗余)
*/
@TableField
(
"user_sale_biz_id"
)
private
String
userSaleBizId
;
/**
* 系统用户唯一业务ID(冗余)
*/
@TableField
(
"user_biz_id"
)
private
String
userBizId
;
/**
* 姓名
*/
@TableField
(
"real_name"
)
private
String
realName
;
/**
* 手机号
*/
@TableField
(
"phone"
)
private
String
phone
;
/**
* 邮箱
*/
@TableField
(
"email"
)
private
String
email
;
/**
* 通用备注
*/
@TableField
(
"remark"
)
private
String
remark
;
/**
* 删除标识: 0-正常, 1-删除
*/
@TableField
(
"is_deleted"
)
private
Integer
isDeleted
;
/**
* 创建人ID
*/
@TableField
(
"creator_id"
)
private
String
creatorId
;
/**
* 更新人ID
*/
@TableField
(
"updater_id"
)
private
String
updaterId
;
/**
* 创建时间
*/
@TableField
(
"create_time"
)
private
LocalDateTime
createTime
;
/**
* 更新时间
*/
@TableField
(
"update_time"
)
private
LocalDateTime
updateTime
;
}
yd-csf-service/src/main/java/com/yd/csf/service/model/AppointmentUserSign.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
service
.
model
;
import
com.baomidou.mybatisplus.annotation.IdType
;
import
com.baomidou.mybatisplus.annotation.TableField
;
import
com.baomidou.mybatisplus.annotation.TableId
;
import
com.baomidou.mybatisplus.annotation.TableName
;
import
java.io.Serializable
;
import
java.time.LocalDateTime
;
import
lombok.Getter
;
import
lombok.Setter
;
/**
* <p>
* 预约-签单员信息表
* </p>
*
* @author zxm
* @since 2025-12-15
*/
@Getter
@Setter
@TableName
(
"appointment_user_sign"
)
public
class
AppointmentUserSign
implements
Serializable
{
private
static
final
long
serialVersionUID
=
1L
;
@TableId
(
value
=
"id"
,
type
=
IdType
.
AUTO
)
private
Long
id
;
/**
* 预约-签单员信息表唯一业务ID
*/
@TableField
(
"appointment_user_sign_biz_id"
)
private
String
appointmentUserSignBizId
;
/**
* 预约信息主表唯一业务ID(关联)
*/
@TableField
(
"appointment_biz_id"
)
private
String
appointmentBizId
;
/**
* 签单用户扩展唯一业务ID(冗余)
*/
@TableField
(
"user_sign_biz_id"
)
private
String
userSignBizId
;
/**
* 系统用户唯一业务ID(冗余)
*/
@TableField
(
"user_biz_id"
)
private
String
userBizId
;
/**
* 姓名
*/
@TableField
(
"real_name"
)
private
String
realName
;
/**
* 执业编码
*/
@TableField
(
"practice_code"
)
private
String
practiceCode
;
/**
* 手机号
*/
@TableField
(
"phone"
)
private
String
phone
;
/**
* 证件类型
*/
@TableField
(
"card_type"
)
private
String
cardType
;
/**
* 证件号码
*/
@TableField
(
"card_no"
)
private
String
cardNo
;
/**
* 邮箱
*/
@TableField
(
"email"
)
private
String
email
;
/**
* 通用备注
*/
@TableField
(
"remark"
)
private
String
remark
;
/**
* 删除标识: 0-正常, 1-删除
*/
@TableField
(
"is_deleted"
)
private
Integer
isDeleted
;
/**
* 创建人ID
*/
@TableField
(
"creator_id"
)
private
String
creatorId
;
/**
* 更新人ID
*/
@TableField
(
"updater_id"
)
private
String
updaterId
;
/**
* 创建时间
*/
@TableField
(
"create_time"
)
private
LocalDateTime
createTime
;
/**
* 更新时间
*/
@TableField
(
"update_time"
)
private
LocalDateTime
updateTime
;
}
yd-csf-service/src/main/java/com/yd/csf/service/model/AppointmentUserSignLog.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
service
.
model
;
import
com.baomidou.mybatisplus.annotation.IdType
;
import
com.baomidou.mybatisplus.annotation.TableField
;
import
com.baomidou.mybatisplus.annotation.TableId
;
import
com.baomidou.mybatisplus.annotation.TableName
;
import
java.io.Serializable
;
import
java.time.LocalDateTime
;
import
lombok.Getter
;
import
lombok.Setter
;
/**
* <p>
* 预约-签单员信息日志表(快照表)
* </p>
*
* @author zxm
* @since 2025-12-15
*/
@Getter
@Setter
@TableName
(
"appointment_user_sign_log"
)
public
class
AppointmentUserSignLog
implements
Serializable
{
private
static
final
long
serialVersionUID
=
1L
;
@TableId
(
value
=
"id"
,
type
=
IdType
.
AUTO
)
private
Long
id
;
/**
* 预约-签单员信息日志表唯一业务ID
*/
@TableField
(
"appointment_user_sign_log_biz_id"
)
private
String
appointmentUserSignLogBizId
;
/**
* 预约信息日志表唯一业务ID
*/
@TableField
(
"appointment_log_biz_id"
)
private
String
appointmentLogBizId
;
/**
* 签单用户扩展唯一业务ID(冗余)
*/
@TableField
(
"user_sign_biz_id"
)
private
String
userSignBizId
;
/**
* 系统用户唯一业务ID(冗余)
*/
@TableField
(
"user_biz_id"
)
private
String
userBizId
;
/**
* 姓名
*/
@TableField
(
"real_name"
)
private
String
realName
;
/**
* 执业编码
*/
@TableField
(
"practice_code"
)
private
String
practiceCode
;
/**
* 手机号
*/
@TableField
(
"phone"
)
private
String
phone
;
/**
* 证件类型
*/
@TableField
(
"card_type"
)
private
String
cardType
;
/**
* 证件号码
*/
@TableField
(
"card_no"
)
private
String
cardNo
;
/**
* 邮箱
*/
@TableField
(
"email"
)
private
String
email
;
/**
* 通用备注
*/
@TableField
(
"remark"
)
private
String
remark
;
/**
* 删除标识: 0-正常, 1-删除
*/
@TableField
(
"is_deleted"
)
private
Integer
isDeleted
;
/**
* 创建人ID
*/
@TableField
(
"creator_id"
)
private
String
creatorId
;
/**
* 更新人ID
*/
@TableField
(
"updater_id"
)
private
String
updaterId
;
/**
* 创建时间
*/
@TableField
(
"create_time"
)
private
LocalDateTime
createTime
;
/**
* 更新时间
*/
@TableField
(
"update_time"
)
private
LocalDateTime
updateTime
;
}
yd-csf-service/src/main/java/com/yd/csf/service/model/Beneficiary.java
View file @
7b943b2c
...
...
@@ -17,7 +17,7 @@ import java.time.LocalDateTime;
* </p>
*
* @author zxm
* @since 2025-
09-02
* @since 2025-
12-18
*/
@Getter
@Setter
...
...
@@ -42,43 +42,25 @@ public class Beneficiary implements Serializable {
private
String
beneficiaryBizId
;
/**
* 客户类型(字典)(个人或者公司)
*/
@TableField
(
"customer_type"
)
private
String
customerType
;
/**
* 与受保人关系(字典)
*/
@TableField
(
"insurant_rel"
)
private
String
insurantRel
;
/**
* 受益比例
*/
@TableField
(
"benefit_ratio"
)
private
BigDecimal
benefitRatio
;
/**
* 名字
*/
@TableField
(
"name"
)
private
String
name
;
/**
* 名字-英文
* 姓名-中文
*/
@TableField
(
"name_
e
n"
)
private
String
name
E
n
;
@TableField
(
"name_
c
n"
)
private
String
name
C
n
;
/**
*
性别(字典
)
*
姓名-(拼音/英文,通过中文自动加载全部大写的拼音
)
*/
@TableField
(
"
gender
"
)
private
String
gender
;
@TableField
(
"
name_py_en
"
)
private
String
namePyEn
;
/**
* 证件类型(字典)
* 证件类型(字典
,下拉选择
)
*/
@TableField
(
"document_type"
)
private
String
documentType
;
...
...
@@ -90,112 +72,28 @@ public class Beneficiary implements Serializable {
private
String
idNumber
;
/**
*
护照号码
*
性别(字典,如果是身份证,自动获取性别和生日)
*/
@TableField
(
"passport_number"
)
private
String
passportNumber
;
/**
* 出生日期
*/
@TableField
(
"birth_time"
)
private
LocalDateTime
birthTime
;
/**
* 公司名称
*/
@TableField
(
"company_name"
)
private
String
companyName
;
/**
* 公司名称(英文)
*/
@TableField
(
"company_name_en"
)
private
String
companyNameEn
;
/**
* 公司商业登记号码
*/
@TableField
(
"company_business_no"
)
private
String
companyBusinessNo
;
/**
* 公司注册日期
*/
@TableField
(
"company_register_time"
)
private
LocalDateTime
companyRegisterTime
;
/**
* 公司注册地区(字典)
*/
@TableField
(
"company_register_region"
)
private
String
companyRegisterRegion
;
/**
* 公司电话区号
*/
@TableField
(
"company_mobile_code"
)
private
String
companyMobileCode
;
/**
* 公司电话
*/
@TableField
(
"company_mobile"
)
private
String
companyMobile
;
/**
* 公司邮箱
*/
@TableField
(
"company_email"
)
private
String
companyEmail
;
/**
* 公司登记地址
*/
@TableField
(
"company_enter_address"
)
private
String
companyEnterAddress
;
/**
* 通讯地址
*/
@TableField
(
"mailing_address"
)
private
String
mailingAddress
;
/**
* 授权代表姓名中文-名字
*/
@TableField
(
"auth_name_cn"
)
private
String
authNameCn
;
/**
* 授权代表姓名英文-名字
*/
@TableField
(
"auth_name_en"
)
private
String
authNameEn
;
/**
* 授权代表职称
*/
@TableField
(
"auth_professional"
)
private
String
authProfessional
;
@TableField
(
"gender"
)
private
String
gender
;
/**
*
授权代表电话区号
*
出生日期(生日,如果是身份证,自动获取性别和生日)
*/
@TableField
(
"
auth_mobile_code
"
)
private
String
authMobileCode
;
@TableField
(
"
birthday
"
)
private
LocalDateTime
birthday
;
/**
*
授权代表电话
*
国籍(下拉选择)
*/
@TableField
(
"
auth_mobile
"
)
private
String
authMobile
;
@TableField
(
"
nationality
"
)
private
String
nationality
;
/**
*
地址列表(json串)
*
受益比例
*/
@TableField
(
"
address_list
"
)
private
String
addressList
;
@TableField
(
"
benefit_ratio
"
)
private
BigDecimal
benefitRatio
;
/**
* 通用备注
...
...
yd-csf-service/src/main/java/com/yd/csf/service/model/Insurant.java
View file @
7b943b2c
...
...
@@ -4,15 +4,12 @@ import com.baomidou.mybatisplus.annotation.IdType;
import
com.baomidou.mybatisplus.annotation.TableField
;
import
com.baomidou.mybatisplus.annotation.TableId
;
import
com.baomidou.mybatisplus.annotation.TableName
;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
com.yd.csf.feign.dto.AddressDto
;
import
lombok.Getter
;
import
lombok.Setter
;
import
java.io.Serializable
;
import
java.math.BigDecimal
;
import
java.time.LocalDateTime
;
import
java.util.List
;
/**
* <p>
...
...
@@ -20,7 +17,7 @@ import java.util.List;
* </p>
*
* @author zxm
* @since 2025-
09-02
* @since 2025-
12-18
*/
@Getter
@Setter
...
...
@@ -33,22 +30,16 @@ public class Insurant implements Serializable {
private
Long
id
;
/**
* 预约信息主表唯一业务ID
*/
@TableField
(
"appointment_biz_id"
)
private
String
appointmentBizId
;
/**
* 受保人信息表唯一业务ID
*/
@TableField
(
"insurant_biz_id"
)
private
String
insurantBizId
;
/**
*
客户类型(字典)
*
预约信息主表唯一业务ID
*/
@TableField
(
"
customer_type
"
)
private
String
customerType
;
@TableField
(
"
appointment_biz_id
"
)
private
String
appointmentBizId
;
/**
* 关联客户信息表唯一业务ID(冗余字段)
...
...
@@ -69,25 +60,19 @@ public class Insurant implements Serializable {
private
String
policyholderRel
;
/**
*
名字
*
姓名-中文
*/
@TableField
(
"name"
)
private
String
name
;
@TableField
(
"name
_cn
"
)
private
String
name
Cn
;
/**
*
名字-英文
*
姓名-(拼音/英文,通过中文自动加载全部大写的拼音)
*/
@TableField
(
"name_en"
)
private
String
nameEn
;
@TableField
(
"name_
py_
en"
)
private
String
name
Py
En
;
/**
* 性别(字典)
*/
@TableField
(
"gender"
)
private
String
gender
;
/**
* 证件类型(字典)
* 证件类型(字典,下拉选择)
*/
@TableField
(
"document_type"
)
private
String
documentType
;
...
...
@@ -99,172 +84,190 @@ public class Insurant implements Serializable {
private
String
idNumber
;
/**
* 出生日期
* 性别(字典,如果是身份证,自动获取性别和生日)
*/
@TableField
(
"gender"
)
private
String
gender
;
/**
* 出生日期(生日,如果是身份证,自动获取性别和生日)
*/
@TableField
(
"birthday"
)
private
LocalDateTime
birthday
;
/**
* 年龄
* 年龄
(通过生日自动获取年龄)
*/
@TableField
(
"age"
)
private
String
age
;
/**
*
居住地址
*
国籍(下拉选择)
*/
@TableField
(
"
residential_address
"
)
private
String
residentialAddress
;
@TableField
(
"
nationality
"
)
private
String
nationality
;
/**
*
通讯地址
*
出生地
*/
@TableField
(
"
mailing_address
"
)
private
String
mailingAddress
;
@TableField
(
"
birthplace
"
)
private
String
birthplace
;
/**
*
移动电话区号
*
是否拥有其他国家公民身份(如美国、日本等): 0-否, 1-是(字典)
*/
@TableField
(
"
mobile_code
"
)
private
String
mobileCode
;
@TableField
(
"
is_other_country
"
)
private
String
isOtherCountry
;
/**
*
移动电话
*
吸烟情况(字典)
*/
@TableField
(
"
mobile
"
)
private
String
mobile
;
@TableField
(
"
smoking_status
"
)
private
String
smokingStatus
;
/**
*
邮箱
*
婚姻情况(字典)
*/
@TableField
(
"
email
"
)
private
String
email
;
@TableField
(
"
marital_status
"
)
private
String
maritalStatus
;
/**
*
公司名称
*
教育程度(字典)
*/
@TableField
(
"
company_name
"
)
private
String
companyName
;
@TableField
(
"
education_level
"
)
private
String
educationLevel
;
/**
*
公司地址
*
是否退休(字典)
*/
@TableField
(
"
company_address
"
)
private
String
companyAddress
;
@TableField
(
"
is_retirement
"
)
private
String
isRetirement
;
/**
*
行业
*
退休年龄(如已退休,再显示)
*/
@TableField
(
"
industry
"
)
private
String
industry
;
@TableField
(
"
retirement_age
"
)
private
String
retirementAge
;
/**
*
职位
*
身高(CM)
*/
@TableField
(
"
position
"
)
private
String
position
;
@TableField
(
"
height
"
)
private
String
height
;
/**
* 风险偏好(字典)
* 体重(KG)
*/
@TableField
(
"weight"
)
private
String
weight
;
/**
* BMI指数(根据身高和体重自动计算)
*/
@TableField
(
"bmi"
)
private
String
bmi
;
/**
* 风险偏好(字典,下拉选择)
*/
@TableField
(
"risk_appetite"
)
private
String
riskAppetite
;
/**
*
是否VIP: 0-否, 1-是(字典
)
*
受供养人数目(通过FNA带入
)
*/
@TableField
(
"
is_vip
"
)
private
Integer
isVip
;
@TableField
(
"
dependents_num
"
)
private
Integer
dependentsNum
;
/**
*
vip备注
*
移动电话区号
*/
@TableField
(
"
vip_remark
"
)
private
String
vipRemark
;
@TableField
(
"
mobile_code
"
)
private
String
mobileCode
;
/**
*
称谓(字典)
*
移动电话
*/
@TableField
(
"
appellation
"
)
private
String
appellation
;
@TableField
(
"
mobile
"
)
private
String
mobile
;
/**
*
是否区分吸烟(字典)
*
住宅电话区号
*/
@TableField
(
"
smoking_allowed
"
)
private
String
smokingAllowed
;
@TableField
(
"
residence_mobile_code
"
)
private
String
residenceMobileCode
;
/**
*
出生地(省市)
*
住宅电话
*/
@TableField
(
"
birthplac
e"
)
private
String
birthplac
e
;
@TableField
(
"
residence_mobil
e"
)
private
String
residenceMobil
e
;
/**
*
国籍
*
固定电话区号
*/
@TableField
(
"
nationality
"
)
private
String
nationality
;
@TableField
(
"
landline_code
"
)
private
String
landlineCode
;
/**
*
护照号码
*
固定电话
*/
@TableField
(
"
passport_no
"
)
private
String
passportNo
;
@TableField
(
"
landline
"
)
private
String
landline
;
/**
*
通行证号码
*
邮箱
*/
@TableField
(
"
pass_no
"
)
private
String
passNo
;
@TableField
(
"
email
"
)
private
String
email
;
/**
*
身高
*
证件地址
*/
@TableField
(
"
height
"
)
private
String
height
;
@TableField
(
"
certificate_address
"
)
private
String
certificateAddress
;
/**
*
体重
*
通讯地址
*/
@TableField
(
"
weight
"
)
private
String
weight
;
@TableField
(
"
mailing_address
"
)
private
String
mailingAddress
;
/**
*
BMI
*
居住地址(住宅地址)
*/
@TableField
(
"
bmi
"
)
private
String
bmi
;
@TableField
(
"
residential_address
"
)
private
String
residentialAddress
;
/**
*
受雇于现职年期
*
通讯地址邮政编号
*/
@TableField
(
"
current_tenur
e"
)
private
BigDecimal
currentTenur
e
;
@TableField
(
"
mailing_address_cod
e"
)
private
String
mailingAddressCod
e
;
/**
*
总负债额
*
就业情况(字典,下拉选择)
*/
@TableField
(
"
total_debt
"
)
private
BigDecimal
totalDebt
;
@TableField
(
"
employment_status
"
)
private
String
employmentStatus
;
/**
*
受供养人数目
*
公司/学校名称
*/
@TableField
(
"
dependents_num
"
)
private
Integer
dependentsNum
;
@TableField
(
"
cs_name
"
)
private
String
csName
;
/**
*
婚姻状况(字典)
*
行业
*/
@TableField
(
"
marital_status
"
)
private
String
maritalStatus
;
@TableField
(
"
industry
"
)
private
String
industry
;
/**
*
教育程度(字典)
*
现时每月收入(HKD)
*/
@TableField
(
"
education_level
"
)
private
String
educationLevel
;
@TableField
(
"
current_monthly_income
"
)
private
BigDecimal
currentMonthlyIncome
;
/**
* 总工作年期
...
...
@@ -273,10 +276,22 @@ public class Insurant implements Serializable {
private
BigDecimal
totalWorkingYears
;
/**
* 现时每月收入
* 受雇于现职年期
*/
@TableField
(
"current_tenure"
)
private
BigDecimal
currentTenure
;
/**
* 职位
*/
@TableField
(
"current_monthly_income"
)
private
BigDecimal
currentMonthlyIncome
;
@TableField
(
"position"
)
private
String
position
;
/**
* 公司地址
*/
@TableField
(
"company_address"
)
private
String
companyAddress
;
/**
* 公司电话区号
...
...
@@ -291,40 +306,34 @@ public class Insurant implements Serializable {
private
String
companyMobile
;
/**
* 固定电话区号
*/
@TableField
(
"landline_code"
)
private
String
landlineCode
;
/**
* 固定电话
* 公司地址邮政编号
*/
@TableField
(
"
landlin
e"
)
private
String
landlin
e
;
@TableField
(
"
company_address_cod
e"
)
private
String
companyAddressCod
e
;
/**
*
其他电话
*
平均每月收入(HKD)
*/
@TableField
(
"
other_mobil
e"
)
private
String
otherMobil
e
;
@TableField
(
"
month_incom
e"
)
private
BigDecimal
monthIncom
e
;
/**
*
过往一年是否所属国家以外地区居住超过182日: 0-否, 1-是(字典
)
*
平均每月支出(HKD
)
*/
@TableField
(
"
is_exceed
"
)
private
Integer
isExceed
;
@TableField
(
"
month_expenditure
"
)
private
BigDecimal
monthExpenditure
;
/**
*
是否拥有其他国家公民身份(如美国、日本等): 0-否, 1-是(字典
)
*
总流动资产(HKD
)
*/
@TableField
(
"
is_other_country
"
)
private
Integer
isOtherCountry
;
@TableField
(
"
total_current_assets
"
)
private
BigDecimal
totalCurrentAssets
;
/**
*
是否接受推广信息: 0-否, 1-是(字典
)
*
总负债额(HKD
)
*/
@TableField
(
"
is_promotion
"
)
private
Integer
isPromotion
;
@TableField
(
"
total_debt
"
)
private
BigDecimal
totalDebt
;
/**
* 旅行(字典)
...
...
@@ -333,25 +342,25 @@ public class Insurant implements Serializable {
private
String
travel
;
/**
* 运动(字典)
* 运动(字典
,下拉选择
)
*/
@TableField
(
"exercise"
)
private
String
exercise
;
/**
* 游戏(字典)
* 游戏(字典
,下拉选择
)
*/
@TableField
(
"game"
)
private
String
game
;
/**
* 电影/戏剧(字典)
* 电影/戏剧(字典
,下拉选择
)
*/
@TableField
(
"movie_drama"
)
private
String
movieDrama
;
/**
* 美食(
字典
)
* 美食(
输入
)
*/
@TableField
(
"delicacy"
)
private
String
delicacy
;
...
...
@@ -397,83 +406,4 @@ public class Insurant implements Serializable {
*/
@TableField
(
"update_time"
)
private
LocalDateTime
updateTime
;
/**
* 吸烟量(支/天)
*/
@TableField
(
"smoking_volume"
)
private
String
smokingVolume
;
/**
* 货币(字典)
*/
@TableField
(
"currency"
)
private
String
currency
;
/**
* 公司名称(英文)
*/
@TableField
(
"company_name_en"
)
private
String
companyNameEn
;
/**
* 公司商业登记号码
*/
@TableField
(
"company_business_no"
)
private
String
companyBusinessNo
;
/**
* 公司注册日期
*/
@TableField
(
"company_register_time"
)
private
LocalDateTime
companyRegisterTime
;
/**
* 公司注册地区(字典)
*/
@TableField
(
"company_register_region"
)
private
String
companyRegisterRegion
;
/**
* 公司邮箱
*/
@TableField
(
"company_email"
)
private
String
companyEmail
;
/**
* 公司登记地址
*/
@TableField
(
"company_enter_address"
)
private
String
companyEnterAddress
;
/**
* 授权代表姓名中文-名字
*/
@TableField
(
"auth_name_cn"
)
private
String
authNameCn
;
/**
* 授权代表姓名英文-名字
*/
@TableField
(
"auth_name_en"
)
private
String
authNameEn
;
/**
* 授权代表职称
*/
@TableField
(
"auth_professional"
)
private
String
authProfessional
;
/**
* 授权代表电话区号
*/
@TableField
(
"auth_mobile_code"
)
private
String
authMobileCode
;
/**
* 授权代表电话
*/
@TableField
(
"auth_mobile"
)
private
String
authMobile
;
}
yd-csf-service/src/main/java/com/yd/csf/service/model/Policyholder.java
View file @
7b943b2c
...
...
@@ -4,13 +4,11 @@ import com.baomidou.mybatisplus.annotation.IdType;
import
com.baomidou.mybatisplus.annotation.TableField
;
import
com.baomidou.mybatisplus.annotation.TableId
;
import
com.baomidou.mybatisplus.annotation.TableName
;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
lombok.Getter
;
import
lombok.Setter
;
import
java.io.Serializable
;
import
java.math.BigDecimal
;
import
java.time.LocalDateTime
;
import
lombok.Getter
;
import
lombok.Setter
;
/**
* <p>
...
...
@@ -18,7 +16,7 @@ import java.time.LocalDateTime;
* </p>
*
* @author zxm
* @since 2025-
09-02
* @since 2025-
12-18
*/
@Getter
@Setter
...
...
@@ -27,7 +25,6 @@ public class Policyholder implements Serializable {
private
static
final
long
serialVersionUID
=
1L
;
@TableId
(
value
=
"id"
,
type
=
IdType
.
AUTO
)
private
Long
id
;
...
...
@@ -44,12 +41,6 @@ public class Policyholder implements Serializable {
private
String
policyholderBizId
;
/**
* 客户类型(字典)
*/
@TableField
(
"customer_type"
)
private
String
customerType
;
/**
* 关联客户信息表唯一业务ID(冗余字段)
*/
@TableField
(
"customer_biz_id"
)
...
...
@@ -62,25 +53,19 @@ public class Policyholder implements Serializable {
private
String
customerNo
;
/**
* 名字
*/
@TableField
(
"name"
)
private
String
name
;
/**
* 名字-英文
* 姓名-中文
*/
@TableField
(
"name_
e
n"
)
private
String
name
E
n
;
@TableField
(
"name_
c
n"
)
private
String
name
C
n
;
/**
*
性别(字典
)
*
姓名-(拼音/英文,通过中文自动加载全部大写的拼音
)
*/
@TableField
(
"
gender
"
)
private
String
gender
;
@TableField
(
"
name_py_en
"
)
private
String
namePyEn
;
/**
* 证件类型(字典)
* 证件类型(字典
,下拉选择
)
*/
@TableField
(
"document_type"
)
private
String
documentType
;
...
...
@@ -92,190 +77,190 @@ public class Policyholder implements Serializable {
private
String
idNumber
;
/**
* 出生日期
* 性别(字典,如果是身份证,自动获取性别和生日)
*/
@TableField
(
"gender"
)
private
String
gender
;
/**
* 出生日期(生日,如果是身份证,自动获取性别和生日)
*/
@TableField
(
"birthday"
)
private
LocalDateTime
birthday
;
/**
* 年龄
* 年龄
(通过生日自动获取年龄)
*/
@TableField
(
"age"
)
private
String
age
;
/**
*
居住地址
*
国籍(下拉选择)
*/
@TableField
(
"
residential_address
"
)
private
String
residentialAddress
;
@TableField
(
"
nationality
"
)
private
String
nationality
;
/**
*
通讯地址
*
出生地
*/
@TableField
(
"
mailing_address
"
)
private
String
mailingAddress
;
@TableField
(
"
birthplace
"
)
private
String
birthplace
;
/**
*
移动电话区号
*
是否拥有其他国家公民身份(如美国、日本等): 0-否, 1-是(字典)
*/
@TableField
(
"
mobile_code
"
)
private
String
mobileCode
;
@TableField
(
"
is_other_country
"
)
private
String
isOtherCountry
;
/**
*
移动电话
*
吸烟情况(字典)
*/
@TableField
(
"
mobile
"
)
private
String
mobile
;
@TableField
(
"
smoking_status
"
)
private
String
smokingStatus
;
/**
*
邮箱
*
婚姻情况(字典)
*/
@TableField
(
"
email
"
)
private
String
email
;
@TableField
(
"
marital_status
"
)
private
String
maritalStatus
;
/**
*
公司名称
*
教育程度(字典)
*/
@TableField
(
"
company_name
"
)
private
String
companyName
;
@TableField
(
"
education_level
"
)
private
String
educationLevel
;
/**
*
公司地址
*
是否退休(字典)
*/
@TableField
(
"
company_address
"
)
private
String
companyAddress
;
@TableField
(
"
is_retirement
"
)
private
String
isRetirement
;
/**
*
行业
*
退休年龄(如已退休,再显示)
*/
@TableField
(
"
industry
"
)
private
String
industry
;
@TableField
(
"
retirement_age
"
)
private
String
retirementAge
;
/**
*
职位
*
身高(CM)
*/
@TableField
(
"position"
)
private
String
position
;
/**
* 风险偏好(字典)
*/
@TableField
(
"risk_appetite"
)
private
String
riskAppetite
;
@TableField
(
"height"
)
private
String
height
;
/**
*
是否VIP: 0-否, 1-是(字典)
*
体重(KG)
*/
@TableField
(
"
is_vip
"
)
private
Integer
isVip
;
@TableField
(
"
weight
"
)
private
String
weight
;
/**
*
vip备注
*
BMI指数(根据身高和体重自动计算)
*/
@TableField
(
"
vip_remark
"
)
private
String
vipRemark
;
@TableField
(
"
bmi
"
)
private
String
bmi
;
/**
*
称谓(字典
)
*
风险偏好(字典,下拉选择
)
*/
@TableField
(
"
appellation
"
)
private
String
appellation
;
@TableField
(
"
risk_appetite
"
)
private
String
riskAppetite
;
/**
*
是否区分吸烟(字典
)
*
受供养人数目(通过FNA带入
)
*/
@TableField
(
"
smoking_allowed
"
)
private
String
smokingAllowed
;
@TableField
(
"
dependents_num
"
)
private
Integer
dependentsNum
;
/**
*
出生地(省市)
*
移动电话区号
*/
@TableField
(
"
birthplac
e"
)
private
String
birthplac
e
;
@TableField
(
"
mobile_cod
e"
)
private
String
mobileCod
e
;
/**
*
国籍
*
移动电话
*/
@TableField
(
"
nationality
"
)
private
String
nationality
;
@TableField
(
"
mobile
"
)
private
String
mobile
;
/**
*
护照号码
*
住宅电话区号
*/
@TableField
(
"
passport_no
"
)
private
String
passportNo
;
@TableField
(
"
residence_mobile_code
"
)
private
String
residenceMobileCode
;
/**
*
通行证号码
*
住宅电话
*/
@TableField
(
"
pass_no
"
)
private
String
passNo
;
@TableField
(
"
residence_mobile
"
)
private
String
residenceMobile
;
/**
*
身高
*
固定电话区号
*/
@TableField
(
"
height
"
)
private
String
height
;
@TableField
(
"
landline_code
"
)
private
String
landlineCode
;
/**
*
体重
*
固定电话
*/
@TableField
(
"
weight
"
)
private
String
weight
;
@TableField
(
"
landline
"
)
private
String
landline
;
/**
*
BMI
*
邮箱
*/
@TableField
(
"
bmi
"
)
private
String
bmi
;
@TableField
(
"
email
"
)
private
String
email
;
/**
*
平均每月支出
*
证件地址
*/
@TableField
(
"
month_expenditure
"
)
private
BigDecimal
monthExpenditure
;
@TableField
(
"
certificate_address
"
)
private
String
certificateAddress
;
/**
*
平均每月收入
*
通讯地址
*/
@TableField
(
"m
onth_income
"
)
private
BigDecimal
monthIncome
;
@TableField
(
"m
ailing_address
"
)
private
String
mailingAddress
;
/**
*
受雇于现职年期
*
居住地址(住宅地址)
*/
@TableField
(
"
current_tenure
"
)
private
BigDecimal
currentTenure
;
@TableField
(
"
residential_address
"
)
private
String
residentialAddress
;
/**
*
总流动资产
*
通讯地址邮政编号
*/
@TableField
(
"
total_current_assets
"
)
private
BigDecimal
totalCurrentAssets
;
@TableField
(
"
mailing_address_code
"
)
private
String
mailingAddressCode
;
/**
*
总负债额
*
就业情况(字典,下拉选择)
*/
@TableField
(
"
total_debt
"
)
private
BigDecimal
totalDebt
;
@TableField
(
"
employment_status
"
)
private
String
employmentStatus
;
/**
*
受供养人数目
*
公司/学校名称
*/
@TableField
(
"
dependents_num
"
)
private
Integer
dependentsNum
;
@TableField
(
"
cs_name
"
)
private
String
csName
;
/**
*
婚姻状况(字典)
*
行业
*/
@TableField
(
"
marital_status
"
)
private
String
maritalStatus
;
@TableField
(
"
industry
"
)
private
String
industry
;
/**
*
教育程度(字典)
*
现时每月收入(HKD)
*/
@TableField
(
"
education_level
"
)
private
String
educationLevel
;
@TableField
(
"
current_monthly_income
"
)
private
BigDecimal
currentMonthlyIncome
;
/**
* 总工作年期
...
...
@@ -284,64 +269,64 @@ public class Policyholder implements Serializable {
private
BigDecimal
totalWorkingYears
;
/**
*
现时每月收入
*
受雇于现职年期
*/
@TableField
(
"current_
monthly_incom
e"
)
private
BigDecimal
current
MonthlyIncom
e
;
@TableField
(
"current_
tenur
e"
)
private
BigDecimal
current
Tenur
e
;
/**
*
公司电话区号
*
职位
*/
@TableField
(
"
company_mobile_code
"
)
private
String
companyMobileCode
;
@TableField
(
"
position
"
)
private
String
position
;
/**
* 公司
电话
* 公司
地址
*/
@TableField
(
"company_
mobile
"
)
private
String
company
Mobile
;
@TableField
(
"company_
address
"
)
private
String
company
Address
;
/**
*
固定
电话区号
*
公司
电话区号
*/
@TableField
(
"
landlin
e_code"
)
private
String
landlin
eCode
;
@TableField
(
"
company_mobil
e_code"
)
private
String
companyMobil
eCode
;
/**
*
固定
电话
*
公司
电话
*/
@TableField
(
"
landlin
e"
)
private
String
landlin
e
;
@TableField
(
"
company_mobil
e"
)
private
String
companyMobil
e
;
/**
*
其他电话
*
公司地址邮政编号
*/
@TableField
(
"
other_mobil
e"
)
private
String
otherMobil
e
;
@TableField
(
"
company_address_cod
e"
)
private
String
companyAddressCod
e
;
/**
*
过往一年是否所属国家以外地区居住超过182日: 0-否, 1-是(字典
)
*
平均每月收入(HKD
)
*/
@TableField
(
"
is_exceed
"
)
private
Integer
isExceed
;
@TableField
(
"
month_income
"
)
private
BigDecimal
monthIncome
;
/**
*
是否拥有其他国家公民身份(如美国、日本等): 0-否, 1-是(字典
)
*
平均每月支出(HKD
)
*/
@TableField
(
"
is_other_country
"
)
private
Integer
isOtherCountry
;
@TableField
(
"
month_expenditure
"
)
private
BigDecimal
monthExpenditure
;
/**
*
是否接受推广信息: 0-否, 1-是(字典
)
*
总流动资产(HKD
)
*/
@TableField
(
"
is_promotion
"
)
private
Integer
isPromotion
;
@TableField
(
"
total_current_assets
"
)
private
BigDecimal
totalCurrentAssets
;
/**
*
投保人邮政编码
*
总负债额(HKD)
*/
@TableField
(
"
postal_code
"
)
private
String
postalCode
;
@TableField
(
"
total_debt
"
)
private
BigDecimal
totalDebt
;
/**
* 旅行(字典)
...
...
@@ -350,31 +335,31 @@ public class Policyholder implements Serializable {
private
String
travel
;
/**
* 运动(字典)
* 运动(字典
,下拉选择
)
*/
@TableField
(
"exercise"
)
private
String
exercise
;
/**
* 游戏(字典)
* 游戏(字典
,下拉选择
)
*/
@TableField
(
"game"
)
private
String
game
;
/**
* 电影/戏剧(字典)
* 电影/戏剧(字典
,下拉选择
)
*/
@TableField
(
"movie_drama"
)
private
String
movieDrama
;
/**
* 美食(
字典
)
* 美食(
输入
)
*/
@TableField
(
"delicacy"
)
private
String
delicacy
;
/**
* 地址
信息
(json串)
* 地址
列表
(json串)
*/
@TableField
(
"address_list"
)
private
String
addressList
;
...
...
@@ -414,84 +399,4 @@ public class Policyholder implements Serializable {
*/
@TableField
(
"update_time"
)
private
LocalDateTime
updateTime
;
/**
* 吸烟量(支/天)
*/
@TableField
(
"smoking_volume"
)
private
String
smokingVolume
;
/**
* 货币(字典)
*/
@TableField
(
"currency"
)
private
String
currency
;
/**
* 公司名称(英文)
*/
@TableField
(
"company_name_en"
)
private
String
companyNameEn
;
/**
* 公司商业登记号码
*/
@TableField
(
"company_business_no"
)
private
String
companyBusinessNo
;
/**
* 公司注册日期
*/
@TableField
(
"company_register_time"
)
private
LocalDateTime
companyRegisterTime
;
/**
* 公司注册地区(字典)
*/
@TableField
(
"company_register_region"
)
private
String
companyRegisterRegion
;
/**
* 公司邮箱
*/
@TableField
(
"company_email"
)
private
String
companyEmail
;
/**
* 公司登记地址
*/
@TableField
(
"company_enter_address"
)
private
String
companyEnterAddress
;
/**
* 授权代表姓名中文-名字
*/
@TableField
(
"auth_name_cn"
)
private
String
authNameCn
;
/**
* 授权代表姓名英文-名字
*/
@TableField
(
"auth_name_en"
)
private
String
authNameEn
;
/**
* 授权代表职称
*/
@TableField
(
"auth_professional"
)
private
String
authProfessional
;
/**
* 授权代表电话区号
*/
@TableField
(
"auth_mobile_code"
)
private
String
authMobileCode
;
/**
* 授权代表电话
*/
@TableField
(
"auth_mobile"
)
private
String
authMobile
;
}
yd-csf-service/src/main/java/com/yd/csf/service/model/ProductPlan.java
View file @
7b943b2c
package
com
.
yd
.
csf
.
service
.
model
;
import
com.baomidou.mybatisplus.annotation.*
;
import
com.baomidou.mybatisplus.annotation.IdType
;
import
com.baomidou.mybatisplus.annotation.TableField
;
import
com.baomidou.mybatisplus.annotation.TableId
;
import
com.baomidou.mybatisplus.annotation.TableName
;
import
lombok.Getter
;
import
lombok.Setter
;
import
java.io.Serializable
;
import
java.math.BigDecimal
;
import
java.time.LocalDateTime
;
import
lombok.Getter
;
import
lombok.Setter
;
/**
* <p>
...
...
@@ -14,7 +17,7 @@ import lombok.Setter;
* </p>
*
* @author zxm
* @since 2025-
09-01
* @since 2025-
12-18
*/
@Getter
@Setter
...
...
@@ -23,86 +26,95 @@ public class ProductPlan implements Serializable {
private
static
final
long
serialVersionUID
=
1L
;
/**
* 产品计划信息表主键ID
*/
@TableId
(
value
=
"id"
,
type
=
IdType
.
AUTO
)
private
Long
id
;
/**
* 产品计划信息表唯一业务ID
*/
@TableField
(
"plan_biz_id"
)
private
String
planBizId
;
/**
* 预约信息主表唯一业务ID
*/
@TableField
(
"appointment_biz_id"
)
private
String
appointmentBizId
;
/**
*
产品计划信息表唯一业务ID
*
保险公司ID(产品上架信息绑定的保险公司参数)
*/
@TableField
(
"
plan_biz
_id"
)
private
String
planBiz
Id
;
@TableField
(
"
company
_id"
)
private
String
company
Id
;
/**
* 保险
产品唯一业务ID(中台保险产品业务id,冗余)
* 保险
公司名称
*/
@TableField
(
"
product_biz_id
"
)
private
String
productBizId
;
@TableField
(
"
company_name
"
)
private
String
companyName
;
/**
* 保险
产品名称(中台保险产品名称,冗余
)
* 保险
险种ID(产品上架信息绑定的保险险种参数
)
*/
@TableField
(
"
product_name
"
)
private
String
productName
;
@TableField
(
"
insurance_type_id
"
)
private
String
insuranceTypeId
;
/**
* 保险
公司名称(冗余字段)
* 保险
险种名称
*/
@TableField
(
"
company
_name"
)
private
String
company
Name
;
@TableField
(
"
insurance_type
_name"
)
private
String
insuranceType
Name
;
/**
*
地区(冗余字段)
*
产品上架信息表唯一业务ID
*/
@TableField
(
"
region
"
)
private
String
region
;
@TableField
(
"
product_launch_biz_id
"
)
private
String
productLaunchBizId
;
/**
*
货币(字典
)
*
产品上架信息表名称(标题
)
*/
@TableField
(
"
currency
"
)
private
String
currency
;
@TableField
(
"
product_launch_name
"
)
private
String
productLaunchName
;
/**
* 供款
年期(字典)
* 供款
期数
*/
@TableField
(
"
payment_term
"
)
private
String
paymentTerm
;
@TableField
(
"
issue_number
"
)
private
String
issueNumber
;
/**
*
付款频率(字典)
*
保障年期
*/
@TableField
(
"
payment_frequency
"
)
private
String
paymentFrequency
;
@TableField
(
"
guarantee_period
"
)
private
String
guaranteePeriod
;
/**
*
每期保费
*
保单币种
*/
@TableField
(
"
each_issue_premium
"
)
private
BigDecimal
eachIssuePremium
;
@TableField
(
"
policy_currency
"
)
private
String
policyCurrency
;
/**
* 保
额
* 保
单额度(重疾)
*/
@TableField
(
"sum_insured"
)
private
BigDecimal
sumInsured
;
/**
*
是否预缴保费: 0-否, 1-是
(字典)
*
付款频率
(字典)
*/
@TableField
(
"
is_prepa
y"
)
private
Integer
isPrepa
y
;
@TableField
(
"
payment_frequenc
y"
)
private
String
paymentFrequenc
y
;
/**
*
预付额
*
每期保费
*/
@TableField
(
"
deductibles
"
)
private
BigDecimal
deductibles
;
@TableField
(
"
each_issue_premium
"
)
private
BigDecimal
eachIssuePremium
;
/**
* 首期付款方式(字典)
...
...
@@ -111,40 +123,46 @@ public class ProductPlan implements Serializable {
private
String
initialPaymentMethod
;
/**
*
续期付款方式(字典)
*
保单征费
*/
@TableField
(
"
renewal_payment_method
"
)
private
String
renewalPaymentMethod
;
@TableField
(
"
policy_levy
"
)
private
BigDecimal
policyLevy
;
/**
*
红利分配方式
(字典)
*
是否预缴保费: 0-否, 1-是
(字典)
*/
@TableField
(
"
dividend_distribution_method
"
)
private
String
dividendDistributionMethod
;
@TableField
(
"
is_prepay
"
)
private
String
isPrepay
;
/**
*
保单日期回
溯: 0-否, 1-是(字典)
*
是否追
溯: 0-否, 1-是(字典)
*/
@TableField
(
"is_
backtrack
"
)
private
Integer
isBacktrack
;
@TableField
(
"is_
traceable
"
)
private
String
isTraceable
;
/**
* 保单
生效日
* 保单
日期回溯: 0-否, 1-是(字典)
*/
@TableField
(
value
=
"policy_effective_date"
,
updateStrategy
=
FieldStrategy
.
IGNORED
)
private
LocalDateTime
policyEffectiveDate
;
@TableField
(
"is_backtrack"
)
private
String
isBacktrack
;
/**
* 是否参加递增保障权益: 0-否, 1-是(字典)
*/
@TableField
(
"is_join"
)
private
Integer
isJoin
;
private
String
isJoin
;
/**
*
保单征费
*
红利分配方式(字典)
*/
@TableField
(
"policy_levy"
)
private
BigDecimal
policyLevy
;
@TableField
(
"dividend_distribution_method"
)
private
String
dividendDistributionMethod
;
/**
* 续期付款方式(字典)
*/
@TableField
(
"renewal_payment_method"
)
private
String
renewalPaymentMethod
;
/**
* 通用备注
...
...
yd-csf-service/src/main/java/com/yd/csf/service/model/SecondHolder.java
View file @
7b943b2c
...
...
@@ -4,18 +4,19 @@ import com.baomidou.mybatisplus.annotation.IdType;
import
com.baomidou.mybatisplus.annotation.TableField
;
import
com.baomidou.mybatisplus.annotation.TableId
;
import
com.baomidou.mybatisplus.annotation.TableName
;
import
java.io.Serializable
;
import
java.time.LocalDateTime
;
import
lombok.Getter
;
import
lombok.Setter
;
import
java.io.Serializable
;
import
java.time.LocalDateTime
;
/**
* <p>
* 第二持有人信息表
* </p>
*
* @author zxm
* @since 2025-
09-01
* @since 2025-
12-19
*/
@Getter
@Setter
...
...
@@ -28,43 +29,37 @@ public class SecondHolder implements Serializable {
private
Long
id
;
/**
* 预约信息主表唯一业务ID
*/
@TableField
(
"appointment_biz_id"
)
private
String
appointmentBizId
;
/**
* 第二持有人信息表唯一业务ID
*/
@TableField
(
"second_holder_biz_id"
)
private
String
secondHolderBizId
;
/**
*
与受保人关系(字典)
*
预约信息主表唯一业务ID
*/
@TableField
(
"
insurant_rel
"
)
private
String
insurantRel
;
@TableField
(
"
appointment_biz_id
"
)
private
String
appointmentBizId
;
/**
*
名字
*
与受保人关系(字典)
*/
@TableField
(
"
name
"
)
private
String
name
;
@TableField
(
"
insurant_rel
"
)
private
String
insurantRel
;
/**
*
名字-英
文
*
姓名-中
文
*/
@TableField
(
"name_
e
n"
)
private
String
name
E
n
;
@TableField
(
"name_
c
n"
)
private
String
name
C
n
;
/**
*
性别(字典
)
*
姓名-(拼音/英文,通过中文自动加载全部大写的拼音
)
*/
@TableField
(
"
gender
"
)
private
String
gender
;
@TableField
(
"
name_py_en
"
)
private
String
namePyEn
;
/**
* 证件类型(字典)
* 证件类型(字典
,下拉选择
)
*/
@TableField
(
"document_type"
)
private
String
documentType
;
...
...
@@ -76,22 +71,16 @@ public class SecondHolder implements Serializable {
private
String
idNumber
;
/**
* 护照号码
*/
@TableField
(
"passport_number"
)
private
String
passportNumber
;
/**
* 出生日期
* 性别(字典,如果是身份证,自动获取性别和生日)
*/
@TableField
(
"
birth_time
"
)
private
LocalDateTime
birthTime
;
@TableField
(
"
gender
"
)
private
String
gender
;
/**
*
年龄
*
出生日期(生日,如果是身份证,自动获取性别和生日)
*/
@TableField
(
"
age
"
)
private
String
age
;
@TableField
(
"
birthday
"
)
private
LocalDateTime
birthday
;
/**
* 通用备注
...
...
yd-csf-service/src/main/java/com/yd/csf/service/model/Taxation.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
service
.
model
;
import
com.baomidou.mybatisplus.annotation.IdType
;
import
com.baomidou.mybatisplus.annotation.TableField
;
import
com.baomidou.mybatisplus.annotation.TableId
;
import
com.baomidou.mybatisplus.annotation.TableName
;
import
java.io.Serializable
;
import
java.time.LocalDateTime
;
import
lombok.Getter
;
import
lombok.Setter
;
/**
* <p>
* 税务信息表
* </p>
*
* @author zxm
* @since 2025-12-17
*/
@Getter
@Setter
@TableName
(
"taxation"
)
public
class
Taxation
implements
Serializable
{
private
static
final
long
serialVersionUID
=
1L
;
@TableId
(
value
=
"id"
,
type
=
IdType
.
AUTO
)
private
Long
id
;
/**
* 税务信息表唯一业务ID
*/
@TableField
(
"taxation_biz_id"
)
private
String
taxationBizId
;
/**
* 对象类型
*/
@TableField
(
"object_type"
)
private
String
objectType
;
/**
* 对象所属表名(投保人表、受保人表等)
*/
@TableField
(
"object_table_name"
)
private
String
objectTableName
;
/**
* 对象名
*/
@TableField
(
"object_name"
)
private
String
objectName
;
/**
* 对象业务ID
*/
@TableField
(
"object_biz_id"
)
private
String
objectBizId
;
/**
* 税务国家
*/
@TableField
(
"tax_country"
)
private
String
taxCountry
;
/**
* 税务编号
*/
@TableField
(
"tax_id"
)
private
String
taxId
;
/**
* 通用备注
*/
@TableField
(
"remark"
)
private
String
remark
;
/**
* 删除标识: 0-正常, 1-删除
*/
@TableField
(
"is_deleted"
)
private
Integer
isDeleted
;
/**
* 创建人ID
*/
@TableField
(
"creator_id"
)
private
String
creatorId
;
/**
* 更新人ID
*/
@TableField
(
"updater_id"
)
private
String
updaterId
;
/**
* 创建时间
*/
@TableField
(
"create_time"
)
private
LocalDateTime
createTime
;
/**
* 更新时间
*/
@TableField
(
"update_time"
)
private
LocalDateTime
updateTime
;
}
yd-csf-service/src/main/java/com/yd/csf/service/service/IAppointmentLogService.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
service
.
service
;
import
com.yd.csf.service.model.AppointmentLog
;
import
com.baomidou.mybatisplus.extension.service.IService
;
/**
* <p>
* 预约信息日志表(快照表) 服务类
* </p>
*
* @author zxm
* @since 2025-12-15
*/
public
interface
IAppointmentLogService
extends
IService
<
AppointmentLog
>
{
AppointmentLog
queryOne
(
String
appointmentLogBizId
);
}
yd-csf-service/src/main/java/com/yd/csf/service/service/IAppointmentReferrerLogService.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
service
.
service
;
import
com.yd.csf.service.model.AppointmentReferrerLog
;
import
com.baomidou.mybatisplus.extension.service.IService
;
import
java.util.List
;
/**
* <p>
* 预约-转介人信息日志表(快照表) 服务类
* </p>
*
* @author zxm
* @since 2025-12-15
*/
public
interface
IAppointmentReferrerLogService
extends
IService
<
AppointmentReferrerLog
>
{
List
<
AppointmentReferrerLog
>
queryList
(
String
appointmentLogBizId
);
}
yd-csf-service/src/main/java/com/yd/csf/service/service/IAppointmentReferrerService.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
service
.
service
;
import
com.yd.csf.service.model.AppointmentReferrer
;
import
com.baomidou.mybatisplus.extension.service.IService
;
/**
* <p>
* 预约-转介人信息表 服务类
* </p>
*
* @author zxm
* @since 2025-12-15
*/
public
interface
IAppointmentReferrerService
extends
IService
<
AppointmentReferrer
>
{
Boolean
delByAppointmentBizId
(
String
appointmentBizId
);
}
yd-csf-service/src/main/java/com/yd/csf/service/service/IAppointmentService.java
View file @
7b943b2c
...
...
@@ -2,7 +2,9 @@ package com.yd.csf.service.service;
import
com.baomidou.mybatisplus.core.metadata.IPage
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.yd.csf.feign.request.appointment.ApiAppointmentLogPageRequest
;
import
com.yd.csf.feign.request.appointment.ApiAppointmentPageRequest
;
import
com.yd.csf.feign.response.appointment.ApiAppointmentLogPageResponse
;
import
com.yd.csf.feign.response.appointment.ApiAppointmentPageResponse
;
import
com.yd.csf.feign.dto.appointmentfile.ItineraryDto
;
import
com.yd.csf.service.model.Appointment
;
...
...
@@ -26,4 +28,7 @@ public interface IAppointmentService extends IService<Appointment> {
ItineraryDto
getItineraryDto
(
String
appointmentBizId
);
void
del
(
String
appointmentBizId
);
IPage
<
ApiAppointmentLogPageResponse
>
logPage
(
Page
<
ApiAppointmentLogPageResponse
>
page
,
ApiAppointmentLogPageRequest
request
);
}
yd-csf-service/src/main/java/com/yd/csf/service/service/IAppointmentUserSignLogService.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
service
.
service
;
import
com.yd.csf.service.model.AppointmentUserSignLog
;
import
com.baomidou.mybatisplus.extension.service.IService
;
import
java.util.List
;
/**
* <p>
* 预约-签单员信息日志表(快照表) 服务类
* </p>
*
* @author zxm
* @since 2025-12-15
*/
public
interface
IAppointmentUserSignLogService
extends
IService
<
AppointmentUserSignLog
>
{
List
<
AppointmentUserSignLog
>
queryList
(
String
appointmentLogBizId
);
}
yd-csf-service/src/main/java/com/yd/csf/service/service/IAppointmentUserSignService.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
service
.
service
;
import
com.yd.csf.service.model.AppointmentUserSign
;
import
com.baomidou.mybatisplus.extension.service.IService
;
/**
* <p>
* 预约-签单员信息表 服务类
* </p>
*
* @author zxm
* @since 2025-12-15
*/
public
interface
IAppointmentUserSignService
extends
IService
<
AppointmentUserSign
>
{
Boolean
delByAppointmentBizId
(
String
appointmentBizId
);
}
yd-csf-service/src/main/java/com/yd/csf/service/service/ITaxationService.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
service
.
service
;
import
com.yd.csf.service.model.Taxation
;
import
com.baomidou.mybatisplus.extension.service.IService
;
/**
* <p>
* 税务信息表 服务类
* </p>
*
* @author zxm
* @since 2025-12-17
*/
public
interface
ITaxationService
extends
IService
<
Taxation
>
{
}
yd-csf-service/src/main/java/com/yd/csf/service/service/impl/AppointmentLogServiceImpl.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
service
.
service
.
impl
;
import
com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper
;
import
com.yd.csf.service.model.AppointmentLog
;
import
com.yd.csf.service.dao.AppointmentLogMapper
;
import
com.yd.csf.service.service.IAppointmentLogService
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
org.springframework.stereotype.Service
;
/**
* <p>
* 预约信息日志表(快照表) 服务实现类
* </p>
*
* @author zxm
* @since 2025-12-15
*/
@Service
public
class
AppointmentLogServiceImpl
extends
ServiceImpl
<
AppointmentLogMapper
,
AppointmentLog
>
implements
IAppointmentLogService
{
@Override
public
AppointmentLog
queryOne
(
String
appointmentLogBizId
)
{
return
this
.
getOne
(
new
LambdaQueryWrapper
<
AppointmentLog
>().
eq
(
AppointmentLog:
:
getAppointmentLogBizId
,
appointmentLogBizId
));
}
}
yd-csf-service/src/main/java/com/yd/csf/service/service/impl/AppointmentReferrerLogServiceImpl.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
service
.
service
.
impl
;
import
com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper
;
import
com.yd.csf.service.model.AppointmentReferrerLog
;
import
com.yd.csf.service.dao.AppointmentReferrerLogMapper
;
import
com.yd.csf.service.service.IAppointmentReferrerLogService
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
org.springframework.stereotype.Service
;
import
java.util.List
;
/**
* <p>
* 预约-转介人信息日志表(快照表) 服务实现类
* </p>
*
* @author zxm
* @since 2025-12-15
*/
@Service
public
class
AppointmentReferrerLogServiceImpl
extends
ServiceImpl
<
AppointmentReferrerLogMapper
,
AppointmentReferrerLog
>
implements
IAppointmentReferrerLogService
{
@Override
public
List
<
AppointmentReferrerLog
>
queryList
(
String
appointmentLogBizId
)
{
return
this
.
baseMapper
.
selectList
(
new
LambdaQueryWrapper
<
AppointmentReferrerLog
>()
.
eq
(
AppointmentReferrerLog:
:
getAppointmentLogBizId
,
appointmentLogBizId
));
}
}
yd-csf-service/src/main/java/com/yd/csf/service/service/impl/AppointmentReferrerServiceImpl.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
service
.
service
.
impl
;
import
com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper
;
import
com.yd.csf.service.model.AppointmentReferrer
;
import
com.yd.csf.service.dao.AppointmentReferrerMapper
;
import
com.yd.csf.service.service.IAppointmentReferrerService
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
org.springframework.stereotype.Service
;
/**
* <p>
* 预约-转介人信息表 服务实现类
* </p>
*
* @author zxm
* @since 2025-12-15
*/
@Service
public
class
AppointmentReferrerServiceImpl
extends
ServiceImpl
<
AppointmentReferrerMapper
,
AppointmentReferrer
>
implements
IAppointmentReferrerService
{
@Override
public
Boolean
delByAppointmentBizId
(
String
appointmentBizId
)
{
return
this
.
remove
(
new
LambdaQueryWrapper
<
AppointmentReferrer
>().
eq
(
AppointmentReferrer:
:
getAppointmentBizId
,
appointmentBizId
));
}
}
yd-csf-service/src/main/java/com/yd/csf/service/service/impl/AppointmentServiceImpl.java
View file @
7b943b2c
...
...
@@ -3,7 +3,9 @@ package com.yd.csf.service.service.impl;
import
com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper
;
import
com.baomidou.mybatisplus.core.metadata.IPage
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.yd.csf.feign.request.appointment.ApiAppointmentLogPageRequest
;
import
com.yd.csf.feign.request.appointment.ApiAppointmentPageRequest
;
import
com.yd.csf.feign.response.appointment.ApiAppointmentLogPageResponse
;
import
com.yd.csf.feign.response.appointment.ApiAppointmentPageResponse
;
import
com.yd.csf.feign.dto.appointmentfile.ItineraryDto
;
import
com.yd.csf.service.model.Appointment
;
...
...
@@ -63,4 +65,10 @@ public class AppointmentServiceImpl extends ServiceImpl<AppointmentMapper, Appoi
baseMapper
.
updateDelStatus
(
appointmentBizId
);
}
@Override
public
IPage
<
ApiAppointmentLogPageResponse
>
logPage
(
Page
<
ApiAppointmentLogPageResponse
>
page
,
ApiAppointmentLogPageRequest
request
)
{
return
baseMapper
.
logPage
(
page
,
request
);
}
}
yd-csf-service/src/main/java/com/yd/csf/service/service/impl/AppointmentUserSignLogServiceImpl.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
service
.
service
.
impl
;
import
com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper
;
import
com.yd.csf.service.model.AppointmentUserSignLog
;
import
com.yd.csf.service.dao.AppointmentUserSignLogMapper
;
import
com.yd.csf.service.service.IAppointmentUserSignLogService
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
org.springframework.stereotype.Service
;
import
java.util.List
;
/**
* <p>
* 预约-签单员信息日志表(快照表) 服务实现类
* </p>
*
* @author zxm
* @since 2025-12-15
*/
@Service
public
class
AppointmentUserSignLogServiceImpl
extends
ServiceImpl
<
AppointmentUserSignLogMapper
,
AppointmentUserSignLog
>
implements
IAppointmentUserSignLogService
{
@Override
public
List
<
AppointmentUserSignLog
>
queryList
(
String
appointmentLogBizId
)
{
return
this
.
baseMapper
.
selectList
(
new
LambdaQueryWrapper
<
AppointmentUserSignLog
>()
.
eq
(
AppointmentUserSignLog:
:
getAppointmentLogBizId
,
appointmentLogBizId
));
}
}
yd-csf-service/src/main/java/com/yd/csf/service/service/impl/AppointmentUserSignServiceImpl.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
service
.
service
.
impl
;
import
com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper
;
import
com.yd.csf.service.model.AppointmentUserSign
;
import
com.yd.csf.service.dao.AppointmentUserSignMapper
;
import
com.yd.csf.service.service.IAppointmentUserSignService
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
org.springframework.stereotype.Service
;
/**
* <p>
* 预约-签单员信息表 服务实现类
* </p>
*
* @author zxm
* @since 2025-12-15
*/
@Service
public
class
AppointmentUserSignServiceImpl
extends
ServiceImpl
<
AppointmentUserSignMapper
,
AppointmentUserSign
>
implements
IAppointmentUserSignService
{
@Override
public
Boolean
delByAppointmentBizId
(
String
appointmentBizId
)
{
return
this
.
remove
(
new
LambdaQueryWrapper
<
AppointmentUserSign
>().
eq
(
AppointmentUserSign:
:
getAppointmentBizId
,
appointmentBizId
));
}
}
yd-csf-service/src/main/java/com/yd/csf/service/service/impl/PolicyServiceImpl.java
View file @
7b943b2c
...
...
@@ -104,7 +104,7 @@ public class PolicyServiceImpl extends ServiceImpl<PolicyMapper, Policy>
if
(
apiProductPlanMainInfoDto
!=
null
)
{
BeanUtils
.
copyProperties
(
apiProductPlanMainInfoDto
,
policy
,
"policyBizId"
,
"id"
);
policy
.
setPaymentPremium
(
apiProductPlanMainInfoDto
.
getEachIssuePremium
());
policy
.
setIsPrepaid
(
apiProductPlanMainInfoDto
.
getIsPrepay
(
));
policy
.
setIsPrepaid
(
Integer
.
parseInt
(
apiProductPlanMainInfoDto
.
getIsPrepay
()
));
policy
.
setUpdateTime
(
now
);
// 更新保单
this
.
updateById
(
policy
);
...
...
yd-csf-service/src/main/java/com/yd/csf/service/service/impl/TaxationServiceImpl.java
0 → 100644
View file @
7b943b2c
package
com
.
yd
.
csf
.
service
.
service
.
impl
;
import
com.yd.csf.service.model.Taxation
;
import
com.yd.csf.service.dao.TaxationMapper
;
import
com.yd.csf.service.service.ITaxationService
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
org.springframework.stereotype.Service
;
/**
* <p>
* 税务信息表 服务实现类
* </p>
*
* @author zxm
* @since 2025-12-17
*/
@Service
public
class
TaxationServiceImpl
extends
ServiceImpl
<
TaxationMapper
,
Taxation
>
implements
ITaxationService
{
}
yd-csf-service/src/main/java/com/yd/csf/service/utils/MyBatisPlusCodeGenerator.java
View file @
7b943b2c
...
...
@@ -5,11 +5,11 @@ import com.baomidou.mybatisplus.generator.engine.FreemarkerTemplateEngine;
public
class
MyBatisPlusCodeGenerator
{
public
static
void
main
(
String
[]
args
)
{
FastAutoGenerator
.
create
(
"jdbc:mysql://139.224.145.34:3308/yd_csf?serverTimezone=GMT%2B8"
,
"root"
,
"Zxm7320017"
)
FastAutoGenerator
.
create
(
"jdbc:mysql://139.224.145.34:3308/yd_csf
_v1
?serverTimezone=GMT%2B8"
,
"root"
,
"Zxm7320017"
)
.
globalConfig
(
builder
->
{
builder
.
author
(
"zxm"
)
//
.outputDir("src/main/java/com/yd/csf/service");
.
outputDir
(
"D:/soft/ideaproject/v2/yd-csf/yd-csf-service/src/main/java"
);
.
outputDir
(
"src/main/java/com/yd/csf/service"
);
//
.outputDir("D:/soft/ideaproject/v2/yd-csf/yd-csf-service/src/main/java");
})
.
packageConfig
(
builder
->
{
builder
.
parent
(
"com.yd.csf.service"
)
...
...
@@ -21,7 +21,7 @@ public class MyBatisPlusCodeGenerator {
})
.
strategyConfig
(
builder
->
{
builder
.
addInclude
(
"
expected_fortune_log
"
"
second_holder
"
)
.
entityBuilder
()
...
...
yd-csf-service/src/main/resources/mappers/AppointmentLogMapper.xml
0 → 100644
View file @
7b943b2c
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper
namespace=
"com.yd.csf.service.dao.AppointmentLogMapper"
>
</mapper>
yd-csf-service/src/main/resources/mappers/AppointmentMapper.xml
View file @
7b943b2c
...
...
@@ -81,6 +81,13 @@
limit 1
</select>
<select
id=
"logPage"
resultType=
"com.yd.csf.feign.response.appointment.ApiAppointmentLogPageResponse"
>
select al.* from appointment_log al
<where>
and al.is_deleted = 0
</where>
</select>
<!-- 更新预约状态 -->
<update
id=
"updateDelStatus"
>
update appointment set is_deleted = 1 where appointment_biz_id = #{appointmentBizId};
...
...
yd-csf-service/src/main/resources/mappers/AppointmentReferrerLogMapper.xml
0 → 100644
View file @
7b943b2c
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper
namespace=
"com.yd.csf.service.dao.AppointmentReferrerLogMapper"
>
</mapper>
yd-csf-service/src/main/resources/mappers/AppointmentReferrerMapper.xml
0 → 100644
View file @
7b943b2c
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper
namespace=
"com.yd.csf.service.dao.AppointmentReferrerMapper"
>
</mapper>
yd-csf-service/src/main/resources/mappers/AppointmentUserSignLogMapper.xml
0 → 100644
View file @
7b943b2c
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper
namespace=
"com.yd.csf.service.dao.AppointmentUserSignLogMapper"
>
</mapper>
yd-csf-service/src/main/resources/mappers/AppointmentUserSignMapper.xml
0 → 100644
View file @
7b943b2c
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper
namespace=
"com.yd.csf.service.dao.AppointmentUserSignMapper"
>
</mapper>
yd-csf-service/src/main/resources/mappers/TaxationMapper.xml
0 → 100644
View file @
7b943b2c
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper
namespace=
"com.yd.csf.service.dao.TaxationMapper"
>
</mapper>
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment