Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
dj
/
rpc-dj-pe-analysis
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 2b512020
authored
Jun 26, 2026
by
章家宝
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
feat:本系统的业务类型与其他系统的业务类型做映射
1 parent
41e269e4
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
25 additions
and
2 deletions
rpc-dj-pe-analysis/src/main/java/cn/com/glsx/dj/peanalysis/service/MerchantHrbpRelationService.java
rpc-dj-pe-analysis/src/main/java/cn/com/glsx/dj/peanalysis/service/MerchantHrbpRelationService.java
View file @
2b51202
...
@@ -31,10 +31,31 @@ public class MerchantHrbpRelationService {
...
@@ -31,10 +31,31 @@ public class MerchantHrbpRelationService {
private
RecruitmentDemandRemote
recruitmentDemandRemote
;
private
RecruitmentDemandRemote
recruitmentDemandRemote
;
/**
/**
* 本系统业务类型映射到远程接口业务类型
* 本系统: 1=延保, 2=轻改, 3=权益
* 远程接口: 1=延保, 2=权益, 3=轻改
*/
private
Integer
mapToRemoteBusinessType
(
Byte
localBusinessType
)
{
if
(
localBusinessType
==
null
)
{
return
null
;
}
switch
(
localBusinessType
)
{
case
1
:
// 延保 -> 延保
return
1
;
case
2
:
// 轻改 -> 轻改(远程为3)
return
3
;
case
3
:
// 权益 -> 权益(远程为2)
return
2
;
default
:
return
(
int
)
localBusinessType
;
}
}
/**
* 基于省份获取HRBP映射
* 基于省份获取HRBP映射
*
*
* @param provinceNames 省份名称集合
* @param provinceNames 省份名称集合
* @param businessType 业务类型,用于过滤匹配的HRBP配置
* @param businessType 业务类型
(本系统编码:1=延保, 2=轻改, 3=权益)
,用于过滤匹配的HRBP配置
* @return provinceName -> (hrbpName, hrbpPhone)
* @return provinceName -> (hrbpName, hrbpPhone)
*/
*/
public
Map
<
String
,
Pair
<
String
,
String
>>
buildProvinceToHrbpMap
(
Set
<
String
>
provinceNames
,
Byte
businessType
)
{
public
Map
<
String
,
Pair
<
String
,
String
>>
buildProvinceToHrbpMap
(
Set
<
String
>
provinceNames
,
Byte
businessType
)
{
...
@@ -43,6 +64,8 @@ public class MerchantHrbpRelationService {
...
@@ -43,6 +64,8 @@ public class MerchantHrbpRelationService {
}
}
long
startMs
=
System
.
currentTimeMillis
();
long
startMs
=
System
.
currentTimeMillis
();
Map
<
String
,
Pair
<
String
,
String
>>
result
=
new
HashMap
<>();
Map
<
String
,
Pair
<
String
,
String
>>
result
=
new
HashMap
<>();
// 映射业务类型到远程接口编码
Integer
remoteBusinessType
=
mapToRemoteBusinessType
(
businessType
);
try
{
try
{
RecruitmentProvinceHrbpRelation
condition
=
new
RecruitmentProvinceHrbpRelation
();
RecruitmentProvinceHrbpRelation
condition
=
new
RecruitmentProvinceHrbpRelation
();
RpcResponse
<
List
<
RecruitmentProvinceHrbpRelation
>>
response
=
RpcResponse
<
List
<
RecruitmentProvinceHrbpRelation
>>
response
=
...
@@ -51,7 +74,7 @@ public class MerchantHrbpRelationService {
...
@@ -51,7 +74,7 @@ public class MerchantHrbpRelationService {
response
.
getResult
().
forEach
(
relation
->
{
response
.
getResult
().
forEach
(
relation
->
{
// 业务类型过滤:仅当 businessType 不为空且不匹配时跳过
// 业务类型过滤:仅当 businessType 不为空且不匹配时跳过
if
(
relation
.
getBusinessType
()
!=
null
if
(
relation
.
getBusinessType
()
!=
null
&&
!
Objects
.
equals
(
Byte
.
valueOf
(
relation
.
getBusinessType
()),
b
usinessType
))
{
&&
!
Objects
.
equals
(
Integer
.
valueOf
(
relation
.
getBusinessType
()),
remoteB
usinessType
))
{
return
;
return
;
}
}
// 处理全国通用配置
// 处理全国通用配置
...
...
Write
Preview
Markdown
is supported
Attach a file
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 post a comment