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
b030474a
Commit
b030474a
authored
Jan 14, 2022
by
jianan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
【线上来佣比对】导出加组织体系
parent
c4e61645
Show whitespace changes
Inline
Side-by-side
Showing
14 changed files
with
522 additions
and
66 deletions
+522
-66
yd-api/src/main/java/com/yd/api/commission/service/impl/LifeCommissionServiceImpl.java
+99
-15
yd-api/src/main/java/com/yd/api/commission/vo/lifecommission/ComeCommissionVO.java
+348
-43
yd-api/src/main/java/com/yd/dal/entity/customer/AclInsurerBranch.java
+5
-2
yd-api/src/main/java/com/yd/dal/entity/customer/AclPractitioner.java
+4
-0
yd-api/src/main/java/com/yd/dal/mapper/customer/AclInsurerBranchMapper.java
+5
-1
yd-api/src/main/java/com/yd/dal/mapper/customer/AclPractitionerSubordinateSystemMapper.java
+2
-0
yd-api/src/main/java/com/yd/dal/service/customer/AclInsurerBranchDALService.java
+4
-0
yd-api/src/main/java/com/yd/dal/service/customer/AclPractitionerSubordinateSystemDALService.java
+1
-0
yd-api/src/main/java/com/yd/dal/service/customer/impl/AclInsurerBranchDALServiceImpl.java
+6
-0
yd-api/src/main/java/com/yd/dal/service/customer/impl/AclPractitionerSubordinateSystemDALServiceImpl.java
+5
-0
yd-api/src/main/java/com/yd/rmi/cache/SystemConfigService.java
+24
-4
yd-api/src/main/resources/mapper/customer/AclInsurerBranchMapper.xml
+9
-0
yd-api/src/main/resources/mapper/customer/AclPractitionerMapper.xml
+5
-1
yd-api/src/main/resources/mapper/customer/AclPractitionerSubordinateSystemMapper.xml
+5
-0
No files found.
yd-api/src/main/java/com/yd/api/commission/service/impl/LifeCommissionServiceImpl.java
View file @
b030474a
...
...
@@ -6,19 +6,22 @@ import com.github.pagehelper.PageInfo;
import
com.yd.api.commission.service.LifeCommissionService
;
import
com.yd.api.commission.vo.lifecommission.*
;
import
com.yd.api.result.CommonResult
;
import
com.yd.dal.entity.agms.fortune.FortunePayToOrderInfo
;
import
com.yd.dal.entity.commission.AgPoOrderCommission
;
import
com.yd.dal.entity.commission.OrderCommissonCheck
;
import
com.yd.dal.entity.customer.AclCustomerFortune
;
import
com.yd.dal.entity.customer.AclInsurerBranch
;
import
com.yd.dal.entity.customer.AclPractitioner
;
import
com.yd.dal.entity.customer.AclPractitionerSubordinateSystem
;
import
com.yd.dal.entity.meta.MdDropOptions
;
import
com.yd.dal.entity.order.PoOrder
;
import
com.yd.dal.mapper.commission.AgPoOrderCommissionMapper
;
import
com.yd.dal.mapper.customer.AclPractitionerMapper
;
import
com.yd.dal.mapper.lifecommission.LifeCommissionMapper
;
import
com.yd.dal.service.customer.AclCustomerFortuneDALService
;
import
com.yd.dal.service.customer.AclPractitionerSubordinateSystemDALService
;
import
com.yd.dal.service.order.PoOrderDALService
;
import
com.yd.rmi.ali.send.service.SendService
;
import
com.yd.rmi.cache.SystemConfigService
;
import
com.yd.util.CommonUtil
;
import
com.yd.util.config.ZHBErrorConfig
;
import
org.apache.commons.collections.CollectionUtils
;
import
org.apache.commons.lang.StringUtils
;
...
...
@@ -46,6 +49,10 @@ public class LifeCommissionServiceImpl implements LifeCommissionService {
private
SendService
sendService
;
@Autowired
private
AgPoOrderCommissionMapper
orderCommissionMapper
;
@Autowired
private
AclPractitionerSubordinateSystemDALService
aclPractitionerSubordinateSystemDALService
;
@Autowired
private
AclPractitionerMapper
aclPractitionerMapper
;
@Override
...
...
@@ -53,15 +60,18 @@ public class LifeCommissionServiceImpl implements LifeCommissionService {
ComeCommissionListResponseVO
resp
=
new
ComeCommissionListResponseVO
();
String
commissionType
=
requestVO
.
getCommissionType
();
try
{
if
(
StringUtils
.
isBlank
(
commissionType
))
{
resp
.
setCommonResult
(
new
CommonResult
(
false
,
"佣金类型不能为空"
));
return
resp
;
}
if
(
"2"
.
equals
(
commissionType
))
{
this
.
querySpecialCommission
(
requestVO
,
resp
);
}
else
{
// if (StringUtils.isBlank(commissionType)) {
// resp.setCommonResult(new CommonResult(false, "佣金类型不能为空"));
// return resp;
// }
// if ("2".equals(commissionType)) {
// this.querySpecialCommission(requestVO, resp);
// } else {
// this.queryBaseCommission(requestVO, resp);
// }
this
.
queryBaseCommission
(
requestVO
,
resp
);
}
// 设置佣金项目名称
this
.
setCommissionItemName
(
resp
);
...
...
@@ -330,12 +340,77 @@ public class LifeCommissionServiceImpl implements LifeCommissionService {
ExportComeCommissionResponseVO
responseVO
=
new
ExportComeCommissionResponseVO
();
List
<
ComeCommissionVO
>
dataList
=
lifeCommissionMapper
.
queryComeCommissionList
(
requestVO
);
// 查询体系架构信息
queryOrganization
(
dataList
);
createCSV
(
dataList
,
response
);
responseVO
.
setCommonResult
(
new
CommonResult
(
true
,
ZHBErrorConfig
.
getErrorInfo
(
"800000"
)));
return
responseVO
;
}
private
void
queryOrganization
(
List
<
ComeCommissionVO
>
dataList
)
{
List
<
AclPractitioner
>
aclPractitionerList
=
aclPractitionerMapper
.
findAll
();
Map
<
Long
,
AclPractitioner
>
aclPractitionerMap
=
new
HashMap
<>();
if
(
aclPractitionerList
!=
null
&&
aclPractitionerList
.
size
()
>
0
)
{
for
(
AclPractitioner
item
:
aclPractitionerList
)
{
aclPractitionerMap
.
put
(
item
.
getId
(),
item
);
}
}
List
<
AclPractitionerSubordinateSystem
>
subordinateSystemList
=
aclPractitionerSubordinateSystemDALService
.
findAll
();
Map
<
Long
,
AclPractitionerSubordinateSystem
>
subordinateSystemMap
=
new
HashMap
<>();
if
(
subordinateSystemList
!=
null
&&
subordinateSystemList
.
size
()
>
0
)
{
for
(
AclPractitionerSubordinateSystem
item
:
subordinateSystemList
)
{
subordinateSystemMap
.
put
(
item
.
getId
(),
item
);
}
}
Map
<
Long
,
AclInsurerBranch
>
aclInsurerBranchMap
=
systemConfigService
.
getAclInsurerBranchMap
();
//经纪人本人
AclPractitioner
self
=
null
;
//所属体系
AclPractitionerSubordinateSystem
subordinateSystem
=
null
;
//分公司
AclInsurerBranch
insurerBranch
=
null
;
Long
practitionerId
=
null
;
ComeCommissionVO
comeCommissionVO
=
null
;
for
(
int
i
=
0
;
i
<
dataList
.
size
();
i
++)
{
comeCommissionVO
=
dataList
.
get
(
i
);
practitionerId
=
comeCommissionVO
.
getPractitionerId
();
self
=
aclPractitionerMap
.
get
(
practitionerId
);
if
(
self
!=
null
)
{
if
(
self
.
getSubordinateSystemId
()
!=
null
)
{
subordinateSystem
=
subordinateSystemMap
.
get
(
self
.
getSubordinateSystemId
());
if
(
subordinateSystem
!=
null
)
{
comeCommissionVO
.
setSubordinateSystemName
(
subordinateSystem
.
getName
());
if
(
"S2"
.
equals
(
subordinateSystem
.
getSystemType
()))
{
comeCommissionVO
.
setS2SubordinateSystemName
(
subordinateSystem
.
getName
());
}
}
}
if
(
null
!=
self
.
getS2Id
())
{
subordinateSystem
=
subordinateSystemMap
.
get
(
self
.
getS2Id
());
comeCommissionVO
.
setS2SubordinateSystemName
(
subordinateSystem
!=
null
?
subordinateSystem
.
getName
()
:
null
);
}
if
(
null
!=
self
.
getS3Id
())
{
subordinateSystem
=
subordinateSystemMap
.
get
(
self
.
getS3Id
());
comeCommissionVO
.
setS3SubordinateSystemName
(
subordinateSystem
!=
null
?
subordinateSystem
.
getName
()
:
null
);
}
}
if
(
null
!=
comeCommissionVO
.
getYdBranchId
())
{
insurerBranch
=
aclInsurerBranchMap
.
get
(
Long
.
valueOf
(
comeCommissionVO
.
getYdBranchId
()));
comeCommissionVO
.
setYdBrachName
(
insurerBranch
!=
null
?
insurerBranch
.
getBranchName
()
:
"总公司直属"
);
}
else
{
comeCommissionVO
.
setYdBrachName
(
"总公司直属"
);
}
}
}
private
void
orderCommissionCheckCancelSendMail
(
List
<
PoOrder
>
orders
)
{
//发送邮件
List
<
String
>
ccList
=
systemConfigService
.
getListConfigValue
(
"CancelPolicyNotifyCommissionChecking"
);
...
...
@@ -462,7 +537,10 @@ public class LifeCommissionServiceImpl implements LifeCommissionService {
private
void
createCSV
(
List
<
ComeCommissionVO
>
dataList
,
HttpServletResponse
response
)
{
String
charset
=
"UTF-8"
;
// 读取字符编码
String
[]
columnName
=
new
String
[]{
"序号"
,
"来佣编号"
,
"预计来佣年月"
,
"实际来佣年月"
,
"检核年月"
,
"保险公司"
,
"保单号"
,
"保费"
,
"来佣率"
,
"来佣金额"
,
"来佣状态 "
,
"经纪人"
,
"经纪人类型"
,
"下单时间"
,
"购买方案"
,
"产品险种"
,
"保险种类"
,
"缴费年限"
,
"保障期间"
};
String
[]
columnName
=
new
String
[]{
"序号"
,
"来佣编号"
,
"预计来佣年月"
,
"实际来佣年月"
,
"检核年月"
,
"保险公司"
,
"保险分公司"
,
"保单号"
,
"保费"
,
"来佣率"
,
"来佣金额"
,
"来佣状态 "
,
"经纪人"
,
"经纪人类型"
,
"下单时间"
,
"购买方案"
,
"产品险种"
,
"保险种类"
,
"缴费年限"
,
"保障期间"
,
"银盾出单机构"
,
"S3纵队"
,
"S2体系"
,
"S1分部"
};
String
tableName
=
"YD_Export_ComeCommission"
;
String
CSV_COLUMN_SEPARATOR
=
","
;
//CSV文件列分隔符
String
CSV_ROW_SEPARATOR
=
"\r\n"
;
//CSV文件行分隔符
...
...
@@ -480,15 +558,16 @@ public class LifeCommissionServiceImpl implements LifeCommissionService {
buf
.
append
(
i
+
1
).
append
(
CSV_COLUMN_SEPARATOR
);
buf
.
append
(
info
.
getCommissionNo
()).
append
(
CSV_COLUMN_SEPARATOR
);
buf
.
append
(
"\t"
).
append
(
info
.
getCommissionYear
()).
append
(
"\t"
).
append
(
CSV_COLUMN_SEPARATOR
);
buf
.
append
(
"\t"
).
append
(
info
.
getCommissionTime
()
==
null
?
""
:
info
.
getCommissionTime
()
).
append
(
"\t"
).
append
(
CSV_COLUMN_SEPARATOR
);
buf
.
append
(
"\t"
).
append
(
info
.
getCheckDate
()
==
null
?
""
:
info
.
getCheckDate
()
).
append
(
"\t"
).
append
(
CSV_COLUMN_SEPARATOR
);
buf
.
append
(
"\t"
).
append
(
info
.
getCommissionTime
()).
append
(
"\t"
).
append
(
CSV_COLUMN_SEPARATOR
);
buf
.
append
(
"\t"
).
append
(
info
.
getCheckDate
()).
append
(
"\t"
).
append
(
CSV_COLUMN_SEPARATOR
);
buf
.
append
(
info
.
getInsurerName
()).
append
(
CSV_COLUMN_SEPARATOR
);
buf
.
append
(
info
.
getInsurerBrachName
()).
append
(
CSV_COLUMN_SEPARATOR
);
buf
.
append
(
"\t"
).
append
(
info
.
getPolicyNo
()).
append
(
"\t"
).
append
(
CSV_COLUMN_SEPARATOR
);
buf
.
append
(
info
.
getOrderPrice
()).
append
(
CSV_COLUMN_SEPARATOR
);
buf
.
append
(
info
.
getCommissionRate
()).
append
(
CSV_COLUMN_SEPARATOR
);
buf
.
append
(
info
.
getCommissionAmount
()).
append
(
CSV_COLUMN_SEPARATOR
);
buf
.
append
(
this
.
transferCommissionCheckStatus
(
info
.
getCommissionCheckStatus
())).
append
(
CSV_COLUMN_SEPARATOR
);
buf
.
append
(
info
.
getName
()
==
null
?
"/"
:
info
.
getName
()
).
append
(
CSV_COLUMN_SEPARATOR
);
buf
.
append
(
info
.
getName
()).
append
(
CSV_COLUMN_SEPARATOR
);
if
(
"27"
.
equals
(
info
.
getPractitionerTypeId
()))
{
buf
.
append
(
"产险"
).
append
(
CSV_COLUMN_SEPARATOR
);
}
else
if
(
"28"
.
equals
(
info
.
getPractitionerTypeId
()))
{
...
...
@@ -500,8 +579,13 @@ public class LifeCommissionServiceImpl implements LifeCommissionService {
buf
.
append
(
info
.
getPlanName
()).
append
(
CSV_COLUMN_SEPARATOR
);
buf
.
append
(
info
.
getPlanCategoryName
()).
append
(
CSV_COLUMN_SEPARATOR
);
buf
.
append
(
info
.
getCategoryName
()).
append
(
CSV_COLUMN_SEPARATOR
);
buf
.
append
(
info
.
getPayTerm
()
==
null
?
"/"
:
info
.
getPayTerm
()
).
append
(
CSV_COLUMN_SEPARATOR
);
buf
.
append
(
info
.
getPayTerm
()).
append
(
CSV_COLUMN_SEPARATOR
);
buf
.
append
(
info
.
getCoverageTerm
()
==
null
?
"/"
:
info
.
getCoverageTerm
().
substring
(
1
)).
append
(
CSV_COLUMN_SEPARATOR
);
buf
.
append
(
info
.
getYdBrachName
()).
append
(
CSV_COLUMN_SEPARATOR
);
buf
.
append
(
info
.
getS3SubordinateSystemName
()).
append
(
CSV_COLUMN_SEPARATOR
);
buf
.
append
(
info
.
getS2SubordinateSystemName
()).
append
(
CSV_COLUMN_SEPARATOR
);
buf
.
append
(
info
.
getSubordinateSystemName
()).
append
(
CSV_COLUMN_SEPARATOR
);
buf
.
append
(
CSV_ROW_SEPARATOR
);
}
}
...
...
yd-api/src/main/java/com/yd/api/commission/vo/lifecommission/ComeCommissionVO.java
View file @
b030474a
package
com
.
yd
.
api
.
commission
.
vo
.
lifecommission
;
import
lombok.Data
;
import
org.apache.commons.lang.StringUtils
;
@Data
public
class
ComeCommissionVO
{
/**
* 订单id
* 比对日期
* 保险公司
* 购买方案
* 保单号
* 保费
* 来佣率
* 来用金额
* 来佣状态
* 下单时间
* 缴费年限
* 保障期间
* 产品险种
* 保险种类
* 经纪人姓名
* 经纪人类型
*/
private
Long
orderId
;
private
String
checkDate
;
private
String
insurerName
;
private
String
planName
;
private
String
ydBranchId
;
//银盾出单机构
private
String
checkDate
;
//比对日期
private
String
insurerName
;
//保险公司
private
String
planName
;
//购买方案
private
String
policyNo
;
private
String
orderPrice
;
private
String
commissionRate
;
private
String
commissionAmount
;
private
String
commissionCheckStatus
;
private
String
orderDate
;
private
String
payTerm
;
private
String
coverageTerm
;
private
String
categoryName
;
private
String
planCategoryName
;
private
String
name
;
private
String
practitionerTypeId
;
private
Long
commissionId
;
private
String
commissionNo
;
private
String
amount
;
private
String
commissionYear
;
private
String
commissionStatus
;
private
String
commissionTime
;
private
String
commissionPeriod
;
private
String
orderPrice
;
//保费
private
String
commissionRate
;
//来佣率
private
String
commissionAmount
;
//来佣金额
private
String
commissionCheckStatus
;
//来佣状态
private
String
orderDate
;
//下单时间
private
String
payTerm
;
//缴费年限
private
String
coverageTerm
;
//保障期间
private
String
categoryName
;
//产品险种
private
String
planCategoryName
;
//保险种类
private
String
name
;
//经纪人姓名
private
Long
practitionerId
;
private
String
practitionerTypeId
;
//经纪人类型
private
Long
commissionId
;
//
private
String
commissionNo
;
//
private
String
amount
;
//
private
String
commissionYear
;
//
private
String
commissionStatus
;
//
private
String
commissionTime
;
//
private
String
commissionPeriod
;
//
private
String
commissionType
;
//来佣类型(1:基础来佣;2:特殊激励来佣;3:公告佣)
private
String
commissionTypeName
;
...
...
@@ -54,5 +37,327 @@ public class ComeCommissionVO {
private
String
commissionItemName
;
private
String
insurerBrachId
;
private
String
insurerBranchName
;
private
String
insurerBrachName
;
private
Long
ydBrachId
;
//银盾出单机构id
private
String
ydBrachName
;
//银盾出单机构
private
String
s3SubordinateSystemName
;
//s3所属体系名称
private
String
s2SubordinateSystemName
;
//s2所属体系名称
private
String
subordinateSystemName
;
//所属体系名称
public
Long
getOrderId
()
{
return
orderId
;
}
public
void
setOrderId
(
Long
orderId
)
{
this
.
orderId
=
orderId
;
}
public
String
getYdBranchId
()
{
return
ydBranchId
;
}
public
void
setYdBranchId
(
String
ydBranchId
)
{
this
.
ydBranchId
=
ydBranchId
;
}
public
String
getCheckDate
()
{
if
(
StringUtils
.
isBlank
(
checkDate
))
{
return
StringUtils
.
EMPTY
;
}
return
checkDate
;
}
public
void
setCheckDate
(
String
checkDate
)
{
this
.
checkDate
=
checkDate
;
}
public
String
getInsurerName
()
{
return
insurerName
;
}
public
void
setInsurerName
(
String
insurerName
)
{
this
.
insurerName
=
insurerName
;
}
public
String
getPlanName
()
{
return
planName
;
}
public
void
setPlanName
(
String
planName
)
{
this
.
planName
=
planName
;
}
public
String
getPolicyNo
()
{
return
policyNo
;
}
public
void
setPolicyNo
(
String
policyNo
)
{
this
.
policyNo
=
policyNo
;
}
public
String
getOrderPrice
()
{
return
orderPrice
;
}
public
void
setOrderPrice
(
String
orderPrice
)
{
this
.
orderPrice
=
orderPrice
;
}
public
String
getCommissionRate
()
{
return
commissionRate
;
}
public
void
setCommissionRate
(
String
commissionRate
)
{
this
.
commissionRate
=
commissionRate
;
}
public
String
getCommissionAmount
()
{
return
commissionAmount
;
}
public
void
setCommissionAmount
(
String
commissionAmount
)
{
this
.
commissionAmount
=
commissionAmount
;
}
public
String
getCommissionCheckStatus
()
{
return
commissionCheckStatus
;
}
public
void
setCommissionCheckStatus
(
String
commissionCheckStatus
)
{
this
.
commissionCheckStatus
=
commissionCheckStatus
;
}
public
String
getOrderDate
()
{
return
orderDate
;
}
public
void
setOrderDate
(
String
orderDate
)
{
this
.
orderDate
=
orderDate
;
}
public
String
getPayTerm
()
{
if
(
StringUtils
.
isBlank
(
payTerm
))
{
return
"/"
;
}
return
payTerm
;
}
public
void
setPayTerm
(
String
payTerm
)
{
this
.
payTerm
=
payTerm
;
}
public
String
getCoverageTerm
()
{
return
coverageTerm
;
}
public
void
setCoverageTerm
(
String
coverageTerm
)
{
this
.
coverageTerm
=
coverageTerm
;
}
public
String
getCategoryName
()
{
return
categoryName
;
}
public
void
setCategoryName
(
String
categoryName
)
{
this
.
categoryName
=
categoryName
;
}
public
String
getPlanCategoryName
()
{
return
planCategoryName
;
}
public
void
setPlanCategoryName
(
String
planCategoryName
)
{
this
.
planCategoryName
=
planCategoryName
;
}
public
String
getName
()
{
if
(
StringUtils
.
isBlank
(
name
))
{
return
"/"
;
}
return
name
;
}
public
void
setName
(
String
name
)
{
this
.
name
=
name
;
}
public
Long
getPractitionerId
()
{
return
practitionerId
;
}
public
void
setPractitionerId
(
Long
practitionerId
)
{
this
.
practitionerId
=
practitionerId
;
}
public
String
getPractitionerTypeId
()
{
return
practitionerTypeId
;
}
public
void
setPractitionerTypeId
(
String
practitionerTypeId
)
{
this
.
practitionerTypeId
=
practitionerTypeId
;
}
public
Long
getCommissionId
()
{
return
commissionId
;
}
public
void
setCommissionId
(
Long
commissionId
)
{
this
.
commissionId
=
commissionId
;
}
public
String
getCommissionNo
()
{
return
commissionNo
;
}
public
void
setCommissionNo
(
String
commissionNo
)
{
this
.
commissionNo
=
commissionNo
;
}
public
String
getAmount
()
{
return
amount
;
}
public
void
setAmount
(
String
amount
)
{
this
.
amount
=
amount
;
}
public
String
getCommissionYear
()
{
return
commissionYear
;
}
public
void
setCommissionYear
(
String
commissionYear
)
{
this
.
commissionYear
=
commissionYear
;
}
public
String
getCommissionStatus
()
{
return
commissionStatus
;
}
public
void
setCommissionStatus
(
String
commissionStatus
)
{
this
.
commissionStatus
=
commissionStatus
;
}
public
String
getCommissionTime
()
{
if
(
StringUtils
.
isBlank
(
commissionTime
))
{
return
StringUtils
.
EMPTY
;
}
return
commissionTime
;
}
public
void
setCommissionTime
(
String
commissionTime
)
{
this
.
commissionTime
=
commissionTime
;
}
public
String
getCommissionPeriod
()
{
return
commissionPeriod
;
}
public
void
setCommissionPeriod
(
String
commissionPeriod
)
{
this
.
commissionPeriod
=
commissionPeriod
;
}
public
String
getCommissionType
()
{
return
commissionType
;
}
public
void
setCommissionType
(
String
commissionType
)
{
this
.
commissionType
=
commissionType
;
}
public
String
getCommissionTypeName
()
{
return
commissionTypeName
;
}
public
void
setCommissionTypeName
(
String
commissionTypeName
)
{
this
.
commissionTypeName
=
commissionTypeName
;
}
public
String
getCommissionItem
()
{
return
commissionItem
;
}
public
void
setCommissionItem
(
String
commissionItem
)
{
this
.
commissionItem
=
commissionItem
;
}
public
String
getCommissionItemName
()
{
return
commissionItemName
;
}
public
void
setCommissionItemName
(
String
commissionItemName
)
{
this
.
commissionItemName
=
commissionItemName
;
}
public
String
getInsurerBrachId
()
{
return
insurerBrachId
;
}
public
void
setInsurerBrachId
(
String
insurerBrachId
)
{
this
.
insurerBrachId
=
insurerBrachId
;
}
public
String
getInsurerBrachName
()
{
if
(
StringUtils
.
isBlank
(
insurerBrachName
))
{
return
StringUtils
.
EMPTY
;
}
return
insurerBrachName
;
}
public
void
setInsurerBrachName
(
String
insurerBrachName
)
{
this
.
insurerBrachName
=
insurerBrachName
;
}
public
String
getYdBrachName
()
{
if
(
StringUtils
.
isBlank
(
ydBrachName
))
{
return
StringUtils
.
EMPTY
;
}
return
ydBrachName
;
}
public
void
setYdBrachName
(
String
ydBrachName
)
{
this
.
ydBrachName
=
ydBrachName
;
}
public
String
getS3SubordinateSystemName
()
{
if
(
StringUtils
.
isBlank
(
s3SubordinateSystemName
))
{
return
StringUtils
.
EMPTY
;
}
return
s3SubordinateSystemName
;
}
public
void
setS3SubordinateSystemName
(
String
s3SubordinateSystemName
)
{
this
.
s3SubordinateSystemName
=
s3SubordinateSystemName
;
}
public
String
getS2SubordinateSystemName
()
{
if
(
StringUtils
.
isBlank
(
s2SubordinateSystemName
))
{
return
StringUtils
.
EMPTY
;
}
return
s2SubordinateSystemName
;
}
public
void
setS2SubordinateSystemName
(
String
s2SubordinateSystemName
)
{
this
.
s2SubordinateSystemName
=
s2SubordinateSystemName
;
}
public
String
getSubordinateSystemName
()
{
if
(
StringUtils
.
isBlank
(
subordinateSystemName
))
{
return
StringUtils
.
EMPTY
;
}
return
subordinateSystemName
;
}
public
void
setSubordinateSystemName
(
String
subordinateSystemName
)
{
this
.
subordinateSystemName
=
subordinateSystemName
;
}
public
Long
getYdBrachId
()
{
return
ydBrachId
;
}
public
void
setYdBrachId
(
Long
ydBrachId
)
{
this
.
ydBrachId
=
ydBrachId
;
}
}
yd-api/src/main/java/com/yd/dal/entity/customer/AclInsurerBranch.java
View file @
b030474a
package
com
.
yd
.
dal
.
entity
.
customer
;
import
java.util.Date
;
import
lombok.Data
;
import
java.io.Serializable
;
import
java.util.Date
;
/**
* 保险公司分公司/营业部
*/
@Data
public
class
AclInsurerBranch
{
public
class
AclInsurerBranch
implements
Serializable
{
private
static
final
long
serialVersionUID
=
1L
;
/**
* serial id
*/
...
...
yd-api/src/main/java/com/yd/dal/entity/customer/AclPractitioner.java
View file @
b030474a
...
...
@@ -254,4 +254,8 @@ public class AclPractitioner {
* 育成人id
*/
private
Long
raiseId
;
private
Long
s1Id
;
private
Long
s2Id
;
private
Long
s3Id
;
}
yd-api/src/main/java/com/yd/dal/mapper/customer/AclInsurerBranchMapper.java
View file @
b030474a
package
com
.
yd
.
dal
.
mapper
.
customer
;
import
com.yd.dal.entity.customer.AclInsurerBranch
;
import
java.util.List
;
import
org.apache.ibatis.annotations.Param
;
import
java.util.List
;
public
interface
AclInsurerBranchMapper
{
int
deleteByPrimaryKey
(
Long
id
);
...
...
@@ -22,4 +23,6 @@ public interface AclInsurerBranchMapper {
int
updateBatchSelective
(
List
<
AclInsurerBranch
>
list
);
int
batchInsert
(
@Param
(
"list"
)
List
<
AclInsurerBranch
>
list
);
List
<
AclInsurerBranch
>
findAll
();
}
\ No newline at end of file
yd-api/src/main/java/com/yd/dal/mapper/customer/AclPractitionerSubordinateSystemMapper.java
View file @
b030474a
...
...
@@ -40,4 +40,6 @@ public interface AclPractitionerSubordinateSystemMapper {
List
<
AclPractitionerSubordinateSystem
>
findDeptIdAndInsureBranchIdNull
(
Long
insurerId
);
List
<
AclPractitionerSubordinateSystem
>
findDeptIdNotNull
(
Long
insurerId
);
List
<
AclPractitionerSubordinateSystem
>
findAll
();
}
yd-api/src/main/java/com/yd/dal/service/customer/AclInsurerBranchDALService.java
View file @
b030474a
...
...
@@ -2,9 +2,13 @@ package com.yd.dal.service.customer;
import
com.yd.dal.entity.customer.AclInsurerBranch
;
import
java.util.List
;
/**
* @author xxy
*/
public
interface
AclInsurerBranchDALService
{
void
update
(
AclInsurerBranch
branch
);
List
<
AclInsurerBranch
>
findAll
();
}
yd-api/src/main/java/com/yd/dal/service/customer/AclPractitionerSubordinateSystemDALService.java
View file @
b030474a
...
...
@@ -48,4 +48,5 @@ public interface AclPractitionerSubordinateSystemDALService {
*/
public
void
orgRecursion
(
List
<
AclPractitionerSubordinateSystem
>
childOrg
,
List
<
AclPractitionerSubordinateSystem
>
allList
,
Long
pid
);
List
<
AclPractitionerSubordinateSystem
>
findAll
();
}
yd-api/src/main/java/com/yd/dal/service/customer/impl/AclInsurerBranchDALServiceImpl.java
View file @
b030474a
...
...
@@ -6,6 +6,7 @@ import com.yd.dal.service.customer.AclInsurerBranchDALService;
import
org.springframework.stereotype.Service
;
import
javax.annotation.Resource
;
import
java.util.List
;
/**
* @author xxy
...
...
@@ -19,4 +20,9 @@ public class AclInsurerBranchDALServiceImpl implements AclInsurerBranchDALServic
public
void
update
(
AclInsurerBranch
branch
)
{
mapper
.
updateByPrimaryKeySelective
(
branch
);
}
@Override
public
List
<
AclInsurerBranch
>
findAll
()
{
return
mapper
.
findAll
();
}
}
yd-api/src/main/java/com/yd/dal/service/customer/impl/AclPractitionerSubordinateSystemDALServiceImpl.java
View file @
b030474a
...
...
@@ -155,4 +155,9 @@ public class AclPractitionerSubordinateSystemDALServiceImpl implements AclPracti
}
}
}
@Override
public
List
<
AclPractitionerSubordinateSystem
>
findAll
()
{
return
aclPractitionerSubordinateSystemMapper
.
findAll
();
}
}
yd-api/src/main/java/com/yd/rmi/cache/SystemConfigService.java
View file @
b030474a
package
com
.
yd
.
rmi
.
cache
;
import
com.yd.dal.entity.customer.AclInsurerBranch
;
import
com.yd.dal.entity.meta.*
;
import
com.yd.dal.service.customer.AclInsurerBranchDALService
;
import
com.yd.dal.service.meta.*
;
import
com.yd.rmi.ali.ossinterf.service.AliOssInterfService
;
import
com.yd.util.CommonUtil
;
...
...
@@ -10,10 +12,7 @@ import org.springframework.beans.factory.annotation.Autowired;
import
org.springframework.boot.CommandLineRunner
;
import
org.springframework.stereotype.Service
;
import
java.util.ArrayList
;
import
java.util.Arrays
;
import
java.util.List
;
import
java.util.Optional
;
import
java.util.*
;
import
java.util.stream.Collectors
;
/**
...
...
@@ -35,6 +34,8 @@ public class SystemConfigService implements CommandLineRunner{
private
MdIncometaxRateDALService
mdIncometaxRateDALService
;
@Autowired
private
MdDropOptionsDALService
mdDropOptionsDALService
;
@Autowired
private
AclInsurerBranchDALService
aclInsurerBranchDALService
;
/**
* 保存cache
...
...
@@ -308,4 +309,23 @@ public class SystemConfigService implements CommandLineRunner{
}
return
hiringApproveSteps
;
}
public
Map
<
Long
,
AclInsurerBranch
>
getAclInsurerBranchMap
()
{
Map
<
Long
,
AclInsurerBranch
>
map
=
null
;
Element
element
=
systemConfigCache
.
get
(
"aclInsurerBranchMap"
);
if
(
element
!=
null
&&
element
.
getObjectValue
()
!=
null
)
{
map
=
(
Map
<
Long
,
AclInsurerBranch
>)
element
.
getObjectValue
();
}
else
{
List
<
AclInsurerBranch
>
list
=
aclInsurerBranchDALService
.
findAll
();
if
(
list
!=
null
&&
list
.
size
()
>
0
)
{
map
=
new
HashMap
<
Long
,
AclInsurerBranch
>();
for
(
AclInsurerBranch
item
:
list
)
{
map
.
put
(
item
.
getId
(),
item
);
}
}
element
=
new
Element
(
"aclInsurerBranchMap"
,
map
);
systemConfigCache
.
put
(
element
);
}
return
map
;
}
}
yd-api/src/main/resources/mapper/customer/AclInsurerBranchMapper.xml
View file @
b030474a
...
...
@@ -463,4 +463,12 @@
#{item.updatedBy,jdbcType=BIGINT})
</foreach>
</insert>
<select
id=
"findAll"
resultMap=
"BaseResultMap"
>
<!--@mbg.generated-->
select
<include
refid=
"Base_Column_List"
/>
from ag_acl_insurer_branch
</select>
</mapper>
\ No newline at end of file
yd-api/src/main/resources/mapper/customer/AclPractitionerMapper.xml
View file @
b030474a
...
...
@@ -50,6 +50,10 @@
<result
column=
"can_login_dyd"
jdbcType=
"BIGINT"
property=
"canLoginDyd"
/>
<result
column=
"can_see_salary_list"
jdbcType=
"BIGINT"
property=
"canSeeSalaryList"
/>
<result
column=
"raise_id"
jdbcType=
"BIGINT"
property=
"raiseId"
/>
<result
column=
"s1_id"
jdbcType=
"BIGINT"
property=
"s1Id"
/>
<result
column=
"s2_id"
jdbcType=
"BIGINT"
property=
"s2Id"
/>
<result
column=
"s3_id"
jdbcType=
"BIGINT"
property=
"s3Id"
/>
</resultMap>
<sql
id=
"Base_Column_List"
>
<!--@mbg.generated-->
...
...
@@ -60,7 +64,7 @@
province_id, province_name, city_id, city_name, cert_list, bio_intro, wechat_id,
qq_id, is_profile_show, is_name_show, is_mobile_show, education_level, graduated_university,
mentor_id, introducer_id, gender, contract_oss_path, hiring_basic_info_id, can_login_dyd,
can_see_salary_list,raise_id
can_see_salary_list,raise_id
,s1_id,s2_id,s3_id
</sql>
<select
id=
"selectByPrimaryKey"
parameterType=
"java.lang.Long"
resultMap=
"BaseResultMap"
>
<!--@mbg.generated-->
...
...
yd-api/src/main/resources/mapper/customer/AclPractitionerSubordinateSystemMapper.xml
View file @
b030474a
...
...
@@ -350,6 +350,11 @@
SELECT t.* FROM ag_acl_practitioner_subordinate_system t WHERE t.insurer_branch_id is null and t.dept_id is not null and t.is_active = 1 and t.insurer_id= #{insurerId,jdbcType=BIGINT}
</select>
<select
id=
"findAll"
resultMap=
"BaseResultMap"
>
select
<include
refid=
"Base_Column_List"
/>
from ag_acl_practitioner_subordinate_system
</select>
...
...
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