Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
Y
yd-backend
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
AutogeneralShanghai
yd-backend
Commits
2961d4fb
Commit
2961d4fb
authored
Jun 11, 2020
by
Water Wang
Browse files
Options
Browse Files
Download
Plain Diff
resolve conflict
parents
ac543027
2636be9b
Show whitespace changes
Inline
Side-by-side
Showing
69 changed files
with
4245 additions
and
94 deletions
+4245
-94
yd-api/src/main/java/com/yd/api/practitioner/PractitionerController.java
+33
-0
yd-api/src/main/java/com/yd/api/practitioner/service/PractitionerPolicyService.java
+24
-0
yd-api/src/main/java/com/yd/api/practitioner/service/impl/PractitionerPolicyServiceImpl.java
+343
-0
yd-api/src/main/java/com/yd/api/practitioner/service/impl/PractitionerServiceImpl.java
+190
-56
yd-api/src/main/java/com/yd/api/practitioner/vo/policy/PolicyInfo.java
+9
-0
yd-api/src/main/java/com/yd/api/practitioner/vo/policy/PolicyListQueryRequestVO.java
+22
-0
yd-api/src/main/java/com/yd/api/practitioner/vo/policy/PolicyListQueryResponseVO.java
+28
-0
yd-api/src/main/java/com/yd/api/practitioner/vo/policy/policyinfoquery/BuildingOrderInfo.java
+37
-0
yd-api/src/main/java/com/yd/api/practitioner/vo/policy/policyinfoquery/DestinationInfo.java
+31
-0
yd-api/src/main/java/com/yd/api/practitioner/vo/policy/policyinfoquery/EleInvoiceInfo.java
+23
-0
yd-api/src/main/java/com/yd/api/practitioner/vo/policy/policyinfoquery/HolderInfo.java
+4
-0
yd-api/src/main/java/com/yd/api/practitioner/vo/policy/policyinfoquery/IDInfo.java
+85
-0
yd-api/src/main/java/com/yd/api/practitioner/vo/policy/policyinfoquery/InsureFactorInfo.java
+123
-0
yd-api/src/main/java/com/yd/api/practitioner/vo/policy/policyinfoquery/InsuredBirthAddressInfo.java
+41
-0
yd-api/src/main/java/com/yd/api/practitioner/vo/policy/policyinfoquery/InsuredInfo.java
+66
-0
yd-api/src/main/java/com/yd/api/practitioner/vo/policy/policyinfoquery/LifeProductElementInfo.java
+94
-0
yd-api/src/main/java/com/yd/api/practitioner/vo/policy/policyinfoquery/PersonBasicInfo.java
+156
-0
yd-api/src/main/java/com/yd/api/practitioner/vo/policy/policyinfoquery/PolicyFactorInfo.java
+148
-0
yd-api/src/main/java/com/yd/api/practitioner/vo/policy/policyinfoquery/PolicyInfoQueryRequestVO.java
+65
-0
yd-api/src/main/java/com/yd/api/practitioner/vo/policy/policyinfoquery/PolicyInfoQueryResponseVO.java
+166
-0
yd-api/src/main/java/com/yd/api/practitioner/vo/policy/policyinfoquery/ProductInfo.java
+89
-0
yd-api/src/main/java/com/yd/api/practitioner/vo/policy/policyinfoquery/ReferralInfo.java
+22
-0
yd-api/src/main/java/com/yd/api/practitioner/vo/policy/policyinfoquery/RenewBankInfo.java
+78
-0
yd-api/src/main/java/com/yd/api/practitioner/vo/policy/policyinfoquery/UndQueInfo.java
+39
-0
yd-api/src/main/java/com/yd/api/practitioner/vo/policy/policyinfoquery/VehicleOrderInfo.java
+46
-0
yd-api/src/main/java/com/yd/dal/entity/customer/practitioner/PractitionerBasicInfo.java
+1
-0
yd-api/src/main/java/com/yd/dal/entity/customer/practitioner/SubordinateSystemMemberInfoE.java
+76
-0
yd-api/src/main/java/com/yd/dal/entity/meta/OptionsEGolden.java
+49
-0
yd-api/src/main/java/com/yd/dal/entity/order/CustomerPolicyInfo.java
+148
-0
yd-api/src/main/java/com/yd/dal/entity/order/PolicyDetailInfoE.java
+292
-0
yd-api/src/main/java/com/yd/dal/entity/order/PolicyFactorInfoE.java
+58
-0
yd-api/src/main/java/com/yd/dal/entity/product/Product.java
+133
-0
yd-api/src/main/java/com/yd/dal/entity/product/ProductE.java
+22
-0
yd-api/src/main/java/com/yd/dal/entity/product/ProductPlan.java
+148
-0
yd-api/src/main/java/com/yd/dal/mapper/customer/AclCustomerMapper.java
+7
-1
yd-api/src/main/java/com/yd/dal/mapper/customer/AclPractitionerMapper.java
+9
-0
yd-api/src/main/java/com/yd/dal/mapper/customer/AclPractitionerSubordinateSystemMapper.java
+6
-3
yd-api/src/main/java/com/yd/dal/mapper/marketing/MktLeadsGoalsMapper.java
+3
-0
yd-api/src/main/java/com/yd/dal/mapper/meta/MdDropOptionsMapper.java
+4
-0
yd-api/src/main/java/com/yd/dal/mapper/order/PoOrderMapper.java
+14
-0
yd-api/src/main/java/com/yd/dal/mapper/product/ProductMapper.java
+25
-0
yd-api/src/main/java/com/yd/dal/mapper/product/ProductPlanMapper.java
+22
-0
yd-api/src/main/java/com/yd/dal/service/customer/AclCustomerDALService.java
+2
-0
yd-api/src/main/java/com/yd/dal/service/customer/AclPractitionerDALService.java
+37
-0
yd-api/src/main/java/com/yd/dal/service/customer/AclPractitionerSubordinateSystemDALService.java
+4
-0
yd-api/src/main/java/com/yd/dal/service/customer/impl/AclCustomerDALServiceImpl.java
+5
-0
yd-api/src/main/java/com/yd/dal/service/customer/impl/AclPractitionerDALServiceImpl.java
+33
-0
yd-api/src/main/java/com/yd/dal/service/customer/impl/AclPractitionerSubordinateSystemDALServiceImpl.java
+15
-0
yd-api/src/main/java/com/yd/dal/service/marketing/Impl/MktLeadsGoalsDALServiceImpl.java
+5
-0
yd-api/src/main/java/com/yd/dal/service/marketing/MktLeadsGoalsDALService.java
+2
-0
yd-api/src/main/java/com/yd/dal/service/meta/MdDropOptionsDALService.java
+3
-0
yd-api/src/main/java/com/yd/dal/service/meta/impl/MdDropOptionsDALServiceImpl.java
+9
-0
yd-api/src/main/java/com/yd/dal/service/order/Impl/PoOrderDALServiceImpl.java
+34
-0
yd-api/src/main/java/com/yd/dal/service/order/PoOrderDALService.java
+13
-0
yd-api/src/main/java/com/yd/dal/service/product/ProductDALService.java
+14
-0
yd-api/src/main/java/com/yd/dal/service/product/ProductPlanDALService.java
+12
-0
yd-api/src/main/java/com/yd/dal/service/product/impl/ProductDALServiceImpl.java
+29
-0
yd-api/src/main/java/com/yd/dal/service/product/impl/ProductPlanDALServiceImpl.java
+19
-0
yd-api/src/main/resources/application-dev.properties
+3
-3
yd-api/src/main/resources/application-local.properties
+3
-3
yd-api/src/main/resources/mapper/customer/AclCustomerFortuneMapper.xml
+3
-3
yd-api/src/main/resources/mapper/customer/AclCustomerMapper.xml
+10
-0
yd-api/src/main/resources/mapper/customer/AclPractitionerMapper.xml
+128
-22
yd-api/src/main/resources/mapper/customer/AclPractitionerSubordinateSystemMapper.xml
+35
-0
yd-api/src/main/resources/mapper/marketing/MktLeadsGoalsMapper.xml
+10
-0
yd-api/src/main/resources/mapper/meta/MdDropOptionsMapper.xml
+13
-0
yd-api/src/main/resources/mapper/order/PoOrderMapper.xml
+122
-3
yd-api/src/main/resources/mapper/product/ProductMapper.xml
+337
-0
yd-api/src/main/resources/mapper/product/ProductPlanMapper.xml
+366
-0
No files found.
yd-api/src/main/java/com/yd/api/practitioner/PractitionerController.java
View file @
2961d4fb
package
com
.
yd
.
api
.
practitioner
;
import
com.yd.api.practitioner.service.PractitionerPolicyService
;
import
com.yd.api.practitioner.service.PractitionerService
;
import
com.yd.api.practitioner.vo.login.PractitionerLoginRequestVO
;
import
com.yd.api.practitioner.vo.login.PractitionerLoginResponseVO
;
import
com.yd.api.practitioner.vo.media.MediaGetReqVO
;
import
com.yd.api.practitioner.vo.media.MediaGetRespVO
;
import
com.yd.api.practitioner.vo.opportunity.*
;
import
com.yd.api.practitioner.vo.policy.PolicyListQueryRequestVO
;
import
com.yd.api.practitioner.vo.policy.PolicyListQueryResponseVO
;
import
com.yd.api.practitioner.vo.policy.policyinfoquery.PolicyInfoQueryRequestVO
;
import
com.yd.api.practitioner.vo.policy.policyinfoquery.PolicyInfoQueryResponseVO
;
import
com.yd.api.practitioner.vo.rank.PractitionerRankRequestVO
;
import
com.yd.api.practitioner.vo.rank.PractitionerRankResponseVO
;
import
com.yd.api.practitioner.vo.recruit.*
;
...
...
@@ -27,6 +32,8 @@ public class PractitionerController {
@Autowired
private
PractitionerService
practitionerService
;
@Autowired
private
PractitionerPolicyService
practitionerPolicyService
;
/**
* 经纪人登录
...
...
@@ -407,5 +414,31 @@ public class PractitionerController {
result
.
addResult
(
responseVO
);
return
result
;
}
/**
* 经纪人保单列表查询接口
* @param requestVO 请求信息
* @return PolicyListQueryResponseVO
*/
@RequestMapping
(
"/policyListQuery"
)
public
Object
practitionerPolicyListQuery
(
@RequestBody
PolicyListQueryRequestVO
requestVO
){
JsonResult
result
=
new
JsonResult
();
PolicyListQueryResponseVO
responseVO
=
practitionerPolicyService
.
policyListQuery
(
requestVO
);
result
.
setData
(
responseVO
);
result
.
addResult
(
responseVO
);
return
result
;
}
/**
* 经纪人保单详情查询接口
* @param requestVO 请求信息
* @return PolicyInfoQueryResponseVO
*/
@RequestMapping
(
"/policyInfoQuery"
)
public
Object
policyInfoQuery
(
@RequestBody
PolicyInfoQueryRequestVO
requestVO
){
JsonResult
result
=
new
JsonResult
();
PolicyInfoQueryResponseVO
responseVO
=
practitionerPolicyService
.
policyInfoQuery
(
requestVO
);
result
.
setData
(
responseVO
);
result
.
addResult
(
responseVO
);
return
result
;
}
}
yd-api/src/main/java/com/yd/api/practitioner/service/PractitionerPolicyService.java
0 → 100644
View file @
2961d4fb
package
com
.
yd
.
api
.
practitioner
.
service
;
import
com.yd.api.practitioner.vo.policy.PolicyListQueryRequestVO
;
import
com.yd.api.practitioner.vo.policy.PolicyListQueryResponseVO
;
import
com.yd.api.practitioner.vo.policy.policyinfoquery.PolicyInfoQueryRequestVO
;
import
com.yd.api.practitioner.vo.policy.policyinfoquery.PolicyInfoQueryResponseVO
;
import
org.springframework.stereotype.Service
;
@Service
(
"practitionerPolicyService"
)
public
interface
PractitionerPolicyService
{
/**
* 经纪人保单列表查询
* @param requestVO 请求信息
* @return PolicyListQueryResponseVO
*/
PolicyListQueryResponseVO
policyListQuery
(
PolicyListQueryRequestVO
requestVO
);
/**
* 经纪人保单详情查询
* @param requestVO 请求信息
* @return PolicyInfoQueryResponseVO
*/
PolicyInfoQueryResponseVO
policyInfoQuery
(
PolicyInfoQueryRequestVO
requestVO
);
}
yd-api/src/main/java/com/yd/api/practitioner/service/impl/PractitionerPolicyServiceImpl.java
0 → 100644
View file @
2961d4fb
package
com
.
yd
.
api
.
practitioner
.
service
.
impl
;
import
com.google.common.base.Strings
;
import
com.yd.api.practitioner.service.PractitionerPolicyService
;
import
com.yd.api.practitioner.vo.policy.PolicyInfo
;
import
com.yd.api.practitioner.vo.policy.PolicyListQueryRequestVO
;
import
com.yd.api.practitioner.vo.policy.PolicyListQueryResponseVO
;
import
com.yd.api.practitioner.vo.policy.policyinfoquery.*
;
import
com.yd.api.result.CommonResult
;
import
com.yd.dal.entity.customer.AclPractitioner
;
import
com.yd.dal.entity.meta.OptionsEGolden
;
import
com.yd.dal.entity.order.CustomerPolicyInfo
;
import
com.yd.dal.entity.order.PolicyDetailInfoE
;
import
com.yd.dal.entity.order.PolicyFactorInfoE
;
import
com.yd.dal.entity.product.Product
;
import
com.yd.dal.entity.product.ProductE
;
import
com.yd.dal.entity.product.ProductPlan
;
import
com.yd.dal.service.customer.AclPractitionerDALService
;
import
com.yd.dal.service.meta.MdDropOptionsDALService
;
import
com.yd.dal.service.order.PoOrderDALService
;
import
com.yd.dal.service.product.ProductDALService
;
import
com.yd.dal.service.product.ProductPlanDALService
;
import
com.yd.util.CommonUtil
;
import
com.yd.util.config.ZHBErrorConfig
;
import
org.springframework.beans.BeanUtils
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
java.util.*
;
@Service
(
"practitionerPolicyService"
)
public
class
PractitionerPolicyServiceImpl
implements
PractitionerPolicyService
{
@Autowired
private
AclPractitionerDALService
aclPractitionerDALService
;
@Autowired
private
PoOrderDALService
poOrderDALService
;
@Autowired
private
ProductPlanDALService
productPlanDALService
;
@Autowired
private
ProductDALService
productDALService
;
@Autowired
private
MdDropOptionsDALService
mdDropOptionsDALService
;
@Override
public
PolicyListQueryResponseVO
policyListQuery
(
PolicyListQueryRequestVO
requestVO
)
{
PolicyListQueryResponseVO
responseVO
=
new
PolicyListQueryResponseVO
();
Long
practitionerId
=
requestVO
.
getPractitionerId
();
if
(
practitionerId
!=
null
){
String
mobileNo
=
aclPractitionerDALService
.
findMobileNoByPractitionerId
(
practitionerId
);
if
(!
Strings
.
isNullOrEmpty
(
mobileNo
)
&&
mobileNo
.
length
()
==
11
){
List
<
PolicyInfo
>
policyInfoList
=
new
ArrayList
<>();
Integer
time
=
requestVO
.
getTime
();
//1、线上
getPolicyListForYD
(
policyInfoList
,
practitionerId
,
time
);
//2、线下
getPolicyListForEGolden
(
policyInfoList
,
mobileNo
,
time
);
responseVO
.
setPolicyInfoList
(
policyInfoList
);
Collections
.
sort
(
policyInfoList
);
responseVO
.
setCommonResult
(
new
CommonResult
(
true
,
ZHBErrorConfig
.
getErrorInfo
(
"800000"
)));
}
else
{
responseVO
.
setCommonResult
(
new
CommonResult
(
false
,
ZHBErrorConfig
.
getErrorInfo
(
"820001"
)));
}
}
else
{
String
[]
params
=
{
"practitionerId"
};
responseVO
.
setCommonResult
(
new
CommonResult
(
false
,
ZHBErrorConfig
.
getErrorInfo
(
"610001"
,
params
)));
}
return
responseVO
;
}
@Override
public
PolicyInfoQueryResponseVO
policyInfoQuery
(
PolicyInfoQueryRequestVO
requestVO
)
{
PolicyInfoQueryResponseVO
responseVO
=
new
PolicyInfoQueryResponseVO
();
String
orderNo
=
requestVO
.
getOrderNo
();
String
policyNo
=
requestVO
.
getPolicyNo
();
if
(!
Strings
.
isNullOrEmpty
(
orderNo
)
||
!
Strings
.
isNullOrEmpty
(
policyNo
)){
Integer
platform
=
requestVO
.
getPlatform
();
platform
=
(
platform
==
null
)
?
1
:
platform
;
if
(
platform
==
2
){
//EGolden
//1、EGolden--获取orderNo
orderNo
=
(
Strings
.
isNullOrEmpty
(
orderNo
))
?
getOrderNoE
(
policyNo
)
:
orderNo
;
//2、根据orderNo获取保单和被保人的相关数据
List
<
PolicyDetailInfoE
>
policyDetailInfoES
=
poOrderDALService
.
findPolicyDetailsInfoByOrderNoE
(
orderNo
);
if
(!
policyDetailInfoES
.
isEmpty
()){
getResponseMessage
(
responseVO
,
policyDetailInfoES
);
responseVO
.
setCommonResult
(
new
CommonResult
(
true
,
ZHBErrorConfig
.
getErrorInfo
(
"800000"
)));
}
}
else
if
(
platform
==
1
){
//YD
responseVO
.
setCommonResult
(
new
CommonResult
(
true
,
ZHBErrorConfig
.
getErrorInfo
(
"800000"
)));
}
}
else
{
String
[]
params
=
{
"orderNo,policyNo"
};
responseVO
.
setCommonResult
(
new
CommonResult
(
false
,
ZHBErrorConfig
.
getErrorInfo
(
"610002"
,
params
)));
}
return
responseVO
;
}
private
String
getOrderNoE
(
String
policyNo
)
{
String
orderNo
=
null
;
if
(!
Strings
.
isNullOrEmpty
(
policyNo
)){
orderNo
=
poOrderDALService
.
findOrderNoByPolicyNo
(
policyNo
);
}
return
orderNo
;
}
private
void
getResponseMessage
(
PolicyInfoQueryResponseVO
responseVO
,
List
<
PolicyDetailInfoE
>
policyDetailInfoES
)
{
if
(!
policyDetailInfoES
.
isEmpty
()){
List
<
Integer
>
materIds
=
Arrays
.
asList
(
20
,
16
,
116
,
101
,
19
,
50
);
// 20 保单状态,16 缴费频率, 116 发佣状态, 101 保单类别, 19 保额单位,50 与投保人关系
List
<
OptionsEGolden
>
optionsEGoldenList
=
mdDropOptionsDALService
.
findByMasterIdsE
(
materIds
);
Map
<
Integer
,
Map
<
String
,
String
>>
masterMap
=
getMasterMap
(
optionsEGoldenList
);
//查询保单因子相关信息
Set
<
String
>
orderNoSet
=
new
HashSet
<>();
policyDetailInfoES
.
forEach
(
i
->
orderNoSet
.
add
(
i
.
getOrderNo
()));
List
<
String
>
orderNoList
=
new
ArrayList
<>(
orderNoSet
);
List
<
PolicyFactorInfoE
>
policyFactorInfoES
=
poOrderDALService
.
findPolicyFactorByOrderNosE
(
orderNoList
);
Map
<
String
,
PolicyFactorInfoE
>
policyFactorInfoEMap
=
new
HashMap
<>();
policyFactorInfoES
.
forEach
(
i
->
policyFactorInfoEMap
.
put
(
i
.
getProductId
(),
i
));
//拼装返回报文
String
productId
;
PolicyFactorInfoE
policyFactorInfoE
;
List
<
PolicyFactorInfo
>
PolicyFactorInfoList
=
new
ArrayList
<>();
PolicyFactorInfo
policyFactorInfo
;
HolderInfo
holderInfo
;
List
<
InsuredInfo
>
insuredInfos
;
InsuredInfo
insuredInfo
;
IDInfo
idInfo
;
String
relationShip
;
double
orderPrice
=
0
d
,
commission
=
0
d
;
boolean
success
=
false
;
for
(
PolicyDetailInfoE
item
:
policyDetailInfoES
){
productId
=
item
.
getProductId
();
policyFactorInfoE
=
policyFactorInfoEMap
.
get
(
productId
);
policyFactorInfo
=
new
PolicyFactorInfo
();
BeanUtils
.
copyProperties
(
item
,
policyFactorInfo
);
BeanUtils
.
copyProperties
(
policyFactorInfoE
,
policyFactorInfo
);
policyFactorInfo
.
setPolicyType
(
masterMap
.
get
(
101
).
get
(
item
.
getPolicyType
()));
policyFactorInfo
.
setPayFrequency
(
masterMap
.
get
(
16
).
get
(
item
.
getPayFrequency
()));
policyFactorInfo
.
setPayCommissionStatus
(
masterMap
.
get
(
116
).
get
(
item
.
getPayCommissionStatus
()));
policyFactorInfo
.
setAmountUnit
(
masterMap
.
get
(
19
).
get
(
policyFactorInfoE
.
getAmountUnit
()));
policyFactorInfo
.
setCommissionType
(
getCommissionType
(
item
.
getCommissionType
()));
policyFactorInfo
.
setRelationship
(
masterMap
.
get
(
50
).
get
(
policyFactorInfoE
.
getRelationship
()));
PolicyFactorInfoList
.
add
(
policyFactorInfo
);
relationShip
=
policyFactorInfoE
.
getRelationship
();
if
(
item
.
getPremium
()
!=
null
)
orderPrice
=
(
item
.
getPremium
()
!=
null
)
?
orderPrice
+
item
.
getPremium
()
:
orderPrice
;
commission
=
(
item
.
getCommission
()
!=
null
)
?
commission
+
item
.
getCommission
()
:
commission
;
if
(!
success
){
responseVO
.
setOrderNo
(
item
.
getOrderNo
());
responseVO
.
setPolicyNo
(
item
.
getPolicyNo
());
responseVO
.
setOrderDate
(
item
.
getOrderDate
());
responseVO
.
setStartDate
(
item
.
getStartDate
());
responseVO
.
setEndDate
(
item
.
getEndDate
());
responseVO
.
setStatus
(
masterMap
.
get
(
20
).
get
(
item
.
getPolicyStatus
()));
holderInfo
=
new
HolderInfo
();
holderInfo
.
setName
(
item
.
getHolderName
());
holderInfo
.
setMobileNo
(
item
.
getHolderMobileNo
());
holderInfo
.
setGender
(
"1"
.
equals
(
item
.
getHolderSex
())
?
1
:
2
);
holderInfo
.
setBirthDay
(
item
.
getHolderBirthday
());
holderInfo
.
setAge
(
CommonUtil
.
getAge
(
CommonUtil
.
stringParseDate
(
item
.
getHolderBirthday
(),
"yyyy-MM-dd"
)));
idInfo
=
new
IDInfo
();
idInfo
.
setIdType
(
getIdType
(
item
.
getHolderIdNoType
()));
idInfo
.
setIdNo
(
item
.
getHolderIdNo
());
holderInfo
.
setIdInfo
(
idInfo
);
responseVO
.
setHolderInfo
(
holderInfo
);
idInfo
=
new
IDInfo
();
idInfo
.
setIdType
(
getIdType
(
item
.
getInsuredIdNoType
()));
idInfo
.
setIdNo
(
item
.
getInsuredIdNo
());
insuredInfos
=
new
ArrayList
<>();
insuredInfo
=
new
InsuredInfo
();
insuredInfo
.
setName
(
item
.
getInsuredName
());
insuredInfo
.
setRelationType
(
getRelationType
(
relationShip
));
insuredInfo
.
setMobileNo
(
item
.
getInsuredMobileNo
());
insuredInfo
.
setGender
(
"1"
.
equals
(
item
.
getInsuredSex
())
?
1
:
2
);
insuredInfo
.
setBirthDay
(
item
.
getInsuredBirthday
());
insuredInfo
.
setAge
(
CommonUtil
.
getAge
(
CommonUtil
.
stringParseDate
(
item
.
getInsuredBirthday
(),
"yyyy-MM-dd"
)));
insuredInfo
.
setIdInfo
(
idInfo
);
insuredInfos
.
add
(
insuredInfo
);
responseVO
.
setInsuredInfos
(
insuredInfos
);
success
=
true
;
}
}
responseVO
.
setPrice
(
CommonUtil
.
doubleFormat
(
orderPrice
,
2
));
ReferralInfo
referralInfo
=
new
ReferralInfo
();
referralInfo
.
setReferralAmount
(
CommonUtil
.
doubleFormat
(
commission
,
2
));
responseVO
.
setReferralInfo
(
referralInfo
);
responseVO
.
setPolicyFactorInfos
(
PolicyFactorInfoList
);
}
}
private
Long
getIdType
(
String
holderIdNoType
)
{
//1-身份证,2-护照,3-港澳身份证,4-台胞证,9-其他,20-组织机构代码
switch
(
holderIdNoType
){
case
"1"
:
return
1L
;
case
"2"
:
return
2L
;
case
"3"
:
return
9L
;
case
"4"
:
return
4L
;
case
"5"
:
return
3L
;
case
"6"
:
return
20L
;
case
"7"
:
return
9L
;
}
return
9L
;
}
private
String
getCommissionType
(
String
commissionType
)
{
switch
(
commissionType
){
case
"B01"
:
return
"前期欠款"
;
case
"N01"
:
return
"个人直展年终奖"
;
case
"P01"
:
return
"直展营销佣金"
;
case
"P02"
:
return
"保险公司奖励金"
;
case
"PS1"
:
return
"主管第13个月继续率"
;
case
"PS2"
:
return
"主管第25个月继续率"
;
case
"PS3"
:
return
"主管第37个月继续率"
;
case
"PS4"
:
return
"主管第49个月继续率"
;
case
"R01"
:
return
"续年度服务津贴"
;
case
"S01"
:
return
"首年度销售佣金"
;
case
"S02"
:
return
"续年度销售佣金"
;
case
"S03"
:
return
"首年度辅导奖金"
;
case
"S04"
:
return
"续年度辅导奖金"
;
case
"S05"
:
return
"首年度管理奖金"
;
case
"S06"
:
return
"续年度管理奖金"
;
case
"S07"
:
return
"平阶推介奖金"
;
case
"S08"
:
return
"低阶推介奖金"
;
case
"S09"
:
return
"高阶推介奖金"
;
case
"S10"
:
return
"跨体系推介奖金"
;
case
"S11"
:
return
"体系推介奖金"
;
case
"S12"
:
return
"保险公司奖励金"
;
case
"S13"
:
return
"公司活动奖金"
;
case
"S14"
:
return
"特别管理奖金"
;
case
"S15"
:
return
"引荐体系奖金"
;
case
"S16"
:
return
"引荐人奖金"
;
case
"W01"
:
return
"代扣所得税"
;
case
"W02"
:
return
"代扣个人增值税"
;
case
"W03"
:
return
"代扣城建税"
;
case
"W05"
:
return
"邮寄费"
;
case
"W06"
:
return
"保险公司加扣款"
;
// case "W06": return "欠款上扣主管";
case
"Y01"
:
return
"应税其他加扣款"
;
// case "W01": return "代扣所得税";
}
return
null
;
}
private
Long
getRelationType
(
String
relationShip
)
{
if
(
"8"
.
equals
(
relationShip
)){
return
1L
;
}
else
if
(
"14"
.
equals
(
relationShip
))
{
return
2L
;
}
else
if
(
"3"
.
equals
(
relationShip
))
{
return
4L
;
}
else
if
(
"6"
.
equals
(
relationShip
))
{
return
3L
;
}
else
{
return
5L
;
}
}
private
Map
<
Integer
,
Map
<
String
,
String
>>
getMasterMap
(
List
<
OptionsEGolden
>
optionsEGoldenList
)
{
Map
<
Integer
,
Map
<
String
,
String
>>
masterMap
=
new
HashMap
<>();
if
(!
optionsEGoldenList
.
isEmpty
()){
Map
<
String
,
String
>
optMap
;
Integer
mstId
;
for
(
OptionsEGolden
item
:
optionsEGoldenList
){
mstId
=
item
.
getMstId
();
if
(
masterMap
.
containsKey
(
mstId
)){
optMap
=
masterMap
.
get
(
mstId
);
optMap
.
put
(
item
.
getOptAttr
(),
item
.
getOptName
());
}
else
{
optMap
=
new
HashMap
<>();
optMap
.
put
(
item
.
getOptAttr
(),
item
.
getOptName
());
masterMap
.
put
(
mstId
,
optMap
);
}
}
}
return
masterMap
;
}
/**
* EGolden--查询经纪人保单列表
* @param policyInfoList 保单列表
* @param mobileNo 手机号码
* @param time 时间段
*/
private
void
getPolicyListForEGolden
(
List
<
PolicyInfo
>
policyInfoList
,
String
mobileNo
,
Integer
time
)
{
if
(!
Strings
.
isNullOrEmpty
(
mobileNo
)){
PolicyInfo
policyInfo
;
List
<
CustomerPolicyInfo
>
policyInfos
=
poOrderDALService
.
findPolicyInfoByMobileNoE
(
mobileNo
,
time
);
if
(!
policyInfos
.
isEmpty
()){
String
productId
;
Map
<
String
,
String
>
productNameMap
=
new
HashMap
<>();
List
<
ProductE
>
products
=
productDALService
.
findAllE
();
products
.
forEach
(
i
->
productNameMap
.
put
(
i
.
getProductId
(),
i
.
getProductName
()));
for
(
CustomerPolicyInfo
item
:
policyInfos
){
policyInfo
=
new
PolicyInfo
();
productId
=
item
.
getProductName
();
BeanUtils
.
copyProperties
(
item
,
policyInfo
);
policyInfo
.
setProductName
(
productNameMap
.
get
(
productId
));
policyInfo
.
setPlatform
(
2
);
policyInfoList
.
add
(
policyInfo
);
}
}
}
}
/**
* 银盾保险在线--查询经纪人保单列表
* @param policyInfoList 保单列表
* @param practitionerId 经纪人id
* @param time 时间段
*/
private
void
getPolicyListForYD
(
List
<
PolicyInfo
>
policyInfoList
,
Long
practitionerId
,
Integer
time
)
{
if
(
practitionerId
!=
null
){
AclPractitioner
practitioner
=
aclPractitionerDALService
.
findById
(
practitionerId
);
Long
customerId
=
practitioner
.
getCustomerId
();
if
(
customerId
!=
null
){
List
<
CustomerPolicyInfo
>
policyInfos
=
poOrderDALService
.
findPolicyInfoByCustomerId
(
customerId
,
time
);
if
(!
policyInfos
.
isEmpty
()){
PolicyInfo
policyInfo
;
Map
<
Long
,
String
>
planNameMap
=
new
HashMap
<>();
Map
<
Long
,
String
>
productNameMap
=
new
HashMap
<>();
List
<
ProductPlan
>
plans
=
productPlanDALService
.
findAll
();
List
<
Product
>
products
=
productDALService
.
findAll
();
products
.
forEach
(
i
->
productNameMap
.
put
(
i
.
getId
(),
i
.
getName
()));
plans
.
forEach
(
i
->
planNameMap
.
put
(
i
.
getId
(),
i
.
getName
()));
Long
planId
;
for
(
CustomerPolicyInfo
item
:
policyInfos
){
planId
=
item
.
getPlanId
();
policyInfo
=
new
PolicyInfo
();
BeanUtils
.
copyProperties
(
item
,
policyInfo
);
if
(
planId
!=
null
){
policyInfo
.
setPlanName
(
planNameMap
.
get
(
planId
));
policyInfo
.
setNoPlanProduct
(
false
);
}
else
{
policyInfo
.
setProductName
(
productNameMap
.
get
(
item
.
getProductId
()));
policyInfo
.
setNoPlanProduct
(
true
);
}
policyInfo
.
setPlatform
(
1
);
policyInfoList
.
add
(
policyInfo
);
}
}
}
}
}
}
yd-api/src/main/java/com/yd/api/practitioner/service/impl/PractitionerServiceImpl.java
View file @
2961d4fb
...
...
@@ -31,7 +31,6 @@ import com.yd.dal.entity.marketing.MktLeadsAssignedTrack;
import
com.yd.dal.entity.marketing.MktLeadsAssigneds
;
import
com.yd.dal.entity.marketing.MktLeadsGoals
;
import
com.yd.dal.entity.marketing.MktLeadsPool
;
import
com.yd.dal.entity.meta.*
;
import
com.yd.dal.entity.practitioner.opportunity.OwnOpportunityInfo
;
import
com.yd.dal.entity.order.PoOrder
;
import
com.yd.dal.entity.practitioner.opportunity.PlayerSalesActivityInfo
;
...
...
@@ -56,7 +55,6 @@ import com.yd.rmi.tencent.wechatinterf.pojo.token.TokenRequest;
import
com.yd.util.CommonUtil
;
import
com.yd.util.HttpUtil
;
import
com.yd.util.config.ZHBErrorConfig
;
import
com.yd.util.deshandler.DESTypeHandler
;
import
org.apache.commons.beanutils.BeanPropertyValueEqualsPredicate
;
import
org.apache.commons.collections.CollectionUtils
;
import
org.springframework.beans.BeanUtils
;
...
...
@@ -247,15 +245,18 @@ public class PractitionerServiceImpl implements com.yd.api.practitioner.service.
platform
=
(
platform
==
null
)
?
1
:
platform
;
if
(!
Strings
.
isNullOrEmpty
(
mobileNo
)){
//查询该手机号码的经纪人id,是否存在
PractitionerBasicInfo
practitionerBasicInfo
=
getPractitionerBasicInfo
(
mobileNo
,
platform
);
Map
<
Integer
,
PractitionerBasicInfo
>
practitionerBasicInfoMap
=
getPractitionerBasicInfo
(
mobileNo
);
if
(!
practitionerBasicInfoMap
.
isEmpty
()){
PractitionerBasicInfo
practitionerBasicInfo
=
practitionerBasicInfoMap
.
get
(
platform
);
if
(
practitionerBasicInfo
!=
null
){
String
practitionerId
=
practitionerBasicInfo
.
getPractitionerId
();
if
(!
Strings
.
isNullOrEmpty
(
practitionerId
)){
List
<
PractitionerRankInfo
>
rankInfoList
=
getPractitionerRankInfo
(
time
,
platform
);
//按照指定类型排序
getPractitionerRankResult
(
responseVO
,
rankInfoList
,
type
,
practitionerId
);
getPractitionerRankResult
(
responseVO
,
rankInfoList
,
type
,
practitionerBasicInfoMap
,
time
,
platform
);
responseVO
.
setCommonResult
(
new
CommonResult
(
true
,
ZHBErrorConfig
.
getErrorInfo
(
"800000"
)));
}
}
}
else
{
responseVO
.
setCommonResult
(
new
CommonResult
(
false
,
ZHBErrorConfig
.
getErrorInfo
(
"830001"
)));
//该经纪人不存在
}
...
...
@@ -284,25 +285,25 @@ public class PractitionerServiceImpl implements com.yd.api.practitioner.service.
return
rankInfoList
;
}
private
PractitionerBasicInfo
getPractitionerBasicInfo
(
String
mobileNo
,
Integer
platform
)
{
PractitionerBasicInfo
practitionerBasicInfo
;
if
(
platform
==
1
){
practitionerBasicInfo
=
aclPractitionerDALService
.
getPractitionerBasicInfoForOnline
(
mobileNo
);
if
(
practitionerBasicInfo
!=
null
){
Long
practitionerId
=
practitionerBasicInfo
.
getPractitionerIdForOnline
();
private
Map
<
Integer
,
PractitionerBasicInfo
>
getPractitionerBasicInfo
(
String
mobileNo
)
{
Map
<
Integer
,
PractitionerBasicInfo
>
practitionerBasicInfoMap
=
new
HashMap
<>();
PractitionerBasicInfo
practitionerBasicInfo1
=
aclPractitionerDALService
.
getPractitionerBasicInfoForOnline
(
mobileNo
);
if
(
practitionerBasicInfo1
!=
null
){
Long
practitionerId
=
practitionerBasicInfo1
.
getPractitionerIdForOnline
();
if
(
practitionerId
!=
null
){
practitionerBasicInfo
.
setPractitionerId
(
practitionerId
.
toString
());
practitionerBasicInfo1
.
setPractitionerId
(
practitionerId
.
toString
());
practitionerBasicInfoMap
.
put
(
1
,
practitionerBasicInfo1
);
}
}
}
else
{
practitionerBasicInfo
=
aclPractitionerDALService
.
getPractitionerBasicInfoForOffline
(
mobileNo
);
}
return
practitionerBasicInfo
;
PractitionerBasicInfo
practitionerBasicInfo2
=
aclPractitionerDALService
.
getPractitionerBasicInfoForOffline
(
mobileNo
);
practitionerBasicInfoMap
.
put
(
2
,
practitionerBasicInfo2
);
return
practitionerBasicInfoMap
;
}
private
void
getPractitionerRankResult
(
PractitionerRankResponseVO
responseVO
,
List
<
PractitionerRankInfo
>
rankInfoList
,
Integer
type
,
String
practitionerId
)
{
private
void
getPractitionerRankResult
(
PractitionerRankResponseVO
responseVO
,
List
<
PractitionerRankInfo
>
rankInfoList
,
Integer
type
,
Map
<
Integer
,
PractitionerBasicInfo
>
practitionerBasicInfoMap
,
Integer
time
,
Integer
platform
)
{
PractitionerInfoForAchievement
practitionerInfo
=
new
PractitionerInfoForAchievement
(
0
D
,
0
D
,
0
);
List
<
AclCustomerFortuneStatistics
>
rankList
=
new
ArrayList
<>();
String
practitionerId
=
practitionerBasicInfoMap
.
get
(
platform
).
getPractitionerId
();
if
(!
rankInfoList
.
isEmpty
()){
//排序---1-保费,2-佣金,3-件数
if
(
2
==
type
){
...
...
@@ -340,10 +341,41 @@ public class PractitionerServiceImpl implements com.yd.api.practitioner.service.
rank
++;
}
}
disposalPractitionerInfo
(
practitionerInfo
,
practitionerBasicInfoMap
,
time
,
platform
);
responseVO
.
setPractitionerInfo
(
practitionerInfo
);
responseVO
.
setRank
(
rankList
);
}
private
void
disposalPractitionerInfo
(
PractitionerInfoForAchievement
practitionerInfo
,
Map
<
Integer
,
PractitionerBasicInfo
>
practitionerBasicInfoMap
,
Integer
time
,
Integer
platform
)
{
Double
fyc
=
practitionerInfo
.
getFyc
();
PractitionerRankInfo
practitionerRankInfo
=
null
;
Double
fycOther
;
PractitionerBasicInfo
practitionerBasicInfoYD
=
practitionerBasicInfoMap
.
get
(
1
);
if
(
practitionerBasicInfoYD
!=
null
){
String
practitionerIdYD
=
practitionerBasicInfoYD
.
getPractitionerId
();
if
(!
Strings
.
isNullOrEmpty
(
practitionerIdYD
)){
Long
practitionerId
=
Long
.
parseLong
(
practitionerIdYD
);
if
(
platform
==
1
){
PractitionerBasicInfo
practitionerBasicInfoEG
=
practitionerBasicInfoMap
.
get
(
2
);
if
(
practitionerBasicInfoEG
!=
null
){
String
practitionerIdEG
=
practitionerBasicInfoEG
.
getPractitionerId
();
if
(!
Strings
.
isNullOrEmpty
(
practitionerIdEG
)){
practitionerRankInfo
=
aclPractitionerDALService
.
getPractitionerRankInfoByPractitionerIdEG
(
practitionerIdEG
,
time
);
}
}
}
else
{
practitionerRankInfo
=
aclPractitionerDALService
.
getPractitionerRankInfoByPractitionerIdYD
(
practitionerId
,
time
);
}
fycOther
=
practitionerRankInfo
!=
null
?
practitionerRankInfo
.
getFyc
()
:
0
D
;
Double
fycSum
=
CommonUtil
.
doubleFormat
(
fyc
+
fycOther
,
2
);
if
(
fycSum
!=
0
){
Double
completeRate
=
getCompletionRate
(
practitionerId
,
null
,
fycSum
,
time
);
practitionerInfo
.
setCompletionRate
(
completeRate
);
}
}
}
}
@Override
@SuppressWarnings
(
"unchecked"
)
public
SettingQueryResponseVO
settingQuery
(
SettingQueryRequestVO
requestVO
)
{
...
...
@@ -2300,28 +2332,148 @@ public class PractitionerServiceImpl implements com.yd.api.practitioner.service.
Long
subordinateSystemId
=
subordinateSystem
.
getId
();
Integer
time
=
requestVO
.
getTime
();
time
=
(
time
==
null
)
?
1
:
time
;
List
<
SubordinateSystemMemberInfo
>
memberInfoList
=
new
ArrayList
<>();
SubordinateSystemStatisticInfo
statisticInfo
=
new
SubordinateSystemStatisticInfo
();
//2、查询该团队长所在体系的所有成员
List
<
AclPractitioner
>
practitionerList
=
aclPractitionerDALService
.
findBySubordinateSystemId
(
subordinateSystemId
);
String
mobileNo
=
aclPractitionerDALService
.
findMobileNoByPractitionerId
(
practitionerId
);
double
fypSum
=
0
D
,
fycSum
=
0
D
;
int
countSum
=
0
;
SubordinateSystemStatisticInfo
statisticInfo
=
new
SubordinateSystemStatisticInfo
();
Map
<
String
,
SubordinateSystemMemberInfo
>
memberInfoMap
=
new
HashMap
<>();
//银盾保险在线
getMemberInfoForOnLine
(
memberInfoMap
,
subordinateSystemId
,
time
);
//eGolden
getMemberInfoForEGolden
(
memberInfoMap
,
mobileNo
,
time
);
//查询出来的结果按照fyp进行排序
List
<
SubordinateSystemMemberInfo
>
memberInfoList
=
new
ArrayList
<>(
memberInfoMap
.
values
());
memberInfoList
.
sort
(
Comparator
.
comparingDouble
(
SubordinateSystemMemberInfo:
:
getFyp
));
Collections
.
reverse
(
memberInfoList
);
for
(
SubordinateSystemMemberInfo
item
:
memberInfoList
){
fypSum
+=
item
.
getFyp
();
fycSum
+=
item
.
getFyc
();
countSum
+=
item
.
getCount
();
}
statisticInfo
.
setCount
(
countSum
);
statisticInfo
.
setFyc
(
CommonUtil
.
doubleFormat
(
fycSum
,
2
));
statisticInfo
.
setFyp
(
CommonUtil
.
doubleFormat
(
fypSum
,
2
));
statisticInfo
.
setCompletionRate
(
getCompletionRate
(
null
,
subordinateSystemId
,
fycSum
,
time
));
responseVO
.
setId
(
subordinateSystemId
);
responseVO
.
setSubordinateSystemName
(
subordinateSystem
.
getName
());
responseVO
.
setContactName
(
subordinateSystem
.
getContactName
());
responseVO
.
setContactNo
(
subordinateSystem
.
getContactNo
());
responseVO
.
setRemark
(
subordinateSystem
.
getRemark
());
responseVO
.
setStatisticInfo
(
statisticInfo
);
responseVO
.
setMemberInfoList
(
memberInfoList
);
responseVO
.
setCommonResult
(
new
CommonResult
(
true
,
ZHBErrorConfig
.
getErrorInfo
(
"800000"
)));
}
else
{
responseVO
.
setCommonResult
(
new
CommonResult
(
false
,
ZHBErrorConfig
.
getErrorInfo
(
"830017"
)));
}
}
else
{
String
[]
params
=
{
"practitionerId"
};
responseVO
.
setCommonResult
(
new
CommonResult
(
false
,
ZHBErrorConfig
.
getErrorInfo
(
"610001"
,
params
)));
}
return
responseVO
;
}
/**
* EGolden体系中的成员信息
* @param memberInfoMap 成员类型
* @param mobileNo 团队长手机号码
* @param time 时间
*/
private
void
getMemberInfoForEGolden
(
Map
<
String
,
SubordinateSystemMemberInfo
>
memberInfoMap
,
String
mobileNo
,
Integer
time
)
{
if
(!
Strings
.
isNullOrEmpty
(
mobileNo
)
&&
mobileNo
.
length
()
==
11
){
//1、通过手机号码查询用户
PractitionerBasicInfo
practitionerBasicInfo
=
aclPractitionerDALService
.
findByMobileNoE
(
mobileNo
);
//2、判断该用户是否是为团队长
if
(
practitionerBasicInfo
!=
null
){
String
practitionerId
=
practitionerBasicInfo
.
getPractitionerId
();
if
(!
Strings
.
isNullOrEmpty
(
practitionerId
)){
PractitionerSubordinateInfo
subordinateInfo
=
aclPractitionerSubordinateSystemDALService
.
findByOwnerE
(
practitionerId
);
if
(
subordinateInfo
!=
null
){
//3、通过团队长编号查询出该团队下的所有成员
String
subordinateIdForEGolden
=
subordinateInfo
.
getSubordinateCode
();
List
<
SubordinateSystemMemberInfoE
>
subordinateSystemMemberInfoEList
=
aclPractitionerSubordinateSystemDALService
.
findStatisticsE
(
subordinateIdForEGolden
,
time
);
if
(!
subordinateSystemMemberInfoEList
.
isEmpty
()){
String
mobileNoForMember
;
SubordinateSystemMemberInfo
memberInfo
;
Double
fyp
,
fyc
;
Integer
count
;
//4、根据id查询出所有的成员的fyc和fyp
for
(
SubordinateSystemMemberInfoE
item
:
subordinateSystemMemberInfoEList
){
mobileNoForMember
=
getMobileNo
(
item
.
getMobileNo
());
if
(
memberInfoMap
.
containsKey
(
mobileNoForMember
)){
memberInfo
=
memberInfoMap
.
get
(
mobileNoForMember
);
fyp
=
memberInfo
.
getFyp
();
fyc
=
memberInfo
.
getFyc
();
count
=
memberInfo
.
getCount
();
memberInfo
.
setFyc
(
CommonUtil
.
doubleFormat
(
fyc
+
item
.
getFyc
(),
2
));
memberInfo
.
setFyp
(
CommonUtil
.
doubleFormat
(
fyp
+
item
.
getFyp
(),
2
));
memberInfo
.
setCount
(
count
+
item
.
getCount
());
}
else
{
memberInfo
=
new
SubordinateSystemMemberInfo
();
BeanUtils
.
copyProperties
(
item
,
memberInfo
);
memberInfoMap
.
put
(
mobileNoForMember
,
memberInfo
);
}
}
}
}
}
}
}
}
/**
* 获取EGOlden中的手机号码
* @param mobileNo 手机号码
* @return 校验后的手机号码
*/
private
String
getMobileNo
(
String
mobileNo
)
{
if
(!
Strings
.
isNullOrEmpty
(
mobileNo
)
&&
mobileNo
.
length
()
>
11
){
if
(
mobileNo
.
contains
(
" "
)){
String
[]
mobiles
=
mobileNo
.
split
(
" "
);
return
mobiles
[
1
];
}
}
return
mobileNo
;
}
/**
* 银盾在线查询体系中的成员信息
* @param memberInfoMap 成员类型
* @param subordinateSystemId 体系id
* @param time 时间
*/
private
void
getMemberInfoForOnLine
(
Map
<
String
,
SubordinateSystemMemberInfo
>
memberInfoMap
,
Long
subordinateSystemId
,
Integer
time
)
{
//1、查询该团队长所在体系的所有成员
List
<
AclPractitioner
>
practitionerList
=
aclPractitionerDALService
.
findBySubordinateSystemId
(
subordinateSystemId
);
if
(!
practitionerList
.
isEmpty
()
&&
practitionerList
.
get
(
0
)
!=
null
){
Map
<
Long
,
Long
>
customerMap
=
new
HashMap
<>();
Map
<
Long
,
String
>
practitionerIdMobileNoMap
=
new
HashMap
<>();
List
<
Long
>
practitionerIds
=
new
ArrayList
<>();
practitionerList
.
forEach
(
i
->
practitionerIds
.
add
(
i
.
getId
()));
//3、查询该体系下经纪人的财富订单统计
List
<
Long
>
customerIds
=
new
ArrayList
<>();
for
(
AclPractitioner
item
:
practitionerList
){
practitionerIds
.
add
(
item
.
getId
());
customerIds
.
add
(
item
.
getCustomerId
());
customerMap
.
put
(
item
.
getCustomerId
(),
item
.
getId
());
}
//2、查询该体系下经纪人的财富订单统计
List
<
AclCustomerFortuneStatistics
>
customerFortuneStatistics
=
aclCustomerFortuneDALService
.
findBySubordinateSystemStatistics
(
subordinateSystemId
,
time
);
Map
<
Long
,
AclCustomerFortuneStatistics
>
customerFortuneStatisticsMap
=
new
HashMap
<>();
customerFortuneStatistics
.
forEach
(
i
->
customerFortuneStatisticsMap
.
put
(
i
.
getPractitionerId
(),
i
));
//
获取所有成员的级别
//3、
获取所有成员的级别
List
<
AclPractitionerSetting
>
practitionerSettings
=
aclpractitionersettingDALService
.
findByPractitionerIdList
(
practitionerIds
);
Map
<
Long
,
Long
>
practitionerSettingMap
=
new
HashMap
<>();
practitionerSettings
.
forEach
(
i
->
practitionerSettingMap
.
put
(
i
.
getPractitionerId
(),
i
.
getPractitionerLevel
()));
//
获取所有经纪人登记的基础信息
//4、
获取所有经纪人登记的基础信息
List
<
MdDropOptions
>
practitionerLevelInfo
=
mdDropOptionsDALService
.
findByDropMasterCode
(
"practitioner_level"
);
//5L
Map
<
Long
,
String
>
levelInfoNameMap
=
new
HashMap
<>()
,
levelInfoCodeMap
=
new
HashMap
<>();
practitionerLevelInfo
.
forEach
(
i
->
levelInfoNameMap
.
put
(
i
.
getId
(),
i
.
getDropOptionName
()));
practitionerLevelInfo
.
forEach
(
i
->
levelInfoCodeMap
.
put
(
i
.
getId
(),
i
.
getDropOptionCode
()));
//5、查询所以经纪人手机号码
List
<
AclCustomer
>
customerList
=
aclCustomerDALService
.
findByIds
(
customerIds
);
customerList
.
forEach
(
i
->
practitionerIdMobileNoMap
.
put
(
customerMap
.
get
(
i
.
getId
()),
i
.
getMobileNo
()));
// for(AclCustomer item : customerList){
// practitionerIdMobileNoMap.put(customerMap.get(item.getId()),item.getMobileNo());
// }
SubordinateSystemMemberInfo
memberInfo
;
Long
practitionerIdForMember
,
practitionerLevelId
;
AclCustomerFortuneStatistics
customerFortuneStatisticsItem
;
...
...
@@ -2340,58 +2492,40 @@ public class PractitionerServiceImpl implements com.yd.api.practitioner.service.
fyc
=
customerFortuneStatisticsItem
.
getFyc
();
fyp
=
customerFortuneStatisticsItem
.
getFyp
();
count
=
customerFortuneStatisticsItem
.
getCount
();
fycSum
=
fycSum
+
fyc
;
fypSum
=
fypSum
+
fyp
;
countSum
=
countSum
+
count
;
}
memberInfo
.
setFyc
(
CommonUtil
.
doubleFormat
(
fyc
,
2
));
memberInfo
.
setFyp
(
CommonUtil
.
doubleFormat
(
fyp
,
2
));
memberInfo
.
setCount
(
count
);
memberInfoList
.
add
(
memberInfo
);
}
}
//查询出来的结果按照fyp进行排序
memberInfoList
.
sort
(
Comparator
.
comparingDouble
(
SubordinateSystemMemberInfo:
:
getFyp
));
Collections
.
reverse
(
memberInfoList
);
statisticInfo
.
setCount
(
countSum
);
statisticInfo
.
setFyc
(
CommonUtil
.
doubleFormat
(
fycSum
,
2
));
statisticInfo
.
setFyp
(
CommonUtil
.
doubleFormat
(
fypSum
,
2
));
statisticInfo
.
setCompletionRate
(
getCompletionRate
(
subordinateSystemId
,
fycSum
,
time
));
responseVO
.
setId
(
subordinateSystemId
);
responseVO
.
setSubordinateSystemName
(
subordinateSystem
.
getName
());
responseVO
.
setContactName
(
subordinateSystem
.
getContactName
());
responseVO
.
setContactNo
(
subordinateSystem
.
getContactNo
());
responseVO
.
setRemark
(
subordinateSystem
.
getRemark
());
responseVO
.
setStatisticInfo
(
statisticInfo
);
responseVO
.
setMemberInfoList
(
memberInfoList
);
responseVO
.
setCommonResult
(
new
CommonResult
(
true
,
ZHBErrorConfig
.
getErrorInfo
(
"800000"
)));
}
else
{
responseVO
.
setCommonResult
(
new
CommonResult
(
false
,
ZHBErrorConfig
.
getErrorInfo
(
"830054"
)));
memberInfoMap
.
put
(
practitionerIdMobileNoMap
.
get
(
practitionerIdForMember
),
memberInfo
);
}
}
else
{
String
[]
params
=
{
"practitionerId"
};
responseVO
.
setCommonResult
(
new
CommonResult
(
false
,
ZHBErrorConfig
.
getErrorInfo
(
"610001"
,
params
)));
}
return
responseVO
;
}
/**
* 获取团队的完成率
* 获取完成率
* @param practitionerId 经纪人Id
* @param subordinateSystemId 团队长ID
* @param fycSum 总的FYC
* @param time 时间
* @return 完成率
*/
private
Double
getCompletionRate
(
Long
subordinateSystemId
,
Double
fycSum
,
Integer
time
)
{
if
(
subordinateSystemId
!=
null
&&
fycSum
!=
null
&&
time
!=
null
&&
fycSum
>
0
){
private
Double
getCompletionRate
(
Long
practitionerId
,
Long
subordinateSystemId
,
Double
fycSum
,
Integer
time
)
{
if
(
(
practitionerId
!=
null
||
subordinateSystemId
!=
null
)
&&
fycSum
!=
null
&&
time
!=
null
&&
fycSum
>
0
){
List
<
MktLeadsGoals
>
leadsGoals
;
Double
goalsPremium
=
null
;
if
(
time
==
2
){
if
(
practitionerId
!=
null
){
leadsGoals
=
mktLeadsGoalsDALService
.
findByTypeAndTimeUnitAndPractitionerId
(
1
,
1
,
practitionerId
);
}
else
{
leadsGoals
=
mktLeadsGoalsDALService
.
findByTypeAndTimeUnitAndSubordinateSystemId
(
2
,
1
,
subordinateSystemId
);
}
goalsPremium
=
(
leadsGoals
!=
null
&&
leadsGoals
.
size
()
>
0
)
?
leadsGoals
.
get
(
0
).
getCommission
()
:
null
;
}
else
{
if
(
practitionerId
!=
null
){
leadsGoals
=
mktLeadsGoalsDALService
.
findByTypeAndTimeUnitAndPractitionerId
(
1
,
3
,
practitionerId
);
}
else
{
leadsGoals
=
mktLeadsGoalsDALService
.
findByTypeAndTimeUnitAndSubordinateSystemId
(
2
,
3
,
subordinateSystemId
);
}
Calendar
calendar
=
Calendar
.
getInstance
();
int
month
=
calendar
.
get
(
Calendar
.
MONTH
)+
1
;
List
<
Integer
>
monthList
=
getMonthListForQuarter
(
month
);
...
...
@@ -2410,7 +2544,7 @@ public class PractitionerServiceImpl implements com.yd.api.practitioner.service.
}
if
(
goalsPremium
!=
null
&&
goalsPremium
>
0
){
BigDecimal
fycBigDecimal
=
new
BigDecimal
(
fycSum
),
goalsBigDecimal
=
new
BigDecimal
(
goalsPremium
);
return
fycBigDecimal
.
divide
(
goalsBigDecimal
,
2
,
BigDecimal
.
ROUND_HALF_UP
).
doubleValue
()
;
return
fycBigDecimal
.
divide
(
goalsBigDecimal
,
4
,
BigDecimal
.
ROUND_HALF_UP
).
doubleValue
()
*
100
;
}
}
return
0
D
;
...
...
yd-api/src/main/java/com/yd/api/practitioner/vo/policy/PolicyInfo.java
0 → 100644
View file @
2961d4fb
package
com
.
yd
.
api
.
practitioner
.
vo
.
policy
;
import
com.yd.dal.entity.order.CustomerPolicyInfo
;
public
class
PolicyInfo
extends
CustomerPolicyInfo
{
}
\ No newline at end of file
yd-api/src/main/java/com/yd/api/practitioner/vo/policy/PolicyListQueryRequestVO.java
0 → 100644
View file @
2961d4fb
package
com
.
yd
.
api
.
practitioner
.
vo
.
policy
;
public
class
PolicyListQueryRequestVO
{
private
Long
practitionerId
;
private
Integer
time
;
public
Long
getPractitionerId
()
{
return
practitionerId
;
}
public
void
setPractitionerId
(
Long
practitionerId
)
{
this
.
practitionerId
=
practitionerId
;
}
public
Integer
getTime
()
{
return
time
;
}
public
void
setTime
(
Integer
time
)
{
this
.
time
=
time
;
}
}
yd-api/src/main/java/com/yd/api/practitioner/vo/policy/PolicyListQueryResponseVO.java
0 → 100644
View file @
2961d4fb
package
com
.
yd
.
api
.
practitioner
.
vo
.
policy
;
import
com.yd.api.result.CommonResult
;
import
java.util.List
;
public
class
PolicyListQueryResponseVO
{
private
List
<
PolicyInfo
>
policyInfoList
;
private
CommonResult
commonResult
;
public
List
<
PolicyInfo
>
getPolicyInfoList
()
{
return
policyInfoList
;
}
public
void
setPolicyInfoList
(
List
<
PolicyInfo
>
policyInfoList
)
{
this
.
policyInfoList
=
policyInfoList
;
}
public
CommonResult
getCommonResult
()
{
return
commonResult
;
}
public
void
setCommonResult
(
CommonResult
commonResult
)
{
this
.
commonResult
=
commonResult
;
}
}
yd-api/src/main/java/com/yd/api/practitioner/vo/policy/policyinfoquery/BuildingOrderInfo.java
0 → 100644
View file @
2961d4fb
package
com
.
yd
.
api
.
practitioner
.
vo
.
policy
.
policyinfoquery
;
public
class
BuildingOrderInfo
{
private
String
address
;
//详细地址
private
String
roomQty
;
//房间数范围
/**
* 获取属性 address 详细地址
* @return address
*/
public
String
getAddress
()
{
return
address
;
}
/**
* 属性赋值 address 详细地址
* @param address
*/
public
void
setAddress
(
String
address
)
{
this
.
address
=
address
;
}
/**
* 获取属性 roomQty 房间数范围
* @return the roomQty
*/
public
String
getRoomQty
()
{
return
roomQty
;
}
/**
* 属性赋值 roomQty 房间数范围
* @param roomQty the roomQty to set
*/
public
void
setRoomQty
(
String
roomQty
)
{
this
.
roomQty
=
roomQty
;
}
}
yd-api/src/main/java/com/yd/api/practitioner/vo/policy/policyinfoquery/DestinationInfo.java
0 → 100644
View file @
2961d4fb
package
com
.
yd
.
api
.
practitioner
.
vo
.
policy
.
policyinfoquery
;
public
class
DestinationInfo
{
private
Integer
destinationType
;
//目的地类型 1-洲;2-国家;3-地区
private
Long
destinationId
;
//对应的洲、国家、地区ID
private
String
destinationName
;
//目的地名称
public
Integer
getDestinationType
()
{
return
destinationType
;
}
public
void
setDestinationType
(
Integer
destinationType
)
{
this
.
destinationType
=
destinationType
;
}
public
Long
getDestinationId
()
{
return
destinationId
;
}
public
void
setDestinationId
(
Long
destinationId
)
{
this
.
destinationId
=
destinationId
;
}
public
String
getDestinationName
()
{
return
destinationName
;
}
public
void
setDestinationName
(
String
destinationName
)
{
this
.
destinationName
=
destinationName
;
}
}
yd-api/src/main/java/com/yd/api/practitioner/vo/policy/policyinfoquery/EleInvoiceInfo.java
0 → 100644
View file @
2961d4fb
package
com
.
yd
.
api
.
practitioner
.
vo
.
policy
.
policyinfoquery
;
public
class
EleInvoiceInfo
{
private
boolean
isHaveEleInvoiceUrl
;
//该保险公司是否有电子发票获取地址 0-无,1-有
private
String
eleInvoiceUrl
;
//保单电子发票获取地址
public
boolean
isHaveEleInvoiceUrl
()
{
return
isHaveEleInvoiceUrl
;
}
public
void
setHaveEleInvoiceUrl
(
boolean
haveEleInvoiceUrl
)
{
isHaveEleInvoiceUrl
=
haveEleInvoiceUrl
;
}
public
String
getEleInvoiceUrl
()
{
return
eleInvoiceUrl
;
}
public
void
setEleInvoiceUrl
(
String
eleInvoiceUrl
)
{
this
.
eleInvoiceUrl
=
eleInvoiceUrl
;
}
}
yd-api/src/main/java/com/yd/api/practitioner/vo/policy/policyinfoquery/HolderInfo.java
0 → 100644
View file @
2961d4fb
package
com
.
yd
.
api
.
practitioner
.
vo
.
policy
.
policyinfoquery
;
public
class
HolderInfo
extends
PersonBasicInfo
{
}
yd-api/src/main/java/com/yd/api/practitioner/vo/policy/policyinfoquery/IDInfo.java
0 → 100644
View file @
2961d4fb
package
com
.
yd
.
api
.
practitioner
.
vo
.
policy
.
policyinfoquery
;
public
class
IDInfo
{
private
Long
idType
;
//证件类型 1-身份证,2-护照,3-港澳身份证,4-台胞证,9-其他,20-组织机构代码
private
String
idNo
;
//证件号码
private
Integer
isIdLongTerm
;
//被保人证件是否长期有效 0=No 1=Yes
private
String
idEffectiveFrom
;
//证件有效日期 (起),格式yyyy-MM-dd
private
String
idEffectiveTo
;
//证件有效日期 (终),格式yyyy-MM-dd(长期有效则传3000-01-01)
private
String
idCardFront
;
//身份证正面照片上传返回地址
private
String
idCardFrontWx
;
//身份证正面照片上传返回地址
private
String
idCardBack
;
//身份证反面照片上传返回地址
private
String
idCardBackWx
;
//身份证反面照片上传返回地址
public
Long
getIdType
()
{
return
idType
;
}
public
void
setIdType
(
Long
idType
)
{
this
.
idType
=
idType
;
}
public
String
getIdNo
()
{
return
idNo
;
}
public
void
setIdNo
(
String
idNo
)
{
this
.
idNo
=
idNo
;
}
public
Integer
getIsIdLongTerm
()
{
return
isIdLongTerm
;
}
public
void
setIsIdLongTerm
(
Integer
isIdLongTerm
)
{
this
.
isIdLongTerm
=
isIdLongTerm
;
}
public
String
getIdEffectiveFrom
()
{
return
idEffectiveFrom
;
}
public
void
setIdEffectiveFrom
(
String
idEffectiveFrom
)
{
this
.
idEffectiveFrom
=
idEffectiveFrom
;
}
public
String
getIdEffectiveTo
()
{
return
idEffectiveTo
;
}
public
void
setIdEffectiveTo
(
String
idEffectiveTo
)
{
this
.
idEffectiveTo
=
idEffectiveTo
;
}
public
String
getIdCardFront
()
{
return
idCardFront
;
}
public
void
setIdCardFront
(
String
idCardFront
)
{
this
.
idCardFront
=
idCardFront
;
}
public
String
getIdCardFrontWx
()
{
return
idCardFrontWx
;
}
public
void
setIdCardFrontWx
(
String
idCardFrontWx
)
{
this
.
idCardFrontWx
=
idCardFrontWx
;
}
public
String
getIdCardBack
()
{
return
idCardBack
;
}
public
void
setIdCardBack
(
String
idCardBack
)
{
this
.
idCardBack
=
idCardBack
;
}
public
String
getIdCardBackWx
()
{
return
idCardBackWx
;
}
public
void
setIdCardBackWx
(
String
idCardBackWx
)
{
this
.
idCardBackWx
=
idCardBackWx
;
}
}
yd-api/src/main/java/com/yd/api/practitioner/vo/policy/policyinfoquery/InsureFactorInfo.java
0 → 100644
View file @
2961d4fb
package
com
.
yd
.
api
.
practitioner
.
vo
.
policy
.
policyinfoquery
;
public
class
InsureFactorInfo
{
private
Integer
socialInsured
;
//(社保:新农合 1-有 2-无)
private
String
coverTerm
;
//保障计划(终身保障/保障至xx岁)
private
Integer
paymentTerm
;
//缴费期限
private
String
paymentTermUnit
;
//缴费单位
private
Integer
payInterval
;
//缴费间隔
private
String
isInsure
;
//是否投保(投保,不投保)
private
Integer
adultCount
;
//成年人数目
private
Integer
childCount
;
//未成年人数目
private
Integer
eldCount
;
//老年人数目
private
Integer
coverLength
;
//1-365 days
private
DestinationInfo
destinationInfo
;
//目的地信息
private
VehicleOrderInfo
vehicleInfo
;
//标的信息--驾乘险
private
BuildingOrderInfo
buildingInfo
;
//标的信息--家财险
public
Integer
getSocialInsured
()
{
return
socialInsured
;
}
public
void
setSocialInsured
(
Integer
socialInsured
)
{
this
.
socialInsured
=
socialInsured
;
}
public
String
getCoverTerm
()
{
return
coverTerm
;
}
public
void
setCoverTerm
(
String
coverTerm
)
{
this
.
coverTerm
=
coverTerm
;
}
public
Integer
getPaymentTerm
()
{
return
paymentTerm
;
}
public
void
setPaymentTerm
(
Integer
paymentTerm
)
{
this
.
paymentTerm
=
paymentTerm
;
}
public
String
getPaymentTermUnit
()
{
return
paymentTermUnit
;
}
public
void
setPaymentTermUnit
(
String
paymentTermUnit
)
{
this
.
paymentTermUnit
=
paymentTermUnit
;
}
public
Integer
getPayInterval
()
{
return
payInterval
;
}
public
void
setPayInterval
(
Integer
payInterval
)
{
this
.
payInterval
=
payInterval
;
}
public
String
getIsInsure
()
{
return
isInsure
;
}
public
void
setIsInsure
(
String
isInsure
)
{
this
.
isInsure
=
isInsure
;
}
public
Integer
getAdultCount
()
{
return
adultCount
;
}
public
void
setAdultCount
(
Integer
adultCount
)
{
this
.
adultCount
=
adultCount
;
}
public
Integer
getChildCount
()
{
return
childCount
;
}
public
void
setChildCount
(
Integer
childCount
)
{
this
.
childCount
=
childCount
;
}
public
Integer
getEldCount
()
{
return
eldCount
;
}
public
void
setEldCount
(
Integer
eldCount
)
{
this
.
eldCount
=
eldCount
;
}
public
Integer
getCoverLength
()
{
return
coverLength
;
}
public
void
setCoverLength
(
Integer
coverLength
)
{
this
.
coverLength
=
coverLength
;
}
public
DestinationInfo
getDestinationInfo
()
{
return
destinationInfo
;
}
public
void
setDestinationInfo
(
DestinationInfo
destinationInfo
)
{
this
.
destinationInfo
=
destinationInfo
;
}
public
VehicleOrderInfo
getVehicleInfo
()
{
return
vehicleInfo
;
}
public
void
setVehicleInfo
(
VehicleOrderInfo
vehicleInfo
)
{
this
.
vehicleInfo
=
vehicleInfo
;
}
public
BuildingOrderInfo
getBuildingInfo
()
{
return
buildingInfo
;
}
public
void
setBuildingInfo
(
BuildingOrderInfo
buildingInfo
)
{
this
.
buildingInfo
=
buildingInfo
;
}
}
yd-api/src/main/java/com/yd/api/practitioner/vo/policy/policyinfoquery/InsuredBirthAddressInfo.java
0 → 100644
View file @
2961d4fb
package
com
.
yd
.
api
.
practitioner
.
vo
.
policy
.
policyinfoquery
;
public
class
InsuredBirthAddressInfo
{
private
Long
birthProvinceId
;
//被保人出生地省份
private
Long
birthCityId
;
//被保人出生地城市
private
Long
birthDistrictId
;
//被保人出生地地区
private
String
birthAddress
;
//被保人出生地地址
public
Long
getBirthProvinceId
()
{
return
birthProvinceId
;
}
public
void
setBirthProvinceId
(
Long
birthProvinceId
)
{
this
.
birthProvinceId
=
birthProvinceId
;
}
public
Long
getBirthCityId
()
{
return
birthCityId
;
}
public
void
setBirthCityId
(
Long
birthCityId
)
{
this
.
birthCityId
=
birthCityId
;
}
public
Long
getBirthDistrictId
()
{
return
birthDistrictId
;
}
public
void
setBirthDistrictId
(
Long
birthDistrictId
)
{
this
.
birthDistrictId
=
birthDistrictId
;
}
public
String
getBirthAddress
()
{
return
birthAddress
;
}
public
void
setBirthAddress
(
String
birthAddress
)
{
this
.
birthAddress
=
birthAddress
;
}
}
yd-api/src/main/java/com/yd/api/practitioner/vo/policy/policyinfoquery/InsuredInfo.java
0 → 100644
View file @
2961d4fb
package
com
.
yd
.
api
.
practitioner
.
vo
.
policy
.
policyinfoquery
;
import
java.util.List
;
public
class
InsuredInfo
extends
PersonBasicInfo
{
private
Long
relationType
;
//与投保人关系,1-本人,2-配偶,3-父母,4-子女,5-其他
private
Double
insuredHeight
;
//被保人身高,单位:cm
private
Double
insuredWeight
;
//被保人体重,单位:kg
private
InsuredBirthAddressInfo
insuredBirthInfo
;
//被保人出生地信息
private
List
<
UndQueInfo
>
undQueList
;
//健康问卷列表
private
List
<
LifeProductElementInfo
>
lifeProductElementInfoList
;
//寿险与重疾信息
public
Long
getRelationType
()
{
return
relationType
;
}
public
void
setRelationType
(
Long
relationType
)
{
this
.
relationType
=
relationType
;
}
public
Double
getInsuredHeight
()
{
return
insuredHeight
;
}
public
void
setInsuredHeight
(
Double
insuredHeight
)
{
this
.
insuredHeight
=
insuredHeight
;
}
public
Double
getInsuredWeight
()
{
return
insuredWeight
;
}
public
void
setInsuredWeight
(
Double
insuredWeight
)
{
this
.
insuredWeight
=
insuredWeight
;
}
public
InsuredBirthAddressInfo
getInsuredBirthInfo
()
{
return
insuredBirthInfo
;
}
public
void
setInsuredBirthInfo
(
InsuredBirthAddressInfo
insuredBirthInfo
)
{
this
.
insuredBirthInfo
=
insuredBirthInfo
;
}
public
List
<
UndQueInfo
>
getUndQueList
()
{
return
undQueList
;
}
public
void
setUndQueList
(
List
<
UndQueInfo
>
undQueList
)
{
this
.
undQueList
=
undQueList
;
}
/**
* 获取属性 lifeProductElementInfoList
* @return lifeProductElementInfoList
*/
public
List
<
LifeProductElementInfo
>
getLifeProductElementInfoList
()
{
return
lifeProductElementInfoList
;
}
/**
* 获取属性 lifeProductElementInfoList
* @param lifeProductElementInfoList
*/
public
void
setLifeProductElementInfoList
(
List
<
LifeProductElementInfo
>
lifeProductElementInfoList
)
{
this
.
lifeProductElementInfoList
=
lifeProductElementInfoList
;
}
}
yd-api/src/main/java/com/yd/api/practitioner/vo/policy/policyinfoquery/LifeProductElementInfo.java
0 → 100644
View file @
2961d4fb
package
com
.
yd
.
api
.
practitioner
.
vo
.
policy
.
policyinfoquery
;
public
class
LifeProductElementInfo
{
private
Long
factorId
;
private
String
factorName
;
private
String
factorCode
;
private
Long
elementId
;
private
String
elementText
;
private
Long
policyHolderId
;
/**
* 获取属性 factorId
* @return factorId
*/
public
Long
getFactorId
()
{
return
factorId
;
}
/**
* 获取属性 factorId
* @param factorId
*/
public
void
setFactorId
(
Long
factorId
)
{
this
.
factorId
=
factorId
;
}
/**
* 获取属性 factorName
* @return factorName
*/
public
String
getFactorName
()
{
return
factorName
;
}
/**
* 获取属性 factorCode
* @return factorCode
*/
public
String
getFactorCode
()
{
return
factorCode
;
}
/**
* 获取属性 factorCode
* @param factorCode
*/
public
void
setFactorCode
(
String
factorCode
)
{
this
.
factorCode
=
factorCode
;
}
/**
* 获取属性 factorName
* @param factorName
*/
public
void
setFactorName
(
String
factorName
)
{
this
.
factorName
=
factorName
;
}
/**
* 获取属性 elementId
* @return elementId
*/
public
Long
getElementId
()
{
return
elementId
;
}
/**
* 获取属性 elementId
* @param elementId
*/
public
void
setElementId
(
Long
elementId
)
{
this
.
elementId
=
elementId
;
}
/**
* 获取属性 elementText
* @return elementText
*/
public
String
getElementText
()
{
return
elementText
;
}
/**
* 获取属性 elementText
* @param elementText
*/
public
void
setElementText
(
String
elementText
)
{
this
.
elementText
=
elementText
;
}
/**
* 获取属性 policyHolderId
* @return policyHolderId
*/
public
Long
getPolicyHolderId
()
{
return
policyHolderId
;
}
/**
* 获取属性 policyHolderId
* @param policyHolderId
*/
public
void
setPolicyHolderId
(
Long
policyHolderId
)
{
this
.
policyHolderId
=
policyHolderId
;
}
}
yd-api/src/main/java/com/yd/api/practitioner/vo/policy/policyinfoquery/PersonBasicInfo.java
0 → 100644
View file @
2961d4fb
package
com
.
yd
.
api
.
practitioner
.
vo
.
policy
.
policyinfoquery
;
public
class
PersonBasicInfo
{
private
long
id
;
//ID
private
String
name
;
//姓名
private
String
mobileNo
;
//手机号
private
String
email
;
//邮箱
private
Integer
gender
;
//性别 1-Male,2-FeMale
private
String
birthDay
;
//生日,格式yyyy-MM-dd
private
Integer
age
;
//年龄
private
Long
provinceId
;
//省份ID
private
Long
cityId
;
//城市ID
private
Long
districtId
;
//区(县)ID
private
String
address
;
//地址
private
String
postCode
;
//邮编
private
Long
occupationId
;
//职业代码ID
private
String
occupationName
;
//职业类别
private
String
salaryType
;
//各种来源
private
Double
salary
;
//去年总收入
private
IDInfo
idInfo
;
//证件信息
public
long
getId
()
{
return
id
;
}
public
void
setId
(
long
id
)
{
this
.
id
=
id
;
}
public
String
getName
()
{
return
name
;
}
public
void
setName
(
String
name
)
{
this
.
name
=
name
;
}
public
String
getMobileNo
()
{
return
mobileNo
;
}
public
void
setMobileNo
(
String
mobileNo
)
{
this
.
mobileNo
=
mobileNo
;
}
public
String
getEmail
()
{
return
email
;
}
public
void
setEmail
(
String
email
)
{
this
.
email
=
email
;
}
public
Integer
getGender
()
{
return
gender
;
}
public
void
setGender
(
Integer
gender
)
{
this
.
gender
=
gender
;
}
public
String
getBirthDay
()
{
return
birthDay
;
}
public
void
setBirthDay
(
String
birthDay
)
{
this
.
birthDay
=
birthDay
;
}
public
Integer
getAge
()
{
return
age
;
}
public
void
setAge
(
Integer
age
)
{
this
.
age
=
age
;
}
public
Long
getProvinceId
()
{
return
provinceId
;
}
public
void
setProvinceId
(
Long
provinceId
)
{
this
.
provinceId
=
provinceId
;
}
public
Long
getCityId
()
{
return
cityId
;
}
public
void
setCityId
(
Long
cityId
)
{
this
.
cityId
=
cityId
;
}
public
Long
getDistrictId
()
{
return
districtId
;
}
public
void
setDistrictId
(
Long
districtId
)
{
this
.
districtId
=
districtId
;
}
public
String
getAddress
()
{
return
address
;
}
public
void
setAddress
(
String
address
)
{
this
.
address
=
address
;
}
public
String
getPostCode
()
{
return
postCode
;
}
public
void
setPostCode
(
String
postCode
)
{
this
.
postCode
=
postCode
;
}
public
Long
getOccupationId
()
{
return
occupationId
;
}
public
void
setOccupationId
(
Long
occupationId
)
{
this
.
occupationId
=
occupationId
;
}
public
String
getOccupationName
()
{
return
occupationName
;
}
public
void
setOccupationName
(
String
occupationName
)
{
this
.
occupationName
=
occupationName
;
}
public
String
getSalaryType
()
{
return
salaryType
;
}
public
void
setSalaryType
(
String
salaryType
)
{
this
.
salaryType
=
salaryType
;
}
public
Double
getSalary
()
{
return
salary
;
}
public
void
setSalary
(
Double
salary
)
{
this
.
salary
=
salary
;
}
public
IDInfo
getIdInfo
()
{
return
idInfo
;
}
public
void
setIdInfo
(
IDInfo
idInfo
)
{
this
.
idInfo
=
idInfo
;
}
}
yd-api/src/main/java/com/yd/api/practitioner/vo/policy/policyinfoquery/PolicyFactorInfo.java
0 → 100644
View file @
2961d4fb
package
com
.
yd
.
api
.
practitioner
.
vo
.
policy
.
policyinfoquery
;
public
class
PolicyFactorInfo
{
private
String
productId
;
private
String
productCode
;
private
String
productName
;
private
String
insurerId
;
private
String
insurerName
;
private
Double
premium
;
private
Double
commission
;
private
Double
commissionRate
;
private
String
policyType
;
private
String
payFrequency
;
private
String
payCommissionStatus
;
private
String
commissionType
;
private
String
insuredAmount
;
private
String
relationship
;
private
String
amountUnit
;
private
Integer
period
;
public
String
getProductId
()
{
return
productId
;
}
public
void
setProductId
(
String
productId
)
{
this
.
productId
=
productId
;
}
public
String
getProductCode
()
{
return
productCode
;
}
public
void
setProductCode
(
String
productCode
)
{
this
.
productCode
=
productCode
;
}
public
String
getProductName
()
{
return
productName
;
}
public
void
setProductName
(
String
productName
)
{
this
.
productName
=
productName
;
}
public
String
getInsurerId
()
{
return
insurerId
;
}
public
void
setInsurerId
(
String
insurerId
)
{
this
.
insurerId
=
insurerId
;
}
public
String
getInsurerName
()
{
return
insurerName
;
}
public
void
setInsurerName
(
String
insurerName
)
{
this
.
insurerName
=
insurerName
;
}
public
Double
getPremium
()
{
return
premium
;
}
public
void
setPremium
(
Double
premium
)
{
this
.
premium
=
premium
;
}
public
Double
getCommission
()
{
return
commission
;
}
public
void
setCommission
(
Double
commission
)
{
this
.
commission
=
commission
;
}
public
Double
getCommissionRate
()
{
return
commissionRate
;
}
public
void
setCommissionRate
(
Double
commissionRate
)
{
this
.
commissionRate
=
commissionRate
;
}
public
String
getPolicyType
()
{
return
policyType
;
}
public
void
setPolicyType
(
String
policyType
)
{
this
.
policyType
=
policyType
;
}
public
String
getPayFrequency
()
{
return
payFrequency
;
}
public
void
setPayFrequency
(
String
payFrequency
)
{
this
.
payFrequency
=
payFrequency
;
}
public
String
getPayCommissionStatus
()
{
return
payCommissionStatus
;
}
public
void
setPayCommissionStatus
(
String
payCommissionStatus
)
{
this
.
payCommissionStatus
=
payCommissionStatus
;
}
public
String
getCommissionType
()
{
return
commissionType
;
}
public
void
setCommissionType
(
String
commissionType
)
{
this
.
commissionType
=
commissionType
;
}
public
String
getInsuredAmount
()
{
return
insuredAmount
;
}
public
void
setInsuredAmount
(
String
insuredAmount
)
{
this
.
insuredAmount
=
insuredAmount
;
}
public
String
getRelationship
()
{
return
relationship
;
}
public
void
setRelationship
(
String
relationship
)
{
this
.
relationship
=
relationship
;
}
public
String
getAmountUnit
()
{
return
amountUnit
;
}
public
void
setAmountUnit
(
String
amountUnit
)
{
this
.
amountUnit
=
amountUnit
;
}
public
Integer
getPeriod
()
{
return
period
;
}
public
void
setPeriod
(
Integer
period
)
{
this
.
period
=
period
;
}
}
yd-api/src/main/java/com/yd/api/practitioner/vo/policy/policyinfoquery/PolicyInfoQueryRequestVO.java
0 → 100644
View file @
2961d4fb
package
com
.
yd
.
api
.
practitioner
.
vo
.
policy
.
policyinfoquery
;
public
class
PolicyInfoQueryRequestVO
{
private
Long
orderId
;
//订单ID
private
String
orderNo
;
//订单号
private
Long
policyId
;
//保单ID
private
String
policyNo
;
//保单号
private
Integer
platform
;
//平台,1--yd,2--EGolden
/**
* 获取属性 orderId 订单ID
* @return orderId
*/
public
Long
getOrderId
(){
return
this
.
orderId
;
}
/**
* 属性赋值 orderId 订单ID
* @param orderId
*/
public
void
setOrderId
(
Long
orderId
){
this
.
orderId
=
orderId
;
}
/**
* 获取属性 orderNo 订单号
* @return orderNo
*/
public
String
getOrderNo
(){
return
this
.
orderNo
;
}
/**
* 属性赋值 orderNo 订单号
* @param orderNo
*/
public
void
setOrderNo
(
String
orderNo
){
this
.
orderNo
=
orderNo
;
}
public
Long
getPolicyId
()
{
return
policyId
;
}
public
void
setPolicyId
(
Long
policyId
)
{
this
.
policyId
=
policyId
;
}
public
String
getPolicyNo
()
{
return
policyNo
;
}
public
void
setPolicyNo
(
String
policyNo
)
{
this
.
policyNo
=
policyNo
;
}
public
Integer
getPlatform
()
{
return
platform
;
}
public
void
setPlatform
(
Integer
platform
)
{
this
.
platform
=
platform
;
}
}
yd-api/src/main/java/com/yd/api/practitioner/vo/policy/policyinfoquery/PolicyInfoQueryResponseVO.java
0 → 100644
View file @
2961d4fb
package
com
.
yd
.
api
.
practitioner
.
vo
.
policy
.
policyinfoquery
;
import
com.yd.api.result.CommonResult
;
import
java.util.List
;
public
class
PolicyInfoQueryResponseVO
{
private
Long
orderId
;
//订单ID
private
String
orderNo
;
//订单号
private
Long
policyId
;
//保单id
private
String
policyNo
;
//保单号
private
Long
customerId
;
//操作人用户Id
private
String
orderDate
;
//下单日期
private
String
startDate
;
//保险起期
private
String
endDate
;
//保险止期
private
Double
price
;
//价格
private
String
status
;
//保单状态
private
ProductInfo
productInfo
;
//产品信息
private
EleInvoiceInfo
eleInvoiceInfo
;
//电子发票信息
private
ReferralInfo
referralInfo
;
//推荐金信息
private
InsureFactorInfo
insureFactorInfo
;
//投保因子信息
private
HolderInfo
holderInfo
;
//投保人
private
List
<
InsuredInfo
>
insuredInfos
;
//被保险人对象列表
private
RenewBankInfo
renewBankInfo
;
//续保银行卡信息
private
List
<
PolicyFactorInfo
>
policyFactorInfos
;
//寿险投保因子相关信息
private
CommonResult
commonResult
;
public
Long
getOrderId
()
{
return
orderId
;
}
public
void
setOrderId
(
Long
orderId
)
{
this
.
orderId
=
orderId
;
}
public
String
getOrderNo
()
{
return
orderNo
;
}
public
void
setOrderNo
(
String
orderNo
)
{
this
.
orderNo
=
orderNo
;
}
public
Long
getPolicyId
()
{
return
policyId
;
}
public
void
setPolicyId
(
Long
policyId
)
{
this
.
policyId
=
policyId
;
}
public
String
getPolicyNo
()
{
return
policyNo
;
}
public
void
setPolicyNo
(
String
policyNo
)
{
this
.
policyNo
=
policyNo
;
}
public
Long
getCustomerId
()
{
return
customerId
;
}
public
void
setCustomerId
(
Long
customerId
)
{
this
.
customerId
=
customerId
;
}
public
String
getOrderDate
()
{
return
orderDate
;
}
public
void
setOrderDate
(
String
orderDate
)
{
this
.
orderDate
=
orderDate
;
}
public
String
getStartDate
()
{
return
startDate
;
}
public
void
setStartDate
(
String
startDate
)
{
this
.
startDate
=
startDate
;
}
public
String
getEndDate
()
{
return
endDate
;
}
public
void
setEndDate
(
String
endDate
)
{
this
.
endDate
=
endDate
;
}
public
Double
getPrice
()
{
return
price
;
}
public
void
setPrice
(
Double
price
)
{
this
.
price
=
price
;
}
public
String
getStatus
()
{
return
status
;
}
public
void
setStatus
(
String
status
)
{
this
.
status
=
status
;
}
public
ProductInfo
getProductInfo
()
{
return
productInfo
;
}
public
void
setProductInfo
(
ProductInfo
productInfo
)
{
this
.
productInfo
=
productInfo
;
}
public
EleInvoiceInfo
getEleInvoiceInfo
()
{
return
eleInvoiceInfo
;
}
public
void
setEleInvoiceInfo
(
EleInvoiceInfo
eleInvoiceInfo
)
{
this
.
eleInvoiceInfo
=
eleInvoiceInfo
;
}
public
ReferralInfo
getReferralInfo
()
{
return
referralInfo
;
}
public
void
setReferralInfo
(
ReferralInfo
referralInfo
)
{
this
.
referralInfo
=
referralInfo
;
}
public
InsureFactorInfo
getInsureFactorInfo
()
{
return
insureFactorInfo
;
}
public
void
setInsureFactorInfo
(
InsureFactorInfo
insureFactorInfo
)
{
this
.
insureFactorInfo
=
insureFactorInfo
;
}
public
HolderInfo
getHolderInfo
()
{
return
holderInfo
;
}
public
void
setHolderInfo
(
HolderInfo
holderInfo
)
{
this
.
holderInfo
=
holderInfo
;
}
public
List
<
InsuredInfo
>
getInsuredInfos
()
{
return
insuredInfos
;
}
public
void
setInsuredInfos
(
List
<
InsuredInfo
>
insuredInfos
)
{
this
.
insuredInfos
=
insuredInfos
;
}
public
RenewBankInfo
getRenewBankInfo
()
{
return
renewBankInfo
;
}
public
void
setRenewBankInfo
(
RenewBankInfo
renewBankInfo
)
{
this
.
renewBankInfo
=
renewBankInfo
;
}
public
List
<
PolicyFactorInfo
>
getPolicyFactorInfos
()
{
return
policyFactorInfos
;
}
public
void
setPolicyFactorInfos
(
List
<
PolicyFactorInfo
>
policyFactorInfos
)
{
this
.
policyFactorInfos
=
policyFactorInfos
;
}
public
CommonResult
getCommonResult
()
{
return
commonResult
;
}
public
void
setCommonResult
(
CommonResult
commonResult
)
{
this
.
commonResult
=
commonResult
;
}
}
yd-api/src/main/java/com/yd/api/practitioner/vo/policy/policyinfoquery/ProductInfo.java
0 → 100644
View file @
2961d4fb
package
com
.
yd
.
api
.
practitioner
.
vo
.
policy
.
policyinfoquery
;
public
class
ProductInfo
{
private
Long
planId
;
//计划ID
private
String
planName
;
//计划名称
private
Long
productId
;
//方案ID
private
String
productName
;
//方案ID
private
Long
insureId
;
//保险公司Id
private
String
insureName
;
//保险公司名称
private
boolean
noPlanProduct
;
//是否为无plan的方案
private
Long
planIdOld
;
//旧的方案ID
private
String
planNameOld
;
//旧的方案名称
public
Long
getPlanId
()
{
return
planId
;
}
public
void
setPlanId
(
Long
planId
)
{
this
.
planId
=
planId
;
}
public
String
getPlanName
()
{
return
planName
;
}
public
void
setPlanName
(
String
planName
)
{
this
.
planName
=
planName
;
}
public
Long
getProductId
()
{
return
productId
;
}
public
void
setProductId
(
Long
productId
)
{
this
.
productId
=
productId
;
}
public
String
getProductName
()
{
return
productName
;
}
public
void
setProductName
(
String
productName
)
{
this
.
productName
=
productName
;
}
public
Long
getInsureId
()
{
return
insureId
;
}
public
void
setInsureId
(
Long
insureId
)
{
this
.
insureId
=
insureId
;
}
public
String
getInsureName
()
{
return
insureName
;
}
public
void
setInsureName
(
String
insureName
)
{
this
.
insureName
=
insureName
;
}
public
boolean
isNoPlanProduct
()
{
return
noPlanProduct
;
}
public
void
setNoPlanProduct
(
boolean
noPlanProduct
)
{
this
.
noPlanProduct
=
noPlanProduct
;
}
public
Long
getPlanIdOld
()
{
return
planIdOld
;
}
public
void
setPlanIdOld
(
Long
planIdOld
)
{
this
.
planIdOld
=
planIdOld
;
}
public
String
getPlanNameOld
()
{
return
planNameOld
;
}
public
void
setPlanNameOld
(
String
planNameOld
)
{
this
.
planNameOld
=
planNameOld
;
}
}
yd-api/src/main/java/com/yd/api/practitioner/vo/policy/policyinfoquery/ReferralInfo.java
0 → 100644
View file @
2961d4fb
package
com
.
yd
.
api
.
practitioner
.
vo
.
policy
.
policyinfoquery
;
public
class
ReferralInfo
{
private
Double
referralRate
;
//推荐金比例
private
Double
referralAmount
;
//推荐金金额
public
Double
getReferralRate
()
{
return
referralRate
;
}
public
void
setReferralRate
(
Double
referralRate
)
{
this
.
referralRate
=
referralRate
;
}
public
Double
getReferralAmount
()
{
return
referralAmount
;
}
public
void
setReferralAmount
(
Double
referralAmount
)
{
this
.
referralAmount
=
referralAmount
;
}
}
yd-api/src/main/java/com/yd/api/practitioner/vo/policy/policyinfoquery/RenewBankInfo.java
0 → 100644
View file @
2961d4fb
package
com
.
yd
.
api
.
practitioner
.
vo
.
policy
.
policyinfoquery
;
public
class
RenewBankInfo
{
private
String
cardHolder
;
// 卡主名字
private
Long
bankId
;
private
String
bank
;
//所属银行
private
String
cardNo
;
//卡号
private
String
reserveMobileNo
;
//银行预留电话号码
private
String
bankCityName
;
//开户行所在地
private
String
autoPayFlag
;
//保险费过期未付选择
public
String
getCardHolder
()
{
return
cardHolder
;
}
public
void
setCardHolder
(
String
cardHolder
)
{
this
.
cardHolder
=
cardHolder
;
}
public
String
getBank
()
{
return
bank
;
}
public
void
setBank
(
String
bank
)
{
this
.
bank
=
bank
;
}
public
String
getCardNo
()
{
return
cardNo
;
}
public
void
setCardNo
(
String
cardNo
)
{
this
.
cardNo
=
cardNo
;
}
public
Long
getBankId
()
{
return
bankId
;
}
public
void
setBankId
(
Long
bankId
)
{
this
.
bankId
=
bankId
;
}
/**
* 获取属性 reserveMobileNo
* @return reserveMobileNo
*/
public
String
getReserveMobileNo
()
{
return
reserveMobileNo
;
}
/**
* 获取属性 reserveMobileNo
* @param reserveMobileNo
*/
public
void
setReserveMobileNo
(
String
reserveMobileNo
)
{
this
.
reserveMobileNo
=
reserveMobileNo
;
}
/**
* 获取属性 bankCityName 开户行所在地
* @return bankCityName
*/
public
String
getBankCityName
()
{
return
bankCityName
;
}
/**
* 获取属性 bankCityName 开户行所在地
* @param bankCityName
*/
public
void
setBankCityName
(
String
bankCityName
)
{
this
.
bankCityName
=
bankCityName
;
}
/**
* 获取属性 autoPayFlag 保险费过期未付选择
* @return autoPayFlag
*/
public
String
getAutoPayFlag
()
{
return
autoPayFlag
;
}
/**
* 获取属性 autoPayFlag 保险费过期未付选择
* @param autoPayFlag
*/
public
void
setAutoPayFlag
(
String
autoPayFlag
)
{
this
.
autoPayFlag
=
autoPayFlag
;
}
}
yd-api/src/main/java/com/yd/api/practitioner/vo/policy/policyinfoquery/UndQueInfo.java
0 → 100644
View file @
2961d4fb
package
com
.
yd
.
api
.
practitioner
.
vo
.
policy
.
policyinfoquery
;
public
class
UndQueInfo
{
private
Long
questionVerifyId
;
//问卷ID,来源于9.4疾病-问卷查询接口
private
String
answer
;
//Y 或者 N
/**
* 获取属性 questionVerifyId 问卷ID,来源于9.4疾病-问卷查询接口
* @return questionVerifyId
*/
public
Long
getQuestionVerifyId
(){
return
this
.
questionVerifyId
;
}
/**
* 属性赋值 questionVerifyId 问卷ID,来源于9.4疾病-问卷查询接口
* @param questionVerifyId
*/
public
void
setQuestionVerifyId
(
Long
questionVerifyId
){
this
.
questionVerifyId
=
questionVerifyId
;
}
/**
* 获取属性 answer Y 或者 N
* @return answer
*/
public
String
getAnswer
(){
return
this
.
answer
;
}
/**
* 属性赋值 answer Y 或者 N
* @param answer
*/
public
void
setAnswer
(
String
answer
){
this
.
answer
=
answer
;
}
}
yd-api/src/main/java/com/yd/api/practitioner/vo/policy/policyinfoquery/VehicleOrderInfo.java
0 → 100644
View file @
2961d4fb
package
com
.
yd
.
api
.
practitioner
.
vo
.
policy
.
policyinfoquery
;
public
class
VehicleOrderInfo
{
private
String
licenseNo
;
//车牌号
private
Integer
seatCount
;
//核定座位数
private
String
frameNo
;
//车架号
/**
* 获取属性licenseNo 车牌号
*/
public
String
getLicenseNo
()
{
return
licenseNo
;
}
/**
* 属性设置licenseNo 车牌号
* @param licenseNo
*/
public
void
setLicenseNo
(
String
licenseNo
)
{
this
.
licenseNo
=
licenseNo
;
}
/**
* 获取属性seatCount 核定座位数
*/
public
Integer
getSeatCount
()
{
return
seatCount
;
}
/**
* 属性设置seatCount 核定座位数
* @param seatCount
*/
public
void
setSeatCount
(
Integer
seatCount
)
{
this
.
seatCount
=
seatCount
;
}
/**
* 获取属性frameNo 车架号
*/
public
String
getFrameNo
()
{
return
frameNo
;
}
/**
* 属性设值 frameNo 车架号
* @param frameNo
*/
public
void
setFrameNo
(
String
frameNo
)
{
this
.
frameNo
=
frameNo
;
}
}
yd-api/src/main/java/com/yd/dal/entity/customer/practitioner/PractitionerBasicInfo.java
View file @
2961d4fb
...
...
@@ -64,4 +64,5 @@ public class PractitionerBasicInfo {
public
void
setGender
(
String
gender
)
{
this
.
gender
=
gender
;
}
}
yd-api/src/main/java/com/yd/dal/entity/customer/practitioner/SubordinateSystemMemberInfoE.java
0 → 100644
View file @
2961d4fb
package
com
.
yd
.
dal
.
entity
.
customer
.
practitioner
;
public
class
SubordinateSystemMemberInfoE
{
private
Long
practitionerId
;
private
String
name
;
private
String
levelCode
;
private
String
levelName
;
private
Double
fyp
;
private
Double
fyc
;
private
Integer
count
;
private
String
mobileNo
;
public
Long
getPractitionerId
()
{
return
practitionerId
;
}
public
void
setPractitionerId
(
Long
practitionerId
)
{
this
.
practitionerId
=
practitionerId
;
}
public
String
getName
()
{
return
name
;
}
public
void
setName
(
String
name
)
{
this
.
name
=
name
;
}
public
String
getLevelCode
()
{
return
levelCode
;
}
public
void
setLevelCode
(
String
levelCode
)
{
this
.
levelCode
=
levelCode
;
}
public
String
getLevelName
()
{
return
levelName
;
}
public
void
setLevelName
(
String
levelName
)
{
this
.
levelName
=
levelName
;
}
public
Double
getFyp
()
{
return
fyp
;
}
public
void
setFyp
(
Double
fyp
)
{
this
.
fyp
=
fyp
;
}
public
Double
getFyc
()
{
return
fyc
;
}
public
void
setFyc
(
Double
fyc
)
{
this
.
fyc
=
fyc
;
}
public
Integer
getCount
()
{
return
count
;
}
public
void
setCount
(
Integer
count
)
{
this
.
count
=
count
;
}
public
String
getMobileNo
()
{
return
mobileNo
;
}
public
void
setMobileNo
(
String
mobileNo
)
{
this
.
mobileNo
=
mobileNo
;
}
}
yd-api/src/main/java/com/yd/dal/entity/meta/OptionsEGolden.java
0 → 100644
View file @
2961d4fb
package
com
.
yd
.
dal
.
entity
.
meta
;
public
class
OptionsEGolden
{
private
Integer
optId
;
private
Integer
mstId
;
private
String
optName
;
private
String
optAttr
;
private
String
optOrder
;
public
Integer
getOptId
()
{
return
optId
;
}
public
void
setOptId
(
Integer
optId
)
{
this
.
optId
=
optId
;
}
public
Integer
getMstId
()
{
return
mstId
;
}
public
void
setMstId
(
Integer
mstId
)
{
this
.
mstId
=
mstId
;
}
public
String
getOptName
()
{
return
optName
;
}
public
void
setOptName
(
String
optName
)
{
this
.
optName
=
optName
;
}
public
String
getOptAttr
()
{
return
optAttr
;
}
public
void
setOptAttr
(
String
optAttr
)
{
this
.
optAttr
=
optAttr
;
}
public
String
getOptOrder
()
{
return
optOrder
;
}
public
void
setOptOrder
(
String
optOrder
)
{
this
.
optOrder
=
optOrder
;
}
}
yd-api/src/main/java/com/yd/dal/entity/order/CustomerPolicyInfo.java
0 → 100644
View file @
2961d4fb
package
com
.
yd
.
dal
.
entity
.
order
;
import
com.google.common.base.Strings
;
import
com.yd.util.CommonUtil
;
import
java.util.Date
;
public
class
CustomerPolicyInfo
implements
Comparable
<
CustomerPolicyInfo
>{
private
Long
orderId
;
private
String
orderNo
;
private
String
policyNo
;
private
String
holderName
;
private
String
destination
;
private
String
planName
;
private
String
productName
;
private
String
orderDate
;
private
String
startDate
;
private
String
endDate
;
private
Double
referralAmount
;
private
Double
orderPrice
;
private
boolean
noPlanProduct
;
private
Integer
platform
;
//1、银盾在线,2、EGolden
private
Long
planId
;
private
Long
productId
;
public
Long
getOrderId
()
{
return
orderId
;
}
public
void
setOrderId
(
Long
orderId
)
{
this
.
orderId
=
orderId
;
}
public
String
getOrderNo
()
{
return
orderNo
;
}
public
void
setOrderNo
(
String
orderNo
)
{
this
.
orderNo
=
orderNo
;
}
public
String
getPolicyNo
()
{
return
policyNo
;
}
public
void
setPolicyNo
(
String
policyNo
)
{
this
.
policyNo
=
policyNo
;
}
public
String
getHolderName
()
{
return
holderName
;
}
public
void
setHolderName
(
String
holderName
)
{
this
.
holderName
=
holderName
;
}
public
String
getDestination
()
{
return
destination
;
}
public
void
setDestination
(
String
destination
)
{
this
.
destination
=
destination
;
}
public
String
getPlanName
()
{
return
planName
;
}
public
void
setPlanName
(
String
planName
)
{
this
.
planName
=
planName
;
}
public
String
getOrderDate
()
{
return
orderDate
;
}
public
void
setOrderDate
(
String
orderDate
)
{
this
.
orderDate
=
orderDate
;
}
public
String
getStartDate
()
{
return
startDate
;
}
public
void
setStartDate
(
String
startDate
)
{
this
.
startDate
=
startDate
;
}
public
String
getEndDate
()
{
return
endDate
;
}
public
void
setEndDate
(
String
endDate
)
{
this
.
endDate
=
endDate
;
}
public
Double
getReferralAmount
()
{
return
referralAmount
;
}
public
void
setReferralAmount
(
Double
referralAmount
)
{
this
.
referralAmount
=
referralAmount
;
}
public
Double
getOrderPrice
()
{
return
orderPrice
;
}
public
void
setOrderPrice
(
Double
orderPrice
)
{
this
.
orderPrice
=
orderPrice
;
}
public
String
getProductName
()
{
return
productName
;
}
public
void
setProductName
(
String
productName
)
{
this
.
productName
=
productName
;
}
public
boolean
isNoPlanProduct
()
{
return
noPlanProduct
;
}
public
void
setNoPlanProduct
(
boolean
noPlanProduct
)
{
this
.
noPlanProduct
=
noPlanProduct
;
}
public
Integer
getPlatform
()
{
return
platform
;
}
public
void
setPlatform
(
Integer
platform
)
{
this
.
platform
=
platform
;
}
public
Long
getPlanId
()
{
return
planId
;
}
public
void
setPlanId
(
Long
planId
)
{
this
.
planId
=
planId
;
}
public
Long
getProductId
()
{
return
productId
;
}
public
void
setProductId
(
Long
productId
)
{
this
.
productId
=
productId
;
}
@Override
public
int
compareTo
(
CustomerPolicyInfo
o
)
{
String
orderDate1
=
o
.
getOrderDate
();
if
(!
Strings
.
isNullOrEmpty
(
orderDate
)
&&
!
Strings
.
isNullOrEmpty
(
orderDate1
)){
Date
orderDateDT
=
CommonUtil
.
stringParseDate
(
orderDate
,
"yyyy-MM-dd HH:mm:ss"
);
Date
orderDate1DT
=
CommonUtil
.
stringParseDate
(
orderDate1
,
"yyyy-MM-dd HH:mm:ss"
);
if
(
orderDate1DT
!=
null
&&
orderDateDT
!=
null
){
return
orderDate1DT
.
compareTo
(
orderDateDT
);
}
else
{
return
0
;
}
}
else
{
return
0
;
}
}
}
yd-api/src/main/java/com/yd/dal/entity/order/PolicyDetailInfoE.java
0 → 100644
View file @
2961d4fb
package
com
.
yd
.
dal
.
entity
.
order
;
public
class
PolicyDetailInfoE
{
private
String
orderNo
;
private
String
policyNo
;
private
String
policyStatus
;
private
String
orderDate
;
private
String
startDate
;
private
String
endDate
;
private
String
holderId
;
private
String
holderName
;
private
String
holderIdNoType
;
private
String
holderIdNo
;
private
String
holderSex
;
private
String
holderBirthday
;
private
String
holderMobileNo
;
private
String
insuredId
;
private
String
insuredName
;
private
String
insuredIdNoType
;
private
String
insuredIdNo
;
private
String
insuredSex
;
private
String
insuredBirthday
;
private
String
insuredMobileNo
;
private
String
productId
;
private
String
productCode
;
private
String
productName
;
private
String
insurerId
;
private
String
insurerName
;
private
Double
premium
;
private
Double
commission
;
private
Double
commissionRate
;
private
String
policyType
;
private
String
payFrequency
;
private
String
payCommissionStatus
;
private
String
commissionType
;
public
String
getOrderNo
()
{
return
orderNo
;
}
public
void
setOrderNo
(
String
orderNo
)
{
this
.
orderNo
=
orderNo
;
}
public
String
getPolicyNo
()
{
return
policyNo
;
}
public
void
setPolicyNo
(
String
policyNo
)
{
this
.
policyNo
=
policyNo
;
}
public
String
getPolicyStatus
()
{
return
policyStatus
;
}
public
void
setPolicyStatus
(
String
policyStatus
)
{
this
.
policyStatus
=
policyStatus
;
}
public
String
getOrderDate
()
{
return
orderDate
;
}
public
void
setOrderDate
(
String
orderDate
)
{
this
.
orderDate
=
orderDate
;
}
public
String
getStartDate
()
{
return
startDate
;
}
public
void
setStartDate
(
String
startDate
)
{
this
.
startDate
=
startDate
;
}
public
String
getEndDate
()
{
return
endDate
;
}
public
void
setEndDate
(
String
endDate
)
{
this
.
endDate
=
endDate
;
}
public
String
getHolderId
()
{
return
holderId
;
}
public
void
setHolderId
(
String
holderId
)
{
this
.
holderId
=
holderId
;
}
public
String
getHolderName
()
{
return
holderName
;
}
public
void
setHolderName
(
String
holderName
)
{
this
.
holderName
=
holderName
;
}
public
String
getHolderIdNo
()
{
return
holderIdNo
;
}
public
void
setHolderIdNo
(
String
holderIdNo
)
{
this
.
holderIdNo
=
holderIdNo
;
}
public
String
getHolderSex
()
{
return
holderSex
;
}
public
void
setHolderSex
(
String
holderSex
)
{
this
.
holderSex
=
holderSex
;
}
public
String
getHolderBirthday
()
{
return
holderBirthday
;
}
public
void
setHolderBirthday
(
String
holderBirthday
)
{
this
.
holderBirthday
=
holderBirthday
;
}
public
String
getHolderMobileNo
()
{
return
holderMobileNo
;
}
public
void
setHolderMobileNo
(
String
holderMobileNo
)
{
this
.
holderMobileNo
=
holderMobileNo
;
}
public
String
getInsuredId
()
{
return
insuredId
;
}
public
void
setInsuredId
(
String
insuredId
)
{
this
.
insuredId
=
insuredId
;
}
public
String
getInsuredName
()
{
return
insuredName
;
}
public
void
setInsuredName
(
String
insuredName
)
{
this
.
insuredName
=
insuredName
;
}
public
String
getInsuredIdNo
()
{
return
insuredIdNo
;
}
public
void
setInsuredIdNo
(
String
insuredIdNo
)
{
this
.
insuredIdNo
=
insuredIdNo
;
}
public
String
getInsuredSex
()
{
return
insuredSex
;
}
public
void
setInsuredSex
(
String
insuredSex
)
{
this
.
insuredSex
=
insuredSex
;
}
public
String
getInsuredBirthday
()
{
return
insuredBirthday
;
}
public
void
setInsuredBirthday
(
String
insuredBirthday
)
{
this
.
insuredBirthday
=
insuredBirthday
;
}
public
String
getInsuredMobileNo
()
{
return
insuredMobileNo
;
}
public
void
setInsuredMobileNo
(
String
insuredMobileNo
)
{
this
.
insuredMobileNo
=
insuredMobileNo
;
}
public
String
getProductId
()
{
return
productId
;
}
public
void
setProductId
(
String
productId
)
{
this
.
productId
=
productId
;
}
public
String
getProductCode
()
{
return
productCode
;
}
public
void
setProductCode
(
String
productCode
)
{
this
.
productCode
=
productCode
;
}
public
String
getProductName
()
{
return
productName
;
}
public
void
setProductName
(
String
productName
)
{
this
.
productName
=
productName
;
}
public
String
getInsurerId
()
{
return
insurerId
;
}
public
void
setInsurerId
(
String
insurerId
)
{
this
.
insurerId
=
insurerId
;
}
public
String
getInsurerName
()
{
return
insurerName
;
}
public
void
setInsurerName
(
String
insurerName
)
{
this
.
insurerName
=
insurerName
;
}
public
Double
getPremium
()
{
return
premium
;
}
public
void
setPremium
(
Double
premium
)
{
this
.
premium
=
premium
;
}
public
Double
getCommission
()
{
return
commission
;
}
public
void
setCommission
(
Double
commission
)
{
this
.
commission
=
commission
;
}
public
Double
getCommissionRate
()
{
return
commissionRate
;
}
public
void
setCommissionRate
(
Double
commissionRate
)
{
this
.
commissionRate
=
commissionRate
;
}
public
String
getPolicyType
()
{
return
policyType
;
}
public
void
setPolicyType
(
String
policyType
)
{
this
.
policyType
=
policyType
;
}
public
String
getPayFrequency
()
{
return
payFrequency
;
}
public
void
setPayFrequency
(
String
payFrequency
)
{
this
.
payFrequency
=
payFrequency
;
}
public
String
getPayCommissionStatus
()
{
return
payCommissionStatus
;
}
public
void
setPayCommissionStatus
(
String
payCommissionStatus
)
{
this
.
payCommissionStatus
=
payCommissionStatus
;
}
public
String
getCommissionType
()
{
return
commissionType
;
}
public
void
setCommissionType
(
String
commissionType
)
{
this
.
commissionType
=
commissionType
;
}
public
String
getHolderIdNoType
()
{
return
holderIdNoType
;
}
public
void
setHolderIdNoType
(
String
holderIdNoType
)
{
this
.
holderIdNoType
=
holderIdNoType
;
}
public
String
getInsuredIdNoType
()
{
return
insuredIdNoType
;
}
public
void
setInsuredIdNoType
(
String
insuredIdNoType
)
{
this
.
insuredIdNoType
=
insuredIdNoType
;
}
}
yd-api/src/main/java/com/yd/dal/entity/order/PolicyFactorInfoE.java
0 → 100644
View file @
2961d4fb
package
com
.
yd
.
dal
.
entity
.
order
;
public
class
PolicyFactorInfoE
{
private
String
orderNo
;
private
String
productId
;
private
String
insuredAmount
;
private
String
relationship
;
private
String
amountUnit
;
private
Integer
period
;
public
String
getOrderNo
()
{
return
orderNo
;
}
public
void
setOrderNo
(
String
orderNo
)
{
this
.
orderNo
=
orderNo
;
}
public
String
getProductId
()
{
return
productId
;
}
public
void
setProductId
(
String
productId
)
{
this
.
productId
=
productId
;
}
public
String
getInsuredAmount
()
{
return
insuredAmount
;
}
public
void
setInsuredAmount
(
String
insuredAmount
)
{
this
.
insuredAmount
=
insuredAmount
;
}
public
String
getRelationship
()
{
return
relationship
;
}
public
void
setRelationship
(
String
relationship
)
{
this
.
relationship
=
relationship
;
}
public
String
getAmountUnit
()
{
return
amountUnit
;
}
public
void
setAmountUnit
(
String
amountUnit
)
{
this
.
amountUnit
=
amountUnit
;
}
public
Integer
getPeriod
()
{
return
period
;
}
public
void
setPeriod
(
Integer
period
)
{
this
.
period
=
period
;
}
}
yd-api/src/main/java/com/yd/dal/entity/product/Product.java
0 → 100644
View file @
2961d4fb
package
com
.
yd
.
dal
.
entity
.
product
;
import
lombok.Data
;
import
java.io.Serializable
;
import
java.math.BigDecimal
;
import
java.util.Date
;
/**
* ag_product
* @author
*/
@Data
public
class
Product
implements
Serializable
{
/**
* serial id
*/
private
Long
id
;
/**
* FK ag_acl_insurer.id
*/
private
Long
insurerId
;
private
String
insurerName
;
/**
* FK ag_acl_insurer_branch.id
*/
private
Long
insurerBranchId
;
/**
* FK ag_product_category.id
*/
private
Long
productCategoryId
;
/**
* Product#
*/
private
String
no
;
/**
* Product Chinese name/Description
*/
private
String
name
;
/**
* Product English name
*/
private
String
nameEn
;
private
String
description
;
/**
* 0000-00-00
*/
private
Date
effectiveStartDate
;
/**
* 0000-00-00
*/
private
Date
effectiveEndDate
;
private
BigDecimal
salePrice
;
/**
* 0=No, 1=Yes
*/
private
Integer
isActive
;
/**
* 保单生效起始日计算 T+X
*/
private
Integer
policyEffCount
;
/**
* 保单生效起始日计算单位 H=时 D=天 W=周 M=月 Y=年
*/
private
String
policyEffCountUnit
;
/**
* 最小保障期限
*/
private
Integer
minCoverTerm
;
/**
* 最小保障期限单位 H=时 D=天 W=周 M=月 Y=年
*/
private
String
minCoverTermUnit
;
/**
* 犹豫期,该产品订单的财富,只有过了犹豫期才能体现(H5)
*/
private
Integer
hesitatePeroid
;
/**
* 1人/天、1人/年
*/
private
String
uiDisplayUnit
;
/**
* 评测icon文章的url
*/
private
String
articleUrl
;
/**
* 是否银盾收保费 0=No, 1=Yes
*/
private
Integer
isPayToYd
;
/**
* 0000-00-00 00:00:00
*/
private
Date
createdAt
;
/**
* FK ag_acl_user.id
*/
private
Long
createdBy
;
/**
* 0000-00-00 00:00:00
*/
private
Date
updatedAt
;
/**
* latest updator
*/
private
Long
updatedBy
;
private
static
final
long
serialVersionUID
=
1L
;
}
\ No newline at end of file
yd-api/src/main/java/com/yd/dal/entity/product/ProductE.java
0 → 100644
View file @
2961d4fb
package
com
.
yd
.
dal
.
entity
.
product
;
public
class
ProductE
{
private
String
productId
;
private
String
productName
;
public
String
getProductId
()
{
return
productId
;
}
public
void
setProductId
(
String
productId
)
{
this
.
productId
=
productId
;
}
public
String
getProductName
()
{
return
productName
;
}
public
void
setProductName
(
String
productName
)
{
this
.
productName
=
productName
;
}
}
yd-api/src/main/java/com/yd/dal/entity/product/ProductPlan.java
0 → 100644
View file @
2961d4fb
package
com
.
yd
.
dal
.
entity
.
product
;
import
lombok.Data
;
import
java.io.Serializable
;
import
java.math.BigDecimal
;
import
java.util.Date
;
/**
* ag_product_plan
* @author
*/
@Data
public
class
ProductPlan
implements
Serializable
{
/**
* serial id
*/
private
Long
id
;
/**
* FK ag_acl_insurer.id
*/
private
Long
insurerId
;
/**
* FK ag_product.id
*/
private
Long
productId
;
/**
* plan#= plan code
*/
private
String
planCode
;
/**
* contract_id for Starr; Risk-Duty code for Fosun
*/
private
String
contractId
;
/**
* plan Chinese name
*/
private
String
name
;
/**
* plan Level name 档次显示
*/
private
String
nameSub
;
/**
* plan Eng name
*/
private
String
nameEn
;
/**
* 0, 1=low, 2=mid 3=high, 4=super
*/
private
Integer
level
;
private
BigDecimal
commisionRate
;
private
BigDecimal
referralRate
;
private
BigDecimal
salePrice
;
/**
* 0000-00-00
*/
private
Date
effectiveStartDate
;
/**
* 0000-00-00
*/
private
Date
effectiveEndDate
;
/**
* 0=No, 1=Yes
*/
private
Integer
isActive
;
/**
* 0=No, 1=Yes
*/
private
Integer
isGlobal
;
/**
* FK ag_acl_continent.id
*/
private
Long
continentId
;
/**
* FK ag_md_country.id
*/
private
Long
countryId
;
/**
* FK ag_md_region.id
*/
private
Long
regionId
;
/**
* 0=No, 1=Yes
*/
private
Integer
isPopular
;
/**
* incremental +1
*/
private
Integer
salesCount
;
/**
* version control
*/
private
Integer
version
;
/**
* 支持社保类型(1-仅支持有社保; 0-仅支持无社保; 3-同时支持有、无社保)
*/
private
Integer
isSocialInsured
;
/**
* 适用性别(1-男;2-女)
*/
private
Integer
appGender
;
/**
* 创建时间
*/
private
Date
createdAt
;
/**
* 创建人
*/
private
Long
createdBy
;
/**
* 修改时间
*/
private
Date
updatedAt
;
/**
* 修改人
*/
private
Long
updatedBy
;
private
static
final
long
serialVersionUID
=
1L
;
}
\ No newline at end of file
yd-api/src/main/java/com/yd/dal/mapper/customer/AclCustomerMapper.java
View file @
2961d4fb
package
com
.
yd
.
dal
.
mapper
.
customer
;
import
com.yd.dal.entity.customer.AclCustomer
;
import
java.util.List
;
import
com.yd.dal.entity.customer.AclCustomer
;
import
org.apache.ibatis.annotations.Param
;
import
java.util.List
;
public
interface
AclCustomerMapper
{
int
deleteByPrimaryKey
(
Long
id
);
...
...
@@ -18,4 +21,6 @@ public interface AclCustomerMapper {
List
<
AclCustomer
>
findByLogin
(
String
mobileNo
);
AclCustomer
findByMobileNo
(
String
mobileNo
);
List
<
AclCustomer
>
findByIds
(
@Param
(
"customerIds"
)
List
<
Long
>
customerIds
);
}
\ No newline at end of file
yd-api/src/main/java/com/yd/dal/mapper/customer/AclPractitionerMapper.java
View file @
2961d4fb
...
...
@@ -46,4 +46,12 @@ public interface AclPractitionerMapper {
List
<
PlayerSalesActivityInfo
>
playerSalesActivityQuery
(
@Param
(
"practitionerId"
)
Long
practitionerId
,
@Param
(
"optionsId"
)
Long
optionsId
);
List
<
AclPractitioner
>
findBySubordinateSystemId
(
@Param
(
"subordinateSystemId"
)
Long
subordinateSystemId
);
String
findMobileNoByPractitionerId
(
@Param
(
"practitionerId"
)
Long
practitionerId
);
PractitionerBasicInfo
findByMobileNoE
(
@Param
(
"mobileNo"
)
String
mobileNo
);
PractitionerRankInfo
getPractitionerRankInfoByPractitionerIdEG
(
@Param
(
"practitionerIdEG"
)
String
practitionerIdEG
,
@Param
(
"time"
)
Integer
time
);
PractitionerRankInfo
getPractitionerRankInfoByPractitionerIdYD
(
@Param
(
"practitionerId"
)
Long
practitionerId
,
@Param
(
"time"
)
Integer
time
);
}
\ No newline at end of file
yd-api/src/main/java/com/yd/dal/mapper/customer/AclPractitionerSubordinateSystemMapper.java
View file @
2961d4fb
...
...
@@ -2,10 +2,8 @@ package com.yd.dal.mapper.customer;
import
com.yd.dal.entity.customer.AclPractitionerSubordinateSystem
;
import
com.yd.dal.entity.customer.practitioner.PractitionerSubordinateInfo
;
import
com.yd.dal.entity.customer.practitioner.SubordinateSystemMemberInfoE
;
import
org.apache.ibatis.annotations.Param
;
import
java.util.List
;
import
java.util.List
;
public
interface
AclPractitionerSubordinateSystemMapper
{
...
...
@@ -28,4 +26,8 @@ public interface AclPractitionerSubordinateSystemMapper {
List
<
AclPractitionerSubordinateSystem
>
findByOwnerPractitionerId
(
Long
practitionerId
);
List
<
AclPractitionerSubordinateSystem
>
findByOwner
(
@Param
(
"practitionerId"
)
Long
practitionerId
);
PractitionerSubordinateInfo
findByOwnerE
(
@Param
(
"practitionerId"
)
String
practitionerId
);
List
<
SubordinateSystemMemberInfoE
>
findStatisticsE
(
@Param
(
"subordinateIdForEGolden"
)
String
subordinateIdForEGolden
,
@Param
(
"time"
)
Integer
time
);
}
\ No newline at end of file
yd-api/src/main/java/com/yd/dal/mapper/marketing/MktLeadsGoalsMapper.java
View file @
2961d4fb
...
...
@@ -25,4 +25,6 @@ public interface MktLeadsGoalsMapper {
List
<
MktLeadsGoals
>
selectByPractitionerIds
(
@Param
(
"practitionerIds"
)
List
<
Long
>
practitionerIds
,
@Param
(
"year"
)
Integer
year
);
List
<
MktLeadsGoals
>
findByTypeAndTimeUnitAndSubordinateSystemId
(
@Param
(
"goalsType"
)
Integer
goalsType
,
@Param
(
"statisticTimeUnit"
)
Integer
statisticTimeUnit
,
@Param
(
"subordinateSystemId"
)
Long
subordinateSystemId
);
List
<
MktLeadsGoals
>
findByTypeAndTimeUnitAndPractitionerId
(
@Param
(
"goalsType"
)
Integer
goalsType
,
@Param
(
"statisticTimeUnit"
)
Integer
statisticTimeUnit
,
@Param
(
"practitionerId"
)
Long
practitionerId
);
}
\ No newline at end of file
yd-api/src/main/java/com/yd/dal/mapper/meta/MdDropOptionsMapper.java
View file @
2961d4fb
package
com
.
yd
.
dal
.
mapper
.
meta
;
import
com.yd.dal.entity.meta.MdDropOptions
;
import
com.yd.dal.entity.meta.OptionsEGolden
;
import
org.apache.ibatis.annotations.Param
;
import
java.util.List
;
...
...
@@ -28,4 +29,6 @@ public interface MdDropOptionsMapper {
MdDropOptions
selectByMasterCodeAndOptionsCode
(
@Param
(
"masterCode"
)
String
masterCode
,
@Param
(
"optionsCode"
)
String
optionsCode
);
List
<
MdDropOptions
>
findByMasterCodeAndOptionsCode
(
@Param
(
"masterCode"
)
String
masterCode
,
@Param
(
"optionsCode"
)
String
optionsCode
);
List
<
OptionsEGolden
>
findByMasterIdsE
(
@Param
(
"materIds"
)
List
<
Integer
>
materIds
);
}
\ No newline at end of file
yd-api/src/main/java/com/yd/dal/mapper/order/PoOrderMapper.java
View file @
2961d4fb
package
com
.
yd
.
dal
.
mapper
.
order
;
import
com.yd.dal.entity.order.CustomerPolicyInfo
;
import
com.yd.dal.entity.order.PoOrder
;
import
com.yd.dal.entity.order.PolicyDetailInfoE
;
import
com.yd.dal.entity.order.PolicyFactorInfoE
;
import
org.apache.ibatis.annotations.Param
;
import
java.util.List
;
...
...
@@ -19,4 +22,14 @@ public interface PoOrderMapper {
int
updateByPrimaryKey
(
PoOrder
record
);
List
<
PoOrder
>
findByStatusAndShareCodeInGroupByCustomerId
(
@Param
(
"status"
)
int
status
,
@Param
(
"customerShareCodes"
)
List
<
String
>
customerShareCodes
);
List
<
CustomerPolicyInfo
>
findPolicyInfoByCustomerId
(
@Param
(
"customerId"
)
Long
customerId
,
@Param
(
"time"
)
Integer
time
);
List
<
CustomerPolicyInfo
>
findPolicyInfoByMobileNoE
(
@Param
(
"mobileNo"
)
String
mobileNo
,
@Param
(
"time"
)
Integer
time
);
String
findOrderNoByPolicyNo
(
@Param
(
"policyNo"
)
String
policyNo
);
List
<
PolicyDetailInfoE
>
findPolicyDetailsInfoByOrderNoE
(
@Param
(
"orderNo"
)
String
orderNo
);
List
<
PolicyFactorInfoE
>
findPolicyFactorByOrderNosE
(
@Param
(
"orderNoList"
)
List
<
String
>
orderNoList
);
}
\ No newline at end of file
yd-api/src/main/java/com/yd/dal/mapper/product/ProductMapper.java
0 → 100644
View file @
2961d4fb
package
com
.
yd
.
dal
.
mapper
.
product
;
import
com.yd.dal.entity.product.Product
;
import
com.yd.dal.entity.product.ProductE
;
import
java.util.List
;
public
interface
ProductMapper
{
int
deleteByPrimaryKey
(
Long
id
);
int
insert
(
Product
record
);
int
insertSelective
(
Product
record
);
Product
selectByPrimaryKey
(
Long
id
);
int
updateByPrimaryKeySelective
(
Product
record
);
int
updateByPrimaryKey
(
Product
record
);
List
<
Product
>
findAll
();
List
<
ProductE
>
findAllE
();
}
\ No newline at end of file
yd-api/src/main/java/com/yd/dal/mapper/product/ProductPlanMapper.java
0 → 100644
View file @
2961d4fb
package
com
.
yd
.
dal
.
mapper
.
product
;
import
com.yd.dal.entity.product.ProductPlan
;
import
java.util.List
;
public
interface
ProductPlanMapper
{
int
deleteByPrimaryKey
(
Long
id
);
int
insert
(
ProductPlan
record
);
int
insertSelective
(
ProductPlan
record
);
ProductPlan
selectByPrimaryKey
(
Long
id
);
int
updateByPrimaryKeySelective
(
ProductPlan
record
);
int
updateByPrimaryKey
(
ProductPlan
record
);
List
<
ProductPlan
>
findAll
();
}
\ No newline at end of file
yd-api/src/main/java/com/yd/dal/service/customer/AclCustomerDALService.java
View file @
2961d4fb
...
...
@@ -32,5 +32,7 @@ public interface AclCustomerDALService {
AclCustomer
findByCustomerId
(
Long
customerId
);
AclCustomer
findByMobileNo
(
String
mobileNo
);
List
<
AclCustomer
>
findByIds
(
List
<
Long
>
customerIds
);
}
yd-api/src/main/java/com/yd/dal/service/customer/AclPractitionerDALService.java
View file @
2961d4fb
...
...
@@ -102,4 +102,41 @@ public interface AclPractitionerDALService {
* @return
*/
List
<
AclPractitioner
>
findBySubordinateSystemId
(
Long
subordinateSystemId
);
/**
* 更具经纪人id查询该经纪人手机号码
* @param practitionerId 经纪人id
* @return 查询结果
*/
String
findMobileNoByPractitionerId
(
Long
practitionerId
);
/**
* EGolden -- 根据手机号码查询经纪人的基本信息
* @param mobileNo 手机号码
* @return 查询结果
*/
PractitionerBasicInfo
findByMobileNoE
(
String
mobileNo
);
/**
* 根据id查询经纪人信息
* @param practitionerId 经纪人id
* @return 查询结果
*/
AclPractitioner
findById
(
Long
practitionerId
);
/**
* EGolden -- 根据practitionerId和时间段查询
* @param practitionerIdEG 经纪人id
* @param time 时间
* @return 返回结果
*/
PractitionerRankInfo
getPractitionerRankInfoByPractitionerIdEG
(
String
practitionerIdEG
,
Integer
time
);
/**
* YD -- 根据practitionerId和时间段查询
* @param practitionerId 经纪人id
* @param time 时间
* @return 返回结果
*/
PractitionerRankInfo
getPractitionerRankInfoByPractitionerIdYD
(
Long
practitionerId
,
Integer
time
);
}
yd-api/src/main/java/com/yd/dal/service/customer/AclPractitionerSubordinateSystemDALService.java
View file @
2961d4fb
...
...
@@ -2,6 +2,7 @@ package com.yd.dal.service.customer;
import
com.yd.dal.entity.customer.AclPractitionerSubordinateSystem
;
import
com.yd.dal.entity.customer.practitioner.PractitionerSubordinateInfo
;
import
com.yd.dal.entity.customer.practitioner.SubordinateSystemMemberInfoE
;
import
org.springframework.stereotype.Service
;
import
java.util.List
;
...
...
@@ -17,4 +18,7 @@ public interface AclPractitionerSubordinateSystemDALService {
List
<
AclPractitionerSubordinateSystem
>
findByOwner
(
Long
practitionerId
);
PractitionerSubordinateInfo
findByOwnerE
(
String
practitionerId
);
List
<
SubordinateSystemMemberInfoE
>
findStatisticsE
(
String
subordinateIdForEGolden
,
Integer
time
);
}
yd-api/src/main/java/com/yd/dal/service/customer/impl/AclCustomerDALServiceImpl.java
View file @
2961d4fb
...
...
@@ -47,4 +47,9 @@ public class AclCustomerDALServiceImpl implements AclCustomerDALService {
return
aclCustomerMapper
.
findByMobileNo
(
mobileNo
);
}
@Override
public
List
<
AclCustomer
>
findByIds
(
List
<
Long
>
customerIds
)
{
return
aclCustomerMapper
.
findByIds
(
customerIds
);
}
}
yd-api/src/main/java/com/yd/dal/service/customer/impl/AclPractitionerDALServiceImpl.java
View file @
2961d4fb
...
...
@@ -9,6 +9,7 @@ import com.yd.dal.entity.customer.practitioner.PractitionerInfo;
import
com.yd.dal.entity.customer.practitioner.PractitionerRankInfo
;
import
com.yd.dal.mapper.customer.AclPractitionerMapper
;
import
com.yd.dal.service.customer.AclPractitionerDALService
;
import
com.yd.util.deshandler.DESTypeHandler
;
import
com.yd.util.intercept.annotation.TargetDataSource
;
import
com.yd.util.intercept.commons.DataSourceKey
;
import
org.apache.log4j.Logger
;
...
...
@@ -102,4 +103,36 @@ public class AclPractitionerDALServiceImpl implements AclPractitionerDALService
public
List
<
AclPractitioner
>
findBySubordinateSystemId
(
Long
subordinateSystemId
)
{
return
aclPractitionerMapper
.
findBySubordinateSystemId
(
subordinateSystemId
);
}
@Override
public
String
findMobileNoByPractitionerId
(
Long
practitionerId
)
{
String
mobileNo
=
aclPractitionerMapper
.
findMobileNoByPractitionerId
(
practitionerId
);
if
(!
Strings
.
isNullOrEmpty
(
mobileNo
)){
DESTypeHandler
jpaCryptoConverter
=
new
DESTypeHandler
();
mobileNo
=
jpaCryptoConverter
.
decode
(
mobileNo
);
}
return
mobileNo
;
}
@Override
@TargetDataSource
(
dataSourceKey
=
DataSourceKey
.
DB_EGOLDEN
)
public
PractitionerBasicInfo
findByMobileNoE
(
String
mobileNo
)
{
return
aclPractitionerMapper
.
findByMobileNoE
(
mobileNo
);
}
@Override
public
AclPractitioner
findById
(
Long
practitionerId
)
{
return
aclPractitionerMapper
.
selectByPrimaryKey
(
practitionerId
);
}
@Override
@TargetDataSource
(
dataSourceKey
=
DataSourceKey
.
DB_EGOLDEN
)
public
PractitionerRankInfo
getPractitionerRankInfoByPractitionerIdEG
(
String
practitionerIdEG
,
Integer
time
)
{
return
aclPractitionerMapper
.
getPractitionerRankInfoByPractitionerIdEG
(
practitionerIdEG
,
time
);
}
@Override
public
PractitionerRankInfo
getPractitionerRankInfoByPractitionerIdYD
(
Long
practitionerId
,
Integer
time
)
{
return
aclPractitionerMapper
.
getPractitionerRankInfoByPractitionerIdYD
(
practitionerId
,
time
);
}
}
yd-api/src/main/java/com/yd/dal/service/customer/impl/AclPractitionerSubordinateSystemDALServiceImpl.java
View file @
2961d4fb
...
...
@@ -2,8 +2,11 @@ package com.yd.dal.service.customer.impl;
import
com.yd.dal.entity.customer.AclPractitionerSubordinateSystem
;
import
com.yd.dal.entity.customer.practitioner.PractitionerSubordinateInfo
;
import
com.yd.dal.entity.customer.practitioner.SubordinateSystemMemberInfoE
;
import
com.yd.dal.mapper.customer.AclPractitionerSubordinateSystemMapper
;
import
com.yd.dal.service.customer.AclPractitionerSubordinateSystemDALService
;
import
com.yd.util.intercept.annotation.TargetDataSource
;
import
com.yd.util.intercept.commons.DataSourceKey
;
import
org.springframework.stereotype.Service
;
import
javax.annotation.Resource
;
...
...
@@ -40,4 +43,16 @@ public class AclPractitionerSubordinateSystemDALServiceImpl implements AclPracti
public
List
<
AclPractitionerSubordinateSystem
>
findByOwner
(
Long
practitionerId
)
{
return
aclPractitionerSubordinateSystemMapper
.
findByOwner
(
practitionerId
);
}
@Override
@TargetDataSource
(
dataSourceKey
=
DataSourceKey
.
DB_EGOLDEN
)
public
PractitionerSubordinateInfo
findByOwnerE
(
String
practitionerId
)
{
return
aclPractitionerSubordinateSystemMapper
.
findByOwnerE
(
practitionerId
);
}
@Override
@TargetDataSource
(
dataSourceKey
=
DataSourceKey
.
DB_EGOLDEN
)
public
List
<
SubordinateSystemMemberInfoE
>
findStatisticsE
(
String
subordinateIdForEGolden
,
Integer
time
)
{
return
aclPractitionerSubordinateSystemMapper
.
findStatisticsE
(
subordinateIdForEGolden
,
time
);
}
}
yd-api/src/main/java/com/yd/dal/service/marketing/Impl/MktLeadsGoalsDALServiceImpl.java
View file @
2961d4fb
...
...
@@ -37,4 +37,9 @@ public class MktLeadsGoalsDALServiceImpl implements MktLeadsGoalsDALService {
public
List
<
MktLeadsGoals
>
findByTypeAndTimeUnitAndSubordinateSystemId
(
Integer
goalsType
,
Integer
statisticTimeUnit
,
Long
subordinateSystemId
)
{
return
mktLeadsGoalsMapper
.
findByTypeAndTimeUnitAndSubordinateSystemId
(
goalsType
,
statisticTimeUnit
,
subordinateSystemId
);
}
@Override
public
List
<
MktLeadsGoals
>
findByTypeAndTimeUnitAndPractitionerId
(
Integer
goalsType
,
Integer
statisticTimeUnit
,
Long
practitionerId
)
{
return
mktLeadsGoalsMapper
.
findByTypeAndTimeUnitAndPractitionerId
(
goalsType
,
statisticTimeUnit
,
practitionerId
);
}
}
yd-api/src/main/java/com/yd/dal/service/marketing/MktLeadsGoalsDALService.java
View file @
2961d4fb
...
...
@@ -15,4 +15,6 @@ public interface MktLeadsGoalsDALService {
List
<
MktLeadsGoals
>
selectByPractitionerIds
(
List
<
Long
>
practitionerIds
,
int
year
);
List
<
MktLeadsGoals
>
findByTypeAndTimeUnitAndSubordinateSystemId
(
Integer
goalsType
,
Integer
statisticTimeUnit
,
Long
subordinateSystemId
);
List
<
MktLeadsGoals
>
findByTypeAndTimeUnitAndPractitionerId
(
Integer
goalsType
,
Integer
statisticTimeUnit
,
Long
practitionerId
);
}
yd-api/src/main/java/com/yd/dal/service/meta/MdDropOptionsDALService.java
View file @
2961d4fb
package
com
.
yd
.
dal
.
service
.
meta
;
import
com.yd.dal.entity.meta.MdDropOptions
;
import
com.yd.dal.entity.meta.OptionsEGolden
;
import
java.util.List
;
public
interface
MdDropOptionsDALService
{
...
...
@@ -18,4 +19,6 @@ public interface MdDropOptionsDALService {
MdDropOptions
selectByMasterCodeAndOptionsCode
(
String
masterCode
,
String
optionsCode
);
List
<
MdDropOptions
>
findByMasterCodeAndOptionsCode
(
String
team_building_track
,
String
s
);
List
<
OptionsEGolden
>
findByMasterIdsE
(
List
<
Integer
>
materIds
);
}
yd-api/src/main/java/com/yd/dal/service/meta/impl/MdDropOptionsDALServiceImpl.java
View file @
2961d4fb
package
com
.
yd
.
dal
.
service
.
meta
.
impl
;
import
com.yd.dal.entity.meta.MdDropOptions
;
import
com.yd.dal.entity.meta.OptionsEGolden
;
import
com.yd.dal.mapper.meta.MdDropOptionsMapper
;
import
com.yd.dal.service.meta.MdDropOptionsDALService
;
import
com.yd.util.intercept.annotation.TargetDataSource
;
import
com.yd.util.intercept.commons.DataSourceKey
;
import
org.springframework.stereotype.Service
;
import
javax.annotation.Resource
;
import
java.util.List
;
...
...
@@ -52,4 +55,10 @@ public class MdDropOptionsDALServiceImpl implements MdDropOptionsDALService {
public
List
<
MdDropOptions
>
findByMasterCodeAndOptionsCode
(
String
masterCode
,
String
optionsCode
)
{
return
mdDropOptionsMapper
.
findByMasterCodeAndOptionsCode
(
masterCode
,
optionsCode
);
}
@Override
@TargetDataSource
(
dataSourceKey
=
DataSourceKey
.
DB_EGOLDEN
)
public
List
<
OptionsEGolden
>
findByMasterIdsE
(
List
<
Integer
>
materIds
)
{
return
mdDropOptionsMapper
.
findByMasterIdsE
(
materIds
);
}
}
yd-api/src/main/java/com/yd/dal/service/order/Impl/PoOrderDALServiceImpl.java
View file @
2961d4fb
package
com
.
yd
.
dal
.
service
.
order
.
Impl
;
import
com.yd.dal.entity.order.CustomerPolicyInfo
;
import
com.yd.dal.entity.order.PoOrder
;
import
com.yd.dal.entity.order.PolicyDetailInfoE
;
import
com.yd.dal.entity.order.PolicyFactorInfoE
;
import
com.yd.dal.mapper.order.PoOrderMapper
;
import
com.yd.dal.service.order.PoOrderDALService
;
import
com.yd.util.intercept.annotation.TargetDataSource
;
import
com.yd.util.intercept.commons.DataSourceKey
;
import
org.springframework.stereotype.Service
;
import
javax.annotation.Resource
;
...
...
@@ -22,4 +27,33 @@ public class PoOrderDALServiceImpl implements PoOrderDALService {
public
PoOrder
findByOrderId
(
Long
orderId
)
{
return
poOrderMapper
.
selectByPrimaryKey
(
orderId
);
}
@Override
public
List
<
CustomerPolicyInfo
>
findPolicyInfoByCustomerId
(
Long
customerId
,
Integer
time
)
{
return
poOrderMapper
.
findPolicyInfoByCustomerId
(
customerId
,
time
);
}
@Override
@TargetDataSource
(
dataSourceKey
=
DataSourceKey
.
DB_EGOLDEN
)
public
List
<
CustomerPolicyInfo
>
findPolicyInfoByMobileNoE
(
String
mobileNo
,
Integer
time
)
{
return
poOrderMapper
.
findPolicyInfoByMobileNoE
(
mobileNo
,
time
);
}
@Override
@TargetDataSource
(
dataSourceKey
=
DataSourceKey
.
DB_EGOLDEN
)
public
String
findOrderNoByPolicyNo
(
String
policyNo
)
{
return
poOrderMapper
.
findOrderNoByPolicyNo
(
policyNo
);
}
@Override
@TargetDataSource
(
dataSourceKey
=
DataSourceKey
.
DB_EGOLDEN
)
public
List
<
PolicyDetailInfoE
>
findPolicyDetailsInfoByOrderNoE
(
String
orderNo
)
{
return
poOrderMapper
.
findPolicyDetailsInfoByOrderNoE
(
orderNo
);
}
@Override
@TargetDataSource
(
dataSourceKey
=
DataSourceKey
.
DB_EGOLDEN
)
public
List
<
PolicyFactorInfoE
>
findPolicyFactorByOrderNosE
(
List
<
String
>
orderNoList
)
{
return
poOrderMapper
.
findPolicyFactorByOrderNosE
(
orderNoList
);
}
}
yd-api/src/main/java/com/yd/dal/service/order/PoOrderDALService.java
View file @
2961d4fb
package
com
.
yd
.
dal
.
service
.
order
;
import
com.yd.dal.entity.order.CustomerPolicyInfo
;
import
com.yd.dal.entity.order.PoOrder
;
import
com.yd.dal.entity.order.PolicyDetailInfoE
;
import
com.yd.dal.entity.order.PolicyFactorInfoE
;
import
java.util.List
;
...
...
@@ -8,4 +11,14 @@ public interface PoOrderDALService {
List
<
PoOrder
>
findByStatusAndShareCodeInGroupByCustomerId
(
int
status
,
List
<
String
>
customerShareCodes
);
PoOrder
findByOrderId
(
Long
orderId
);
List
<
CustomerPolicyInfo
>
findPolicyInfoByCustomerId
(
Long
customerId
,
Integer
time
);
List
<
CustomerPolicyInfo
>
findPolicyInfoByMobileNoE
(
String
mobileNo
,
Integer
time
);
String
findOrderNoByPolicyNo
(
String
policyNo
);
List
<
PolicyDetailInfoE
>
findPolicyDetailsInfoByOrderNoE
(
String
orderNo
);
List
<
PolicyFactorInfoE
>
findPolicyFactorByOrderNosE
(
List
<
String
>
orderNoList
);
}
yd-api/src/main/java/com/yd/dal/service/product/ProductDALService.java
0 → 100644
View file @
2961d4fb
package
com
.
yd
.
dal
.
service
.
product
;
import
com.yd.dal.entity.product.Product
;
import
com.yd.dal.entity.product.ProductE
;
import
org.springframework.stereotype.Service
;
import
java.util.List
;
@Service
(
"productDALService"
)
public
interface
ProductDALService
{
List
<
Product
>
findAll
();
List
<
ProductE
>
findAllE
();
}
yd-api/src/main/java/com/yd/dal/service/product/ProductPlanDALService.java
0 → 100644
View file @
2961d4fb
package
com
.
yd
.
dal
.
service
.
product
;
import
com.yd.dal.entity.product.ProductPlan
;
import
org.springframework.stereotype.Service
;
import
java.util.List
;
@Service
(
"productPlanDALService"
)
public
interface
ProductPlanDALService
{
List
<
ProductPlan
>
findAll
();
}
yd-api/src/main/java/com/yd/dal/service/product/impl/ProductDALServiceImpl.java
0 → 100644
View file @
2961d4fb
package
com
.
yd
.
dal
.
service
.
product
.
impl
;
import
com.yd.dal.entity.product.Product
;
import
com.yd.dal.entity.product.ProductE
;
import
com.yd.dal.mapper.product.ProductMapper
;
import
com.yd.dal.service.product.ProductDALService
;
import
com.yd.util.intercept.annotation.TargetDataSource
;
import
com.yd.util.intercept.commons.DataSourceKey
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
java.util.List
;
@Service
(
"productDALService"
)
public
class
ProductDALServiceImpl
implements
ProductDALService
{
@Autowired
private
ProductMapper
productMapper
;
@Override
public
List
<
Product
>
findAll
()
{
return
productMapper
.
findAll
();
}
@Override
@TargetDataSource
(
dataSourceKey
=
DataSourceKey
.
DB_EGOLDEN
)
public
List
<
ProductE
>
findAllE
()
{
return
productMapper
.
findAllE
();
}
}
yd-api/src/main/java/com/yd/dal/service/product/impl/ProductPlanDALServiceImpl.java
0 → 100644
View file @
2961d4fb
package
com
.
yd
.
dal
.
service
.
product
.
impl
;
import
com.yd.dal.entity.product.ProductPlan
;
import
com.yd.dal.mapper.product.ProductPlanMapper
;
import
com.yd.dal.service.product.ProductPlanDALService
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
java.util.List
;
@Service
(
"productPlanDALService"
)
public
class
ProductPlanDALServiceImpl
implements
ProductPlanDALService
{
@Autowired
private
ProductPlanMapper
productPlanMapper
;
@Override
public
List
<
ProductPlan
>
findAll
()
{
return
productPlanMapper
.
findAll
();
}
}
yd-api/src/main/resources/application-dev.properties
View file @
2961d4fb
...
...
@@ -18,9 +18,9 @@ multiple.datasource.master.password=devdbpass1
#egolden
multiple.datasource.egolden.driver-class-name
=
com.mysql.jdbc.Driver
multiple.datasource.egolden.url
=
jdbc:MySql://139.224.
94.140:13307/
ydinsurance?characterEncoding=UTF-8&useSSL=false&useAffectedRows=true
multiple.datasource.egolden.username
=
stageuser
multiple.datasource.egolden.password
=
AG@#$mstage234
multiple.datasource.egolden.url
=
jdbc:MySql://139.224.
138.103:13308/stage_
ydinsurance?characterEncoding=UTF-8&useSSL=false&useAffectedRows=true
multiple.datasource.egolden.username
=
insurance_stage
multiple.datasource.egolden.password
=
fWTauSswR2!$
#pagehelper分页插件配置
pagehelper.helperDialect
=
mysql
...
...
yd-api/src/main/resources/application-local.properties
View file @
2961d4fb
...
...
@@ -18,9 +18,9 @@ multiple.datasource.master.password=devdbpass1
#egolden
multiple.datasource.egolden.driver-class-name
=
com.mysql.jdbc.Driver
multiple.datasource.egolden.url
=
jdbc:MySql://139.224.
94.140:13307/
ydinsurance?characterEncoding=UTF-8&useSSL=false&useAffectedRows=true
multiple.datasource.egolden.username
=
stageuser
multiple.datasource.egolden.password
=
AG@#$mstage234
multiple.datasource.egolden.url
=
jdbc:MySql://139.224.
138.103:13308/stage_
ydinsurance?characterEncoding=UTF-8&useSSL=false&useAffectedRows=true
multiple.datasource.egolden.username
=
insurance_stage
multiple.datasource.egolden.password
=
fWTauSswR2!$
#pagehelper分页插件配置
pagehelper.helperDialect
=
mysql
...
...
yd-api/src/main/resources/mapper/customer/AclCustomerFortuneMapper.xml
View file @
2961d4fb
...
...
@@ -296,9 +296,9 @@
p.id practitionerId ,
p.`name` name ,
p.subordinate_system_id subordinateSystemId ,
COUNT(f.id
) count ,
SUM(f.order_price
) FYP ,
SUM(f.referral_amount
) FYC ,
ifnull(COUNT(f.id),0
) count ,
ifnull(SUM(f.order_price),0
) FYP ,
ifnull(SUM(f.fyc_amount),0
) FYC ,
s.practitioner_level practitionerLevelId
FROM
((ag_acl_practitioner_setting s LEFT JOIN ag_acl_practitioner p ON s.practitioner_id = p.id)
...
...
yd-api/src/main/resources/mapper/customer/AclCustomerMapper.xml
View file @
2961d4fb
...
...
@@ -771,4 +771,13 @@
from ag_acl_customer
where mobile_no = #{mobileNo,jdbcType=VARCHAR,typeHandler=com.yd.util.deshandler.DESTypeHandler}
</select>
<select
id=
"findByIds"
resultMap=
"BaseResultMap"
>
select
<include
refid=
"Base_Column_List"
/>
from ag_acl_customer
where id in
<foreach
collection=
"customerIds"
index=
"index"
item=
"item"
open=
"("
separator=
","
close=
")"
>
#{item}
</foreach>
</select>
</mapper>
\ No newline at end of file
yd-api/src/main/resources/mapper/customer/AclPractitionerMapper.xml
View file @
2961d4fb
...
...
@@ -540,30 +540,62 @@
<result
column=
"fyc"
property=
"fyc"
/>
</resultMap>
<!-- <select id="getPractitionerRankInfoForOffline" resultMap="practitioner_rank_map" resultType="java.lang.Integer">-->
<!-- SELECT-->
<!-- p.SAL_MST_ID as practitionerId ,-->
<!-- p.SAL_MST_NAME as name ,-- 姓名-->
<!-- md.DRP_TITLE_LEVEL as titleCode,-- 职称code-->
<!-- md.DRP_TITLE_NAME as titleName,-- 职称名称-->
<!-- spc.SPC_DIV_NAME as spcDivName,-- 体系id-->
<!-- ifnull(count(m.MON025_002),0) as count,-- 保单id-->
<!-- ifnull(sum(m.MON025_401),0) as fyp,-- 保费-->
<!-- ifnull(sum(policy.INS001_FYCTOTAL),0) as fyc -- 应发佣金-->
<!-- FROM MON025 m INNER JOIN sal001 p on m.MON025_007 = p.SAL_MST_ID -- 业务员id-->
<!-- left join DRP003 md on p.FK_DRP_TITLE_CODE = md.DRP_TITLE_CODE-->
<!-- inner JOIN ins001 policy on m.MON025_002 = policy.INS_MST_ID -- 保单id-->
<!-- inner join spc004 spc on m.MON025_006 = spc.SPC_DIV_ID -- 体系-->
<!-- WHERE m.MON025_109 IN (1,2,3) AND m.MON025_303 = 1 AND m.mon025_108 = 'S01'-->
<!-- <choose>-->
<!-- <when test="time == 1">-->
<!-- and DATE_FORMAT(policy.INS_MST_ACCEPT_DATE, '%Y%m' ) = DATE_FORMAT( CURDATE( ) , '%Y%m' )-->
<!-- </when>-->
<!-- <when test="time == 3">-->
<!-- and QUARTER(policy.INS_MST_ACCEPT_DATE) = QUARTER(NOW()) AND year(policy.INS_MST_ACCEPT_DATE)=year(now())-->
<!-- </when>-->
<!-- <otherwise>-->
<!-- and YEAR(policy.INS_MST_ACCEPT_DATE) = YEAR(now())-->
<!-- </otherwise>-->
<!-- </choose>-->
<!-- group by p.SAL_MST_ID;-->
<!-- </select>-->
<select
id=
"getPractitionerRankInfoForOffline"
resultMap=
"practitioner_rank_map"
resultType=
"java.lang.Integer"
>
SELECT
p.SAL_MST_ID as practitionerId ,
p.SAL_MST_NAME as name ,-- 姓名
md.DRP_TITLE_LEVEL
as titleCode,-- 职称code
md.DRP_TITLE_NAM
E as titleName,-- 职称名称
p.SAL_MST_ID_TYPE
as titleCode,-- 职称code
p.SAL_MST_OFFICIAL_TITL
E as titleName,-- 职称名称
spc.SPC_DIV_NAME as spcDivName,-- 体系id
count(m.MON025_002) as count,-- 保单id
sum(m.MON025_401) as fyp,-- 保费
sum(m.MON025_405) as fyc -- 应发佣金
FROM MON025 m INNER JOIN sal001 p on m.MON025_007 = p.SAL_MST_ID -- 业务员id
left join DRP003 md on p.FK_DRP_TITLE_CODE = md.DRP_TITLE_CODE
inner JOIN ins001 policy on m.MON025_002 = policy.INS_MST_ID -- 保单id
ifnull(count(distinct policy.INS_MST_ID),0) as count,-- 保单id
ifnull(sum(policy.INS_MST_TOTAL_PREIUM),0) as fyp,-- 保费
ifnull(sum(policy.INS001_FYCTOTAL),0) as fyc -- 应发佣金
FROM
ins001 policy INNER JOIN mon025 m on policy.INS_MST_ID = m.MON025_002 and m.MON025_109 IN (1,2,3) AND m.MON025_303 = 1 AND m.mon025_108 = 'S01'
INNER JOIN (
SELECT mon025_002,MAX(MON025_405) as MON025_405 FROM mon025 group by mon025_002 ORDER BY mon025_002
) b on m.mon025_002 = b.mon025_002 AND m.MON025_405 = b.MON025_405
INNER JOIN sal001 p on m.MON025_007 = p.SAL_MST_ID -- 业务员id
inner join spc004 spc on m.MON025_006 = spc.SPC_DIV_ID -- 体系
WHERE m.MON025_109 IN (1,2,3) AND m.MON025_303 = 1
where
<choose>
<when
test=
"time == 1"
>
and
DATE_FORMAT(policy.INS_MST_ACCEPT_DATE, '%Y%m' ) = DATE_FORMAT( CURDATE( ) , '%Y%m' )
DATE_FORMAT(policy.INS_MST_ACCEPT_DATE, '%Y%m' ) = DATE_FORMAT( CURDATE( ) , '%Y%m' )
</when>
<when
test=
"time == 3"
>
and
QUARTER(policy.INS_MST_ACCEPT_DATE) = QUARTER(NOW()) AND year(policy.INS_MST_ACCEPT_DATE)=year(now())
QUARTER(policy.INS_MST_ACCEPT_DATE) = QUARTER(NOW()) AND year(policy.INS_MST_ACCEPT_DATE)=year(now())
</when>
<otherwise>
and
YEAR(policy.INS_MST_ACCEPT_DATE) = YEAR(now())
YEAR(policy.INS_MST_ACCEPT_DATE) = YEAR(now())
</otherwise>
</choose>
group by p.SAL_MST_ID;
...
...
@@ -575,14 +607,14 @@
p.id as practitionerIdForOnLine ,
p.name as name ,-- 姓名
ss.name as spcDivName,-- 体系id
count(f.id
) as count,-- 保单id
sum(f.order_price
) as fyp,-- 保费
sum(f.referral_amount
) as fyc -- 应发佣金
FROM ag_acl_customer_fortune f INNER JOIN ag_po_order o ON f.order_id = o.id
ifnull(count(f.id),0
) as count,-- 保单id
ifnull(sum(f.order_price),0
) as fyp,-- 保费
ifnull(sum(f.fyc_amount),0
) as fyc -- 应发佣金
FROM ag_acl_customer_fortune f INNER JOIN ag_po_order o ON f.order_id = o.id
and o.order_price > 0
inner JOIN ag_acl_practitioner p ON f.customer_id = p.customer_id
left join ag_acl_practitioner_setting s on p.id = s.practitioner_id
left join ag_acl_practitioner_subordinate_system ss on p.subordinate_system_id = ss.id
WHERE o.status = 3
and o.order_price > 0
WHERE o.status = 3
<if
test=
"practitionerTypeId != null"
>
and s.practitioner_type_id = #{practitionerTypeId}
</if>
...
...
@@ -607,14 +639,14 @@
p.id as practitionerIdForOnLine ,
p.name as name ,-- 姓名
ss.name as spcDivName,-- 体系id
count(f.id
) as count,-- 保单id
sum(f.order_price
) as fyp,-- 保费
sum(f.referral_amount
) as fyc -- 应发佣金
FROM ag_acl_customer_fortune f INNER JOIN ag_po_order o ON f.order_id = o.id
ifnull(count(f.id),0
) as count,-- 保单id
ifnull(sum(f.order_price),0
) as fyp,-- 保费
ifnull(sum(f.fyc_amount),0
) as fyc -- 应发佣金
FROM ag_acl_customer_fortune f INNER JOIN ag_po_order o ON f.order_id = o.id
and o.order_price > 0
inner JOIN ag_acl_practitioner p ON f.customer_id = p.customer_id
left join ag_acl_customer c on p.customer_id = c.id
left join ag_acl_practitioner_subordinate_system ss on p.subordinate_system_id = ss.id
WHERE o.status = 3
and o.order_price > 0
WHERE o.status = 3
and c.login in
<foreach
collection=
"mobileSpecials"
index=
"index"
item=
"item"
open=
"("
separator=
","
close=
")"
>
#{item}
...
...
@@ -765,4 +797,77 @@
from ag_acl_practitioner
where subordinate_system_id = #{subordinateSystemId,jdbcType=BIGINT} and is_active = 1
</select>
<select
id=
"findMobileNoByPractitionerId"
resultType=
"java.lang.String"
>
select c.mobile_no
from ag_acl_practitioner p left join ag_acl_customer c on p.customer_id = c.id and c.is_active = 1
where p.id = #{practitionerId,jdbcType=BIGINT} limit 1;
</select>
<select
id=
"findByMobileNoE"
resultType=
"com.yd.dal.entity.customer.practitioner.PractitionerBasicInfo"
>
SELECT
p.SAL_MST_ID as practitionerId,
p.SAL_MST_NAME as name,
p.SAL_MST_GENDER as gender,
p.SAL_MST_ID_TYPE as titleCode,
p.SAL_MST_OFFICIAL_TITLE as titleName
FROM sal001 p
where p.SAL_MST_MOBILE like concat(concat('%',#{mobileNo,jdbcType=VARCHAR}),'%')
</select>
<select
id=
"getPractitionerRankInfoByPractitionerIdEG"
resultType=
"com.yd.dal.entity.customer.practitioner.PractitionerRankInfo"
>
SELECT
p.SAL_MST_ID as practitionerId ,
p.SAL_MST_NAME as name ,-- 姓名
p.SAL_MST_ID_TYPE as titleCode,-- 职称code
p.SAL_MST_OFFICIAL_TITLE as titleName,-- 职称名称
spc.SPC_DIV_NAME as spcDivName,-- 体系id
ifnull(count(distinct policy.INS_MST_ID),0) as count,-- 保单id
ifnull(sum(policy.INS_MST_TOTAL_PREIUM),0) as fyp,-- 保费
ifnull(sum(policy.INS001_FYCTOTAL),0) as fyc -- 应发佣金
FROM
ins001 policy INNER JOIN mon025 m on policy.INS_MST_ID = m.MON025_002 and m.MON025_109 IN (1,2,3) AND m.MON025_303 = 1 AND m.mon025_108 = 'S01'
INNER JOIN (
SELECT mon025_002,MAX(MON025_405) as MON025_405 FROM mon025 group by mon025_002 ORDER BY mon025_002
) b on m.mon025_002 = b.mon025_002 AND m.MON025_405 = b.MON025_405
INNER JOIN sal001 p on m.MON025_007 = p.SAL_MST_ID -- 业务员id
inner join spc004 spc on m.MON025_006 = spc.SPC_DIV_ID -- 体系
where p.SAL_MST_ID = #{practitionerIdEG,jdbcType=VARCHAR}
<choose>
<when
test=
"time == 1"
>
and DATE_FORMAT(policy.INS_MST_ACCEPT_DATE, '%Y%m' ) = DATE_FORMAT( CURDATE( ) , '%Y%m' )
</when>
<when
test=
"time == 3"
>
and QUARTER(policy.INS_MST_ACCEPT_DATE) = QUARTER(NOW()) AND year(policy.INS_MST_ACCEPT_DATE)=year(now())
</when>
<otherwise>
and YEAR(policy.INS_MST_ACCEPT_DATE) = YEAR(now())
</otherwise>
</choose>
</select>
<select
id=
"getPractitionerRankInfoByPractitionerIdYD"
resultType=
"com.yd.dal.entity.customer.practitioner.PractitionerRankInfo"
>
SELECT
p.customer_id as customerId,
p.id as practitionerIdForOnLine ,
p.name as name ,-- 姓名
ss.name as spcDivName,-- 体系id
ifnull(count(f.id),0) as count,-- 保单id
ifnull(sum(f.order_price),0) as fyp,-- 保费
ifnull(sum(f.fyc_amount),0) as fyc -- 应发佣金
FROM ag_acl_customer_fortune f INNER JOIN ag_po_order o ON f.order_id = o.id and o.status = 3 and o.order_price > 0
inner JOIN ag_acl_practitioner p ON f.customer_id = p.customer_id
left join ag_acl_practitioner_setting s on p.id = s.practitioner_id
left join ag_acl_practitioner_subordinate_system ss on p.subordinate_system_id = ss.id
WHERE p.id = #{practitionerId,jdbcType=BIGINT}
<choose>
<when
test=
"time == 1"
>
and DATE_FORMAT(f.order_date, '%Y%m' ) = DATE_FORMAT( CURDATE( ) , '%Y%m' )
</when>
<when
test=
"time == 3"
>
and QUARTER(f.order_date) = QUARTER(NOW()) AND year(f.order_date)=year(now())
</when>
<otherwise>
and YEAR(f.order_date) = YEAR(now())
</otherwise>
</choose>
</select>
</mapper>
\ No newline at end of file
yd-api/src/main/resources/mapper/customer/AclPractitionerSubordinateSystemMapper.xml
View file @
2961d4fb
...
...
@@ -260,4 +260,38 @@
from ag_acl_practitioner_subordinate_system
where owner_practitioner_id = #{practitionerId,jdbcType=BIGINT} and is_active = 1
</select>
<select
id=
"findByOwnerE"
resultType=
"com.yd.dal.entity.customer.practitioner.PractitionerSubordinateInfo"
>
SELECT
p.SPC_DIV_NAME as subordinateName,
p.SPC_DIV_ID as subordinateCode,
p.FK_DIV_BOSS_ID as subordinateLeader
FROM spc004 p
where p.FK_DIV_BOSS_ID = #{practitionerId,jdbcType=VARCHAR}
</select>
<select
id=
"findStatisticsE"
resultType=
"com.yd.dal.entity.customer.practitioner.SubordinateSystemMemberInfoE"
>
SELECT
p.SAL_MST_NAME as name ,-- 姓名
p.SAL_MST_ID_TYPE as titleCode,-- 职称code
p.SAL_MST_OFFICIAL_TITLE as titleName,-- 职称名称
p.SAL_MST_MOBILE as mobileNo,
count(m.MON025_002) as count,-- 保单id
sum(m.MON025_401) as fyp,-- 保费
sum(policy.INS001_FYCTOTAL) as fyc -- 应发佣金
FROM sal001 p INNER JOIN MON025 m on m.MON025_007 = p.SAL_MST_ID and m.MON025_109 IN (1,2,3) AND m.MON025_303 = 1 AND m.mon025_108 = 'S01'-- 业务员id
inner JOIN ins001 policy on m.MON025_002 = policy.INS_MST_ID -- 保单id
WHERE p.FK_SPC_DIV_ID = #{subordinateIdForEGolden,jdbcType=VARCHAR}
<choose>
<when
test=
"time == 1"
>
and DATE_FORMAT(policy.INS_MST_ACCEPT_DATE, '%Y%m' ) = DATE_FORMAT( CURDATE( ) , '%Y%m' )
</when>
<when
test=
"time == 3"
>
and QUARTER(policy.INS_MST_ACCEPT_DATE) = QUARTER(NOW()) AND year(policy.INS_MST_ACCEPT_DATE)=year(now())
</when>
<otherwise>
and YEAR(policy.INS_MST_ACCEPT_DATE) = YEAR(now())
</otherwise>
</choose>
group by p.SAL_MST_ID;
</select>
</mapper>
\ No newline at end of file
yd-api/src/main/resources/mapper/marketing/MktLeadsGoalsMapper.xml
View file @
2961d4fb
...
...
@@ -327,4 +327,13 @@
and subordinate_system_id = #{subordinateSystemId,jdbcType=BIGINT}
and is_active = 1
</select>
<select
id=
"findByTypeAndTimeUnitAndPractitionerId"
resultMap=
"BaseResultMap"
>
select
<include
refid=
"Base_Column_List"
/>
from ag_mkt_leads_goals
where goals_type = #{goalsType,jdbcType=INTEGER}
and statistic_time_unit = #{statisticTimeUnit,jdbcType=INTEGER}
and practitioner_id = #{practitionerId,jdbcType=BIGINT}
and is_active = 1
</select>
</mapper>
\ No newline at end of file
yd-api/src/main/resources/mapper/meta/MdDropOptionsMapper.xml
View file @
2961d4fb
...
...
@@ -242,4 +242,16 @@
from ag_md_drop_master m left join ag_md_drop_options o on m.id = o.drop_master_id and o.is_active = 1 and o.drop_option_code = #{optionsCode,jdbcType=VARCHAR}
where m.scenario_code = #{masterCode,jdbcType=BIGINT}
</select>
<select
id=
"findByMasterIdsE"
resultType=
"com.yd.dal.entity.meta.OptionsEGolden"
>
select
t.DRP_OPT_ID as optId,
t.FK_DRP_MST_ID as mstId,
t.DRP_OPT_NAME as optName,
t.DRP_OPT_ATTR as optAttr,
t.DRP_OPT_ORDER as optOrder
from drp002 t where t.FK_DRP_MST_ID in
<foreach
collection=
"materIds"
index=
"index"
item=
"item"
open=
"("
separator=
","
close=
")"
>
#{item}
</foreach>
</select>
</mapper>
\ No newline at end of file
yd-api/src/main/resources/mapper/order/PoOrderMapper.xml
View file @
2961d4fb
...
...
@@ -964,8 +964,126 @@
#{item}
</foreach>
</if>
</select>
<select
id=
"findPolicyInfoByCustomerId"
resultType=
"com.yd.dal.entity.order.CustomerPolicyInfo"
>
SELECT
o.id as orderId,
o.order_no as orderNo ,
o.policy_no as policyNo ,
p.name as holderName,
o.destination as destination,
date_format(o.order_date, '%Y-%m-%d %H:%i:%s') as orderDate,
date_format(o.effective_start_date, '%Y-%m-%d %H:%i:%s') as startDate,
date_format(o.effective_end_date, '%Y-%m-%d %H:%i:%s') as endDate,
f.referral_amount as referralAmount,
f.order_price as orderPrice,
o.plan_id as planId,
o.product_id as productId
FROM ag_acl_customer_fortune f INNER JOIN ag_po_order o ON f.order_id = o.id and o.status = 3 and o.order_price > 0 and o.insurer_id != 888
inner JOIN ag_acl_policyholder p ON o.id = p.order_id and p.type = 2
WHERE f.customer_id = #{customerId,jdbcType=BIGINT}
<choose>
<when
test=
"time == 1"
>
and DATE_FORMAT(f.order_date, '%Y%m' ) = DATE_FORMAT( CURDATE( ) , '%Y%m' )
</when>
<when
test=
"time == 3"
>
and QUARTER(f.order_date) = QUARTER(NOW()) AND year(f.order_date)=year(now())
</when>
<when
test=
"time == 2"
>
and YEAR(f.order_date) = YEAR(now())
</when>
<otherwise>
</otherwise>
</choose>
</select>
<select
id=
"findPolicyInfoByMobileNoE"
resultType=
"com.yd.dal.entity.order.CustomerPolicyInfo"
>
SELECT
policy.INS_MST_ID as orderNo ,
policy.INS_MST_POLICY_NUM as policyNo ,
c.CUS_MST_NAME as holderName,
date_format(policy.INS_MST_ACCEPT_DATE, '%Y-%m-%d %H:%i:%s') as orderDate,
date_format(policy.INS_MST_EFFECT_DATE, '%Y-%m-%d %H:%i:%s') as startDate,
date_format(policy.INS_MST_INVALID_DATE, '%Y-%m-%d %H:%i:%s') as endDate,
sum(m.MON025_405) as referralAmount,
sum(m.MON025_401) as orderPrice,
m.MON025_004 as productName
FROM sal001 p INNER JOIN MON025 m on m.MON025_007 = p.SAL_MST_ID AND m.MON025_303 = 1 AND m.mon025_108 = 'S01'
inner JOIN ins001 policy on m.MON025_002 = policy.INS_MST_ID -- 保单id
inner join cus001 c on policy.FK_CUS_PRO_ID = c.CUS_MST_ID
WHERE p.SAL_MST_MOBILE like concat(concat('%',#{mobileNo,jdbcType=VARCHAR}),'%')
<choose>
<when
test=
"time == 1"
>
and DATE_FORMAT(policy.INS_MST_ACCEPT_DATE, '%Y%m' ) = DATE_FORMAT( CURDATE( ) , '%Y%m' )
</when>
<when
test=
"time == 3"
>
and QUARTER(policy.INS_MST_ACCEPT_DATE) = QUARTER(NOW()) AND year(policy.INS_MST_ACCEPT_DATE)=year(now())
</when>
<when
test=
"time == 3"
>
and YEAR(policy.INS_MST_ACCEPT_DATE) = YEAR(now())
</when>
<otherwise>
</otherwise>
</choose>
group by policy.ins_mst_id
</select>
<select
id=
"findOrderNoByPolicyNo"
resultType=
"java.lang.String"
>
select
INS_MST_ID
from ins001
where INS_MST_POLICY_NUM = #{policyNo,jdbcType=VARCHAR};
</select>
<select
id=
"findPolicyDetailsInfoByOrderNoE"
resultType=
"com.yd.dal.entity.order.PolicyDetailInfoE"
>
SELECT
policy.INS_MST_ID as orderNo , -- 订单号
policy.INS_MST_POLICY_NUM as policyNo , -- 保单号
policy.INS_MST_STATUS as policyStatus, -- 保单状态
date_format(policy.INS_MST_ACCEPT_DATE, '%Y-%m-%d %H:%i:%s') as orderDate, -- 下单日期
date_format(policy.INS_MST_EFFECT_DATE, '%Y-%m-%d %H:%i:%s') as startDate, -- 保险起期
date_format(policy.INS_MST_INVALID_DATE, '%Y-%m-%d %H:%i:%s') as endDate, -- 保险止期
product.PRD_MST_ID as productId , -- 产品编号
product.PRD_MST_INS_CODE as productCode , -- 产品code
product.PRD_MST_PRO_NAME as productName , -- 产品名字
insurer.PRD_SUP_ID as insurerId , -- 保险公司编号
insurer.PRD_SUP_NAME as insurerName , -- 保险公司名称
holder.CUS_MST_NAME as holderName, -- 投保人姓名
holder.CUS_MST_POSTTYPE as holderIdNoType, -- 投保人证件类型
holder.CUS_MST_ID as holderId, -- 投保人编码
holder.CUS_MST_ID_NUM as holderIdNo, -- 投保人编码
holder.CUS_MST_SEX as holderSex, -- 投保人性别
date_format(holder.CUS_MST_BIRTHDAY, '%Y-%m-%d') as holderBirthday, -- 投保人出生年月
holder.CUS_MST_CELL_NUM as holderMobileNo, -- 投保人手机号码
insured.CUS_MST_NAME as insuredName, -- 被保人姓名
insured.CUS_MST_ID as insuredId, -- 被保人编码
insured.CUS_MST_POSTTYPE as insuredIdNoType, -- 被保人证件类型
insured.CUS_MST_ID_NUM as insuredIdNo, -- 被保人编码
insured.CUS_MST_SEX as insuredSex, -- 被保人性别
date_format(insured.CUS_MST_BIRTHDAY, '%Y-%m-%d') as insuredBirthday, -- 被保人出生年月
insured.CUS_MST_CELL_NUM as insuredMobileNo, -- 被保人手机号码
m.MON025_405 as commission, -- 佣金
m.MON025_404 as commissionRate, -- 佣金率
m.MON025_004 as productId, -- 产品ID
m.MON025_401 as premium, -- 保费
m.MON025_101 as policyType, -- 保单类型
m.MON025_102 as payFrequency, -- 缴费频率
m.MON025_109 as payCommissionStatus, -- 发佣状态
m.mon025_108 as commissionType -- 佣金项目代码
FROM ins001 policy INNER JOIN MON025 m on m.MON025_002 = policy.INS_MST_ID AND m.MON025_303 = 1 AND m.mon025_108 = 'S01'
inner join cus001 holder on policy.FK_CUS_PRO_ID = holder.CUS_MST_ID
inner join cus001 insured on policy.FK_CUS_PRO_ID = insured.CUS_MST_ID
inner join prd001 product on m.MON025_004 = product.PRD_MST_ID
inner join prd004 insurer on product.FK_PRD_SUP_ID = insurer.PRD_SUP_ID
WHERE policy.INS_MST_ID = #{orderNo,jdbcType=VARCHAR};
</select>
<select
id=
"findPolicyFactorByOrderNosE"
resultType=
"com.yd.dal.entity.order.PolicyFactorInfoE"
>
SELECT policy2.FK_INS_MST_ID as orderNo, -- 保单id
policy2.FK_PRD_MST_ID as productId, -- 产品ID
policy2.INS_IND_RELATIONSHIP as relationship,-- 与被保人关系
policy2.INS_IND_INSURED_AMOUNT as insuredAmount, -- 保费
policy2.INS_IND_AMOUNT_UNIT as amountUnit, -- 保费单位
policy2.INS_IND_PERIOD as period -- 缴费年限
from ins002 policy2 where policy2.FK_INS_MST_ID in
<foreach
collection=
"orderNoList"
index=
"index"
item=
"item"
open=
"("
separator=
","
close=
")"
>
#{item}
</foreach>
</select>
</mapper>
\ No newline at end of file
yd-api/src/main/resources/mapper/product/ProductMapper.xml
0 → 100644
View file @
2961d4fb
<?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.dal.mapper.product.ProductMapper"
>
<resultMap
id=
"BaseResultMap"
type=
"com.yd.dal.entity.product.Product"
>
<id
column=
"id"
jdbcType=
"BIGINT"
property=
"id"
/>
<result
column=
"insurer_id"
jdbcType=
"BIGINT"
property=
"insurerId"
/>
<result
column=
"insurer_name"
jdbcType=
"VARCHAR"
property=
"insurerName"
/>
<result
column=
"insurer_branch_id"
jdbcType=
"BIGINT"
property=
"insurerBranchId"
/>
<result
column=
"product_category_id"
jdbcType=
"BIGINT"
property=
"productCategoryId"
/>
<result
column=
"no"
jdbcType=
"VARCHAR"
property=
"no"
/>
<result
column=
"name"
jdbcType=
"VARCHAR"
property=
"name"
/>
<result
column=
"name_en"
jdbcType=
"VARCHAR"
property=
"nameEn"
/>
<result
column=
"description"
jdbcType=
"VARCHAR"
property=
"description"
/>
<result
column=
"effective_start_date"
jdbcType=
"DATE"
property=
"effectiveStartDate"
/>
<result
column=
"effective_end_date"
jdbcType=
"DATE"
property=
"effectiveEndDate"
/>
<result
column=
"sale_price"
jdbcType=
"DECIMAL"
property=
"salePrice"
/>
<result
column=
"is_active"
jdbcType=
"INTEGER"
property=
"isActive"
/>
<result
column=
"policy_eff_count"
jdbcType=
"INTEGER"
property=
"policyEffCount"
/>
<result
column=
"policy_eff_count_unit"
jdbcType=
"VARCHAR"
property=
"policyEffCountUnit"
/>
<result
column=
"min_cover_term"
jdbcType=
"INTEGER"
property=
"minCoverTerm"
/>
<result
column=
"min_cover_term_unit"
jdbcType=
"VARCHAR"
property=
"minCoverTermUnit"
/>
<result
column=
"hesitate_peroid"
jdbcType=
"INTEGER"
property=
"hesitatePeroid"
/>
<result
column=
"ui_display_unit"
jdbcType=
"VARCHAR"
property=
"uiDisplayUnit"
/>
<result
column=
"article_url"
jdbcType=
"VARCHAR"
property=
"articleUrl"
/>
<result
column=
"is_pay_to_yd"
jdbcType=
"INTEGER"
property=
"isPayToYd"
/>
<result
column=
"created_at"
jdbcType=
"TIMESTAMP"
property=
"createdAt"
/>
<result
column=
"created_by"
jdbcType=
"BIGINT"
property=
"createdBy"
/>
<result
column=
"updated_at"
jdbcType=
"TIMESTAMP"
property=
"updatedAt"
/>
<result
column=
"updated_by"
jdbcType=
"BIGINT"
property=
"updatedBy"
/>
</resultMap>
<sql
id=
"Base_Column_List"
>
id, insurer_id, insurer_name, insurer_branch_id, product_category_id, `no`, `name`,
name_en, description, effective_start_date, effective_end_date, sale_price, is_active,
policy_eff_count, policy_eff_count_unit, min_cover_term, min_cover_term_unit, hesitate_peroid,
ui_display_unit, article_url, is_pay_to_yd, created_at, created_by, updated_at, updated_by
</sql>
<select
id=
"selectByPrimaryKey"
parameterType=
"java.lang.Long"
resultMap=
"BaseResultMap"
>
select
<include
refid=
"Base_Column_List"
/>
from ag_product
where id = #{id,jdbcType=BIGINT}
</select>
<delete
id=
"deleteByPrimaryKey"
parameterType=
"java.lang.Long"
>
delete from ag_product
where id = #{id,jdbcType=BIGINT}
</delete>
<insert
id=
"insert"
keyColumn=
"id"
keyProperty=
"id"
parameterType=
"com.yd.dal.entity.product.Product"
useGeneratedKeys=
"true"
>
insert into ag_product (insurer_id, insurer_name, insurer_branch_id,
product_category_id, `no`, `name`,
name_en, description, effective_start_date,
effective_end_date, sale_price, is_active,
policy_eff_count, policy_eff_count_unit, min_cover_term,
min_cover_term_unit, hesitate_peroid, ui_display_unit,
article_url, is_pay_to_yd, created_at,
created_by, updated_at, updated_by
)
values (#{insurerId,jdbcType=BIGINT}, #{insurerName,jdbcType=VARCHAR}, #{insurerBranchId,jdbcType=BIGINT},
#{productCategoryId,jdbcType=BIGINT}, #{no,jdbcType=VARCHAR}, #{name,jdbcType=VARCHAR},
#{nameEn,jdbcType=VARCHAR}, #{description,jdbcType=VARCHAR}, #{effectiveStartDate,jdbcType=DATE},
#{effectiveEndDate,jdbcType=DATE}, #{salePrice,jdbcType=DECIMAL}, #{isActive,jdbcType=INTEGER},
#{policyEffCount,jdbcType=INTEGER}, #{policyEffCountUnit,jdbcType=VARCHAR}, #{minCoverTerm,jdbcType=INTEGER},
#{minCoverTermUnit,jdbcType=VARCHAR}, #{hesitatePeroid,jdbcType=INTEGER}, #{uiDisplayUnit,jdbcType=VARCHAR},
#{articleUrl,jdbcType=VARCHAR}, #{isPayToYd,jdbcType=INTEGER}, #{createdAt,jdbcType=TIMESTAMP},
#{createdBy,jdbcType=BIGINT}, #{updatedAt,jdbcType=TIMESTAMP}, #{updatedBy,jdbcType=BIGINT}
)
</insert>
<insert
id=
"insertSelective"
keyColumn=
"id"
keyProperty=
"id"
parameterType=
"com.yd.dal.entity.product.Product"
useGeneratedKeys=
"true"
>
insert into ag_product
<trim
prefix=
"("
suffix=
")"
suffixOverrides=
","
>
<if
test=
"insurerId != null"
>
insurer_id,
</if>
<if
test=
"insurerName != null"
>
insurer_name,
</if>
<if
test=
"insurerBranchId != null"
>
insurer_branch_id,
</if>
<if
test=
"productCategoryId != null"
>
product_category_id,
</if>
<if
test=
"no != null"
>
`no`,
</if>
<if
test=
"name != null"
>
`name`,
</if>
<if
test=
"nameEn != null"
>
name_en,
</if>
<if
test=
"description != null"
>
description,
</if>
<if
test=
"effectiveStartDate != null"
>
effective_start_date,
</if>
<if
test=
"effectiveEndDate != null"
>
effective_end_date,
</if>
<if
test=
"salePrice != null"
>
sale_price,
</if>
<if
test=
"isActive != null"
>
is_active,
</if>
<if
test=
"policyEffCount != null"
>
policy_eff_count,
</if>
<if
test=
"policyEffCountUnit != null"
>
policy_eff_count_unit,
</if>
<if
test=
"minCoverTerm != null"
>
min_cover_term,
</if>
<if
test=
"minCoverTermUnit != null"
>
min_cover_term_unit,
</if>
<if
test=
"hesitatePeroid != null"
>
hesitate_peroid,
</if>
<if
test=
"uiDisplayUnit != null"
>
ui_display_unit,
</if>
<if
test=
"articleUrl != null"
>
article_url,
</if>
<if
test=
"isPayToYd != null"
>
is_pay_to_yd,
</if>
<if
test=
"createdAt != null"
>
created_at,
</if>
<if
test=
"createdBy != null"
>
created_by,
</if>
<if
test=
"updatedAt != null"
>
updated_at,
</if>
<if
test=
"updatedBy != null"
>
updated_by,
</if>
</trim>
<trim
prefix=
"values ("
suffix=
")"
suffixOverrides=
","
>
<if
test=
"insurerId != null"
>
#{insurerId,jdbcType=BIGINT},
</if>
<if
test=
"insurerName != null"
>
#{insurerName,jdbcType=VARCHAR},
</if>
<if
test=
"insurerBranchId != null"
>
#{insurerBranchId,jdbcType=BIGINT},
</if>
<if
test=
"productCategoryId != null"
>
#{productCategoryId,jdbcType=BIGINT},
</if>
<if
test=
"no != null"
>
#{no,jdbcType=VARCHAR},
</if>
<if
test=
"name != null"
>
#{name,jdbcType=VARCHAR},
</if>
<if
test=
"nameEn != null"
>
#{nameEn,jdbcType=VARCHAR},
</if>
<if
test=
"description != null"
>
#{description,jdbcType=VARCHAR},
</if>
<if
test=
"effectiveStartDate != null"
>
#{effectiveStartDate,jdbcType=DATE},
</if>
<if
test=
"effectiveEndDate != null"
>
#{effectiveEndDate,jdbcType=DATE},
</if>
<if
test=
"salePrice != null"
>
#{salePrice,jdbcType=DECIMAL},
</if>
<if
test=
"isActive != null"
>
#{isActive,jdbcType=INTEGER},
</if>
<if
test=
"policyEffCount != null"
>
#{policyEffCount,jdbcType=INTEGER},
</if>
<if
test=
"policyEffCountUnit != null"
>
#{policyEffCountUnit,jdbcType=VARCHAR},
</if>
<if
test=
"minCoverTerm != null"
>
#{minCoverTerm,jdbcType=INTEGER},
</if>
<if
test=
"minCoverTermUnit != null"
>
#{minCoverTermUnit,jdbcType=VARCHAR},
</if>
<if
test=
"hesitatePeroid != null"
>
#{hesitatePeroid,jdbcType=INTEGER},
</if>
<if
test=
"uiDisplayUnit != null"
>
#{uiDisplayUnit,jdbcType=VARCHAR},
</if>
<if
test=
"articleUrl != null"
>
#{articleUrl,jdbcType=VARCHAR},
</if>
<if
test=
"isPayToYd != null"
>
#{isPayToYd,jdbcType=INTEGER},
</if>
<if
test=
"createdAt != null"
>
#{createdAt,jdbcType=TIMESTAMP},
</if>
<if
test=
"createdBy != null"
>
#{createdBy,jdbcType=BIGINT},
</if>
<if
test=
"updatedAt != null"
>
#{updatedAt,jdbcType=TIMESTAMP},
</if>
<if
test=
"updatedBy != null"
>
#{updatedBy,jdbcType=BIGINT},
</if>
</trim>
</insert>
<update
id=
"updateByPrimaryKeySelective"
parameterType=
"com.yd.dal.entity.product.Product"
>
update ag_product
<set>
<if
test=
"insurerId != null"
>
insurer_id = #{insurerId,jdbcType=BIGINT},
</if>
<if
test=
"insurerName != null"
>
insurer_name = #{insurerName,jdbcType=VARCHAR},
</if>
<if
test=
"insurerBranchId != null"
>
insurer_branch_id = #{insurerBranchId,jdbcType=BIGINT},
</if>
<if
test=
"productCategoryId != null"
>
product_category_id = #{productCategoryId,jdbcType=BIGINT},
</if>
<if
test=
"no != null"
>
`no` = #{no,jdbcType=VARCHAR},
</if>
<if
test=
"name != null"
>
`name` = #{name,jdbcType=VARCHAR},
</if>
<if
test=
"nameEn != null"
>
name_en = #{nameEn,jdbcType=VARCHAR},
</if>
<if
test=
"description != null"
>
description = #{description,jdbcType=VARCHAR},
</if>
<if
test=
"effectiveStartDate != null"
>
effective_start_date = #{effectiveStartDate,jdbcType=DATE},
</if>
<if
test=
"effectiveEndDate != null"
>
effective_end_date = #{effectiveEndDate,jdbcType=DATE},
</if>
<if
test=
"salePrice != null"
>
sale_price = #{salePrice,jdbcType=DECIMAL},
</if>
<if
test=
"isActive != null"
>
is_active = #{isActive,jdbcType=INTEGER},
</if>
<if
test=
"policyEffCount != null"
>
policy_eff_count = #{policyEffCount,jdbcType=INTEGER},
</if>
<if
test=
"policyEffCountUnit != null"
>
policy_eff_count_unit = #{policyEffCountUnit,jdbcType=VARCHAR},
</if>
<if
test=
"minCoverTerm != null"
>
min_cover_term = #{minCoverTerm,jdbcType=INTEGER},
</if>
<if
test=
"minCoverTermUnit != null"
>
min_cover_term_unit = #{minCoverTermUnit,jdbcType=VARCHAR},
</if>
<if
test=
"hesitatePeroid != null"
>
hesitate_peroid = #{hesitatePeroid,jdbcType=INTEGER},
</if>
<if
test=
"uiDisplayUnit != null"
>
ui_display_unit = #{uiDisplayUnit,jdbcType=VARCHAR},
</if>
<if
test=
"articleUrl != null"
>
article_url = #{articleUrl,jdbcType=VARCHAR},
</if>
<if
test=
"isPayToYd != null"
>
is_pay_to_yd = #{isPayToYd,jdbcType=INTEGER},
</if>
<if
test=
"createdAt != null"
>
created_at = #{createdAt,jdbcType=TIMESTAMP},
</if>
<if
test=
"createdBy != null"
>
created_by = #{createdBy,jdbcType=BIGINT},
</if>
<if
test=
"updatedAt != null"
>
updated_at = #{updatedAt,jdbcType=TIMESTAMP},
</if>
<if
test=
"updatedBy != null"
>
updated_by = #{updatedBy,jdbcType=BIGINT},
</if>
</set>
where id = #{id,jdbcType=BIGINT}
</update>
<update
id=
"updateByPrimaryKey"
parameterType=
"com.yd.dal.entity.product.Product"
>
update ag_product
set insurer_id = #{insurerId,jdbcType=BIGINT},
insurer_name = #{insurerName,jdbcType=VARCHAR},
insurer_branch_id = #{insurerBranchId,jdbcType=BIGINT},
product_category_id = #{productCategoryId,jdbcType=BIGINT},
`no` = #{no,jdbcType=VARCHAR},
`name` = #{name,jdbcType=VARCHAR},
name_en = #{nameEn,jdbcType=VARCHAR},
description = #{description,jdbcType=VARCHAR},
effective_start_date = #{effectiveStartDate,jdbcType=DATE},
effective_end_date = #{effectiveEndDate,jdbcType=DATE},
sale_price = #{salePrice,jdbcType=DECIMAL},
is_active = #{isActive,jdbcType=INTEGER},
policy_eff_count = #{policyEffCount,jdbcType=INTEGER},
policy_eff_count_unit = #{policyEffCountUnit,jdbcType=VARCHAR},
min_cover_term = #{minCoverTerm,jdbcType=INTEGER},
min_cover_term_unit = #{minCoverTermUnit,jdbcType=VARCHAR},
hesitate_peroid = #{hesitatePeroid,jdbcType=INTEGER},
ui_display_unit = #{uiDisplayUnit,jdbcType=VARCHAR},
article_url = #{articleUrl,jdbcType=VARCHAR},
is_pay_to_yd = #{isPayToYd,jdbcType=INTEGER},
created_at = #{createdAt,jdbcType=TIMESTAMP},
created_by = #{createdBy,jdbcType=BIGINT},
updated_at = #{updatedAt,jdbcType=TIMESTAMP},
updated_by = #{updatedBy,jdbcType=BIGINT}
where id = #{id,jdbcType=BIGINT}
</update>
<select
id=
"findAll"
resultMap=
"BaseResultMap"
>
select
<include
refid=
"Base_Column_List"
/>
from ag_product
where is_active is not null
</select>
<select
id=
"findAllE"
resultType=
"com.yd.dal.entity.product.ProductE"
>
select
t.prd_mst_id as productId,
t.PRD_MST_PRO_NAME as productName
from prd001 t
</select>
</mapper>
\ No newline at end of file
yd-api/src/main/resources/mapper/product/ProductPlanMapper.xml
0 → 100644
View file @
2961d4fb
<?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.dal.mapper.product.ProductPlanMapper"
>
<resultMap
id=
"BaseResultMap"
type=
"com.yd.dal.entity.product.ProductPlan"
>
<id
column=
"id"
jdbcType=
"BIGINT"
property=
"id"
/>
<result
column=
"insurer_id"
jdbcType=
"BIGINT"
property=
"insurerId"
/>
<result
column=
"product_id"
jdbcType=
"BIGINT"
property=
"productId"
/>
<result
column=
"plan_code"
jdbcType=
"VARCHAR"
property=
"planCode"
/>
<result
column=
"contract_id"
jdbcType=
"VARCHAR"
property=
"contractId"
/>
<result
column=
"name"
jdbcType=
"VARCHAR"
property=
"name"
/>
<result
column=
"name_sub"
jdbcType=
"VARCHAR"
property=
"nameSub"
/>
<result
column=
"name_en"
jdbcType=
"VARCHAR"
property=
"nameEn"
/>
<result
column=
"level"
jdbcType=
"INTEGER"
property=
"level"
/>
<result
column=
"commision_rate"
jdbcType=
"DECIMAL"
property=
"commisionRate"
/>
<result
column=
"referral_rate"
jdbcType=
"DECIMAL"
property=
"referralRate"
/>
<result
column=
"sale_price"
jdbcType=
"DECIMAL"
property=
"salePrice"
/>
<result
column=
"effective_start_date"
jdbcType=
"DATE"
property=
"effectiveStartDate"
/>
<result
column=
"effective_end_date"
jdbcType=
"DATE"
property=
"effectiveEndDate"
/>
<result
column=
"is_active"
jdbcType=
"INTEGER"
property=
"isActive"
/>
<result
column=
"is_global"
jdbcType=
"INTEGER"
property=
"isGlobal"
/>
<result
column=
"continent_id"
jdbcType=
"BIGINT"
property=
"continentId"
/>
<result
column=
"country_id"
jdbcType=
"BIGINT"
property=
"countryId"
/>
<result
column=
"region_id"
jdbcType=
"BIGINT"
property=
"regionId"
/>
<result
column=
"is_popular"
jdbcType=
"INTEGER"
property=
"isPopular"
/>
<result
column=
"sales_count"
jdbcType=
"INTEGER"
property=
"salesCount"
/>
<result
column=
"version"
jdbcType=
"INTEGER"
property=
"version"
/>
<result
column=
"is_social_insured"
jdbcType=
"INTEGER"
property=
"isSocialInsured"
/>
<result
column=
"app_gender"
jdbcType=
"INTEGER"
property=
"appGender"
/>
<result
column=
"created_at"
jdbcType=
"TIMESTAMP"
property=
"createdAt"
/>
<result
column=
"created_by"
jdbcType=
"BIGINT"
property=
"createdBy"
/>
<result
column=
"updated_at"
jdbcType=
"TIMESTAMP"
property=
"updatedAt"
/>
<result
column=
"updated_by"
jdbcType=
"BIGINT"
property=
"updatedBy"
/>
</resultMap>
<sql
id=
"Base_Column_List"
>
id, insurer_id, product_id, plan_code, contract_id, `name`, name_sub, name_en, `level`,
commision_rate, referral_rate, sale_price, effective_start_date, effective_end_date,
is_active, is_global, continent_id, country_id, region_id, is_popular, sales_count,
version, is_social_insured, app_gender, created_at, created_by, updated_at, updated_by
</sql>
<select
id=
"selectByPrimaryKey"
parameterType=
"java.lang.Long"
resultMap=
"BaseResultMap"
>
select
<include
refid=
"Base_Column_List"
/>
from ag_product_plan
where id = #{id,jdbcType=BIGINT}
</select>
<delete
id=
"deleteByPrimaryKey"
parameterType=
"java.lang.Long"
>
delete from ag_product_plan
where id = #{id,jdbcType=BIGINT}
</delete>
<insert
id=
"insert"
keyColumn=
"id"
keyProperty=
"id"
parameterType=
"com.yd.dal.entity.product.ProductPlan"
useGeneratedKeys=
"true"
>
insert into ag_product_plan (insurer_id, product_id, plan_code,
contract_id, `name`, name_sub,
name_en, `level`, commision_rate,
referral_rate, sale_price, effective_start_date,
effective_end_date, is_active, is_global,
continent_id, country_id, region_id,
is_popular, sales_count, version,
is_social_insured, app_gender, created_at,
created_by, updated_at, updated_by
)
values (#{insurerId,jdbcType=BIGINT}, #{productId,jdbcType=BIGINT}, #{planCode,jdbcType=VARCHAR},
#{contractId,jdbcType=VARCHAR}, #{name,jdbcType=VARCHAR}, #{nameSub,jdbcType=VARCHAR},
#{nameEn,jdbcType=VARCHAR}, #{level,jdbcType=INTEGER}, #{commisionRate,jdbcType=DECIMAL},
#{referralRate,jdbcType=DECIMAL}, #{salePrice,jdbcType=DECIMAL}, #{effectiveStartDate,jdbcType=DATE},
#{effectiveEndDate,jdbcType=DATE}, #{isActive,jdbcType=INTEGER}, #{isGlobal,jdbcType=INTEGER},
#{continentId,jdbcType=BIGINT}, #{countryId,jdbcType=BIGINT}, #{regionId,jdbcType=BIGINT},
#{isPopular,jdbcType=INTEGER}, #{salesCount,jdbcType=INTEGER}, #{version,jdbcType=INTEGER},
#{isSocialInsured,jdbcType=INTEGER}, #{appGender,jdbcType=INTEGER}, #{createdAt,jdbcType=TIMESTAMP},
#{createdBy,jdbcType=BIGINT}, #{updatedAt,jdbcType=TIMESTAMP}, #{updatedBy,jdbcType=BIGINT}
)
</insert>
<insert
id=
"insertSelective"
keyColumn=
"id"
keyProperty=
"id"
parameterType=
"com.yd.dal.entity.product.ProductPlan"
useGeneratedKeys=
"true"
>
insert into ag_product_plan
<trim
prefix=
"("
suffix=
")"
suffixOverrides=
","
>
<if
test=
"insurerId != null"
>
insurer_id,
</if>
<if
test=
"productId != null"
>
product_id,
</if>
<if
test=
"planCode != null"
>
plan_code,
</if>
<if
test=
"contractId != null"
>
contract_id,
</if>
<if
test=
"name != null"
>
`name`,
</if>
<if
test=
"nameSub != null"
>
name_sub,
</if>
<if
test=
"nameEn != null"
>
name_en,
</if>
<if
test=
"level != null"
>
`level`,
</if>
<if
test=
"commisionRate != null"
>
commision_rate,
</if>
<if
test=
"referralRate != null"
>
referral_rate,
</if>
<if
test=
"salePrice != null"
>
sale_price,
</if>
<if
test=
"effectiveStartDate != null"
>
effective_start_date,
</if>
<if
test=
"effectiveEndDate != null"
>
effective_end_date,
</if>
<if
test=
"isActive != null"
>
is_active,
</if>
<if
test=
"isGlobal != null"
>
is_global,
</if>
<if
test=
"continentId != null"
>
continent_id,
</if>
<if
test=
"countryId != null"
>
country_id,
</if>
<if
test=
"regionId != null"
>
region_id,
</if>
<if
test=
"isPopular != null"
>
is_popular,
</if>
<if
test=
"salesCount != null"
>
sales_count,
</if>
<if
test=
"version != null"
>
version,
</if>
<if
test=
"isSocialInsured != null"
>
is_social_insured,
</if>
<if
test=
"appGender != null"
>
app_gender,
</if>
<if
test=
"createdAt != null"
>
created_at,
</if>
<if
test=
"createdBy != null"
>
created_by,
</if>
<if
test=
"updatedAt != null"
>
updated_at,
</if>
<if
test=
"updatedBy != null"
>
updated_by,
</if>
</trim>
<trim
prefix=
"values ("
suffix=
")"
suffixOverrides=
","
>
<if
test=
"insurerId != null"
>
#{insurerId,jdbcType=BIGINT},
</if>
<if
test=
"productId != null"
>
#{productId,jdbcType=BIGINT},
</if>
<if
test=
"planCode != null"
>
#{planCode,jdbcType=VARCHAR},
</if>
<if
test=
"contractId != null"
>
#{contractId,jdbcType=VARCHAR},
</if>
<if
test=
"name != null"
>
#{name,jdbcType=VARCHAR},
</if>
<if
test=
"nameSub != null"
>
#{nameSub,jdbcType=VARCHAR},
</if>
<if
test=
"nameEn != null"
>
#{nameEn,jdbcType=VARCHAR},
</if>
<if
test=
"level != null"
>
#{level,jdbcType=INTEGER},
</if>
<if
test=
"commisionRate != null"
>
#{commisionRate,jdbcType=DECIMAL},
</if>
<if
test=
"referralRate != null"
>
#{referralRate,jdbcType=DECIMAL},
</if>
<if
test=
"salePrice != null"
>
#{salePrice,jdbcType=DECIMAL},
</if>
<if
test=
"effectiveStartDate != null"
>
#{effectiveStartDate,jdbcType=DATE},
</if>
<if
test=
"effectiveEndDate != null"
>
#{effectiveEndDate,jdbcType=DATE},
</if>
<if
test=
"isActive != null"
>
#{isActive,jdbcType=INTEGER},
</if>
<if
test=
"isGlobal != null"
>
#{isGlobal,jdbcType=INTEGER},
</if>
<if
test=
"continentId != null"
>
#{continentId,jdbcType=BIGINT},
</if>
<if
test=
"countryId != null"
>
#{countryId,jdbcType=BIGINT},
</if>
<if
test=
"regionId != null"
>
#{regionId,jdbcType=BIGINT},
</if>
<if
test=
"isPopular != null"
>
#{isPopular,jdbcType=INTEGER},
</if>
<if
test=
"salesCount != null"
>
#{salesCount,jdbcType=INTEGER},
</if>
<if
test=
"version != null"
>
#{version,jdbcType=INTEGER},
</if>
<if
test=
"isSocialInsured != null"
>
#{isSocialInsured,jdbcType=INTEGER},
</if>
<if
test=
"appGender != null"
>
#{appGender,jdbcType=INTEGER},
</if>
<if
test=
"createdAt != null"
>
#{createdAt,jdbcType=TIMESTAMP},
</if>
<if
test=
"createdBy != null"
>
#{createdBy,jdbcType=BIGINT},
</if>
<if
test=
"updatedAt != null"
>
#{updatedAt,jdbcType=TIMESTAMP},
</if>
<if
test=
"updatedBy != null"
>
#{updatedBy,jdbcType=BIGINT},
</if>
</trim>
</insert>
<update
id=
"updateByPrimaryKeySelective"
parameterType=
"com.yd.dal.entity.product.ProductPlan"
>
update ag_product_plan
<set>
<if
test=
"insurerId != null"
>
insurer_id = #{insurerId,jdbcType=BIGINT},
</if>
<if
test=
"productId != null"
>
product_id = #{productId,jdbcType=BIGINT},
</if>
<if
test=
"planCode != null"
>
plan_code = #{planCode,jdbcType=VARCHAR},
</if>
<if
test=
"contractId != null"
>
contract_id = #{contractId,jdbcType=VARCHAR},
</if>
<if
test=
"name != null"
>
`name` = #{name,jdbcType=VARCHAR},
</if>
<if
test=
"nameSub != null"
>
name_sub = #{nameSub,jdbcType=VARCHAR},
</if>
<if
test=
"nameEn != null"
>
name_en = #{nameEn,jdbcType=VARCHAR},
</if>
<if
test=
"level != null"
>
`level` = #{level,jdbcType=INTEGER},
</if>
<if
test=
"commisionRate != null"
>
commision_rate = #{commisionRate,jdbcType=DECIMAL},
</if>
<if
test=
"referralRate != null"
>
referral_rate = #{referralRate,jdbcType=DECIMAL},
</if>
<if
test=
"salePrice != null"
>
sale_price = #{salePrice,jdbcType=DECIMAL},
</if>
<if
test=
"effectiveStartDate != null"
>
effective_start_date = #{effectiveStartDate,jdbcType=DATE},
</if>
<if
test=
"effectiveEndDate != null"
>
effective_end_date = #{effectiveEndDate,jdbcType=DATE},
</if>
<if
test=
"isActive != null"
>
is_active = #{isActive,jdbcType=INTEGER},
</if>
<if
test=
"isGlobal != null"
>
is_global = #{isGlobal,jdbcType=INTEGER},
</if>
<if
test=
"continentId != null"
>
continent_id = #{continentId,jdbcType=BIGINT},
</if>
<if
test=
"countryId != null"
>
country_id = #{countryId,jdbcType=BIGINT},
</if>
<if
test=
"regionId != null"
>
region_id = #{regionId,jdbcType=BIGINT},
</if>
<if
test=
"isPopular != null"
>
is_popular = #{isPopular,jdbcType=INTEGER},
</if>
<if
test=
"salesCount != null"
>
sales_count = #{salesCount,jdbcType=INTEGER},
</if>
<if
test=
"version != null"
>
version = #{version,jdbcType=INTEGER},
</if>
<if
test=
"isSocialInsured != null"
>
is_social_insured = #{isSocialInsured,jdbcType=INTEGER},
</if>
<if
test=
"appGender != null"
>
app_gender = #{appGender,jdbcType=INTEGER},
</if>
<if
test=
"createdAt != null"
>
created_at = #{createdAt,jdbcType=TIMESTAMP},
</if>
<if
test=
"createdBy != null"
>
created_by = #{createdBy,jdbcType=BIGINT},
</if>
<if
test=
"updatedAt != null"
>
updated_at = #{updatedAt,jdbcType=TIMESTAMP},
</if>
<if
test=
"updatedBy != null"
>
updated_by = #{updatedBy,jdbcType=BIGINT},
</if>
</set>
where id = #{id,jdbcType=BIGINT}
</update>
<update
id=
"updateByPrimaryKey"
parameterType=
"com.yd.dal.entity.product.ProductPlan"
>
update ag_product_plan
set insurer_id = #{insurerId,jdbcType=BIGINT},
product_id = #{productId,jdbcType=BIGINT},
plan_code = #{planCode,jdbcType=VARCHAR},
contract_id = #{contractId,jdbcType=VARCHAR},
`name` = #{name,jdbcType=VARCHAR},
name_sub = #{nameSub,jdbcType=VARCHAR},
name_en = #{nameEn,jdbcType=VARCHAR},
`level` = #{level,jdbcType=INTEGER},
commision_rate = #{commisionRate,jdbcType=DECIMAL},
referral_rate = #{referralRate,jdbcType=DECIMAL},
sale_price = #{salePrice,jdbcType=DECIMAL},
effective_start_date = #{effectiveStartDate,jdbcType=DATE},
effective_end_date = #{effectiveEndDate,jdbcType=DATE},
is_active = #{isActive,jdbcType=INTEGER},
is_global = #{isGlobal,jdbcType=INTEGER},
continent_id = #{continentId,jdbcType=BIGINT},
country_id = #{countryId,jdbcType=BIGINT},
region_id = #{regionId,jdbcType=BIGINT},
is_popular = #{isPopular,jdbcType=INTEGER},
sales_count = #{salesCount,jdbcType=INTEGER},
version = #{version,jdbcType=INTEGER},
is_social_insured = #{isSocialInsured,jdbcType=INTEGER},
app_gender = #{appGender,jdbcType=INTEGER},
created_at = #{createdAt,jdbcType=TIMESTAMP},
created_by = #{createdBy,jdbcType=BIGINT},
updated_at = #{updatedAt,jdbcType=TIMESTAMP},
updated_by = #{updatedBy,jdbcType=BIGINT}
where id = #{id,jdbcType=BIGINT}
</update>
<select
id=
"findAll"
resultMap=
"BaseResultMap"
>
select
<include
refid=
"Base_Column_List"
/>
from ag_product_plan
where is_active is not null
</select>
</mapper>
\ No newline at end of file
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