Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
Y
yifu-mvp
Project
Project
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
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
fangxinjiang
yifu-mvp
Commits
b2476458
Commit
b2476458
authored
Dec 22, 2025
by
huyuchen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
huych-电子档案批量导入提交
parent
fb3da26e
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
249 additions
and
98 deletions
+249
-98
EmployeeRegistrationPre.java
...plus/v1/yifu/archives/entity/EmployeeRegistrationPre.java
+15
-3
EmployeeRegistrationPreServiceImpl.java
...ives/service/impl/EmployeeRegistrationPreServiceImpl.java
+98
-65
TEmployeePreLogServiceImpl.java
...ifu/archives/service/impl/TEmployeePreLogServiceImpl.java
+17
-11
TElectronicArchiveDetailController.java
.../batch/controller/TElectronicArchiveDetailController.java
+7
-0
ElectronicArchiveImportServiceImpl.java
...atch/service/impl/ElectronicArchiveImportServiceImpl.java
+51
-4
TElectronicArchiveDetailServiceImpl.java
...tch/service/impl/TElectronicArchiveDetailServiceImpl.java
+28
-1
TElectronicArchiveDetailMapper.xml
.../main/resources/mapper/TElectronicArchiveDetailMapper.xml
+3
-0
EmployeeRegistrationServiceImpl.java
.../v1/csp/service/impl/EmployeeRegistrationServiceImpl.java
+29
-13
TBusinessOperateServiceImpl.java
...s/service/insurance/impl/TBusinessOperateServiceImpl.java
+1
-1
No files found.
yifu-archives/yifu-archives-api/src/main/java/com/yifu/cloud/plus/v1/yifu/archives/entity/EmployeeRegistrationPre.java
View file @
b2476458
package
com
.
yifu
.
cloud
.
plus
.
v1
.
yifu
.
archives
.
entity
;
package
com
.
yifu
.
cloud
.
plus
.
v1
.
yifu
.
archives
.
entity
;
import
com.alibaba.excel.annotation.ExcelProperty
;
import
com.baomidou.mybatisplus.annotation.*
;
import
com.baomidou.mybatisplus.annotation.*
;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
com.yifu.cloud.plus.v1.yifu.archives.vo.TDispatchInfoPreVo
;
import
com.yifu.cloud.plus.v1.yifu.archives.vo.TDispatchInfoPreVo
;
import
com.yifu.cloud.plus.v1.yifu.archives.vo.TFundPreDetailVo
;
import
com.yifu.cloud.plus.v1.yifu.archives.vo.TFundPreDetailVo
;
import
com.yifu.cloud.plus.v1.yifu.archives.vo.TSocialPreDetailVo
;
import
com.yifu.cloud.plus.v1.yifu.archives.vo.TSocialPreDetailVo
;
import
com.yifu.cloud.plus.v1.yifu.common.core.constant.ExcelAttribute
;
import
com.yifu.cloud.plus.v1.yifu.common.mybatis.base.BaseEntity
;
import
com.yifu.cloud.plus.v1.yifu.common.mybatis.base.BaseEntity
;
import
com.yifu.cloud.plus.v1.yifu.insurances.entity.TEmployeeInsurancePre
;
import
com.yifu.cloud.plus.v1.yifu.insurances.entity.TEmployeeInsurancePre
;
import
com.yifu.cloud.plus.v1.yifu.insurances.entity.TInsurancePreDetail
;
import
com.yifu.cloud.plus.v1.yifu.insurances.entity.TInsurancePreDetail
;
...
@@ -109,7 +107,7 @@ public class EmployeeRegistrationPre extends BaseEntity {
...
@@ -109,7 +107,7 @@ public class EmployeeRegistrationPre extends BaseEntity {
@Schema
(
description
=
"商险是否已购买 0 是 1 否"
)
@Schema
(
description
=
"商险是否已购买 0 是 1 否"
)
private
String
insuranceIsBuy
;
private
String
insuranceIsBuy
;
@Schema
(
description
=
"
商险
是否已购买 0 是 1 否"
)
@Schema
(
description
=
"
社保
是否已购买 0 是 1 否"
)
private
String
socialIsBuy
;
private
String
socialIsBuy
;
@Schema
(
description
=
"公积金是否已参保 0 是 1 否"
)
@Schema
(
description
=
"公积金是否已参保 0 是 1 否"
)
...
@@ -177,4 +175,18 @@ public class EmployeeRegistrationPre extends BaseEntity {
...
@@ -177,4 +175,18 @@ public class EmployeeRegistrationPre extends BaseEntity {
@Schema
(
description
=
"公积金是否可修改"
)
@Schema
(
description
=
"公积金是否可修改"
)
@TableField
(
exist
=
false
)
@TableField
(
exist
=
false
)
private
Boolean
fundUpdateFlag
;
private
Boolean
fundUpdateFlag
;
/**
* 社保是否可修改 可修改 true 不可修改 false
*/
@Schema
(
description
=
"社保是否可修改"
)
@TableField
(
exist
=
false
)
private
Boolean
socialUpdateFlag
;
/**
* 合同是否可修改 可修改 true 不可修改 false
*/
@Schema
(
description
=
"合同是否可修改"
)
@TableField
(
exist
=
false
)
private
Boolean
contractUpdateFlag
;
}
}
yifu-archives/yifu-archives-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/archives/service/impl/EmployeeRegistrationPreServiceImpl.java
View file @
b2476458
...
@@ -31,7 +31,6 @@ import com.yifu.cloud.plus.v1.yifu.common.security.util.SecurityUtils;
...
@@ -31,7 +31,6 @@ import com.yifu.cloud.plus.v1.yifu.common.security.util.SecurityUtils;
import
com.yifu.cloud.plus.v1.yifu.insurances.entity.TEmployeeInsurancePre
;
import
com.yifu.cloud.plus.v1.yifu.insurances.entity.TEmployeeInsurancePre
;
import
com.yifu.cloud.plus.v1.yifu.insurances.entity.TInsuranceDetail
;
import
com.yifu.cloud.plus.v1.yifu.insurances.entity.TInsuranceDetail
;
import
com.yifu.cloud.plus.v1.yifu.insurances.vo.*
;
import
com.yifu.cloud.plus.v1.yifu.insurances.vo.*
;
import
com.yifu.cloud.plus.v1.yifu.social.vo.SysBaseSetInfoVo
;
import
lombok.RequiredArgsConstructor
;
import
lombok.RequiredArgsConstructor
;
import
lombok.extern.log4j.Log4j2
;
import
lombok.extern.log4j.Log4j2
;
import
org.springframework.beans.BeanUtils
;
import
org.springframework.beans.BeanUtils
;
...
@@ -571,6 +570,7 @@ public class EmployeeRegistrationPreServiceImpl extends ServiceImpl<EmployeeRegi
...
@@ -571,6 +570,7 @@ public class EmployeeRegistrationPreServiceImpl extends ServiceImpl<EmployeeRegi
oldList
=
sdr
.
getData
().
getPreList
();
oldList
=
sdr
.
getData
().
getPreList
();
}
}
StringBuilder
errorTemp
=
new
StringBuilder
();
// 1:存在商险,判断合规性+日期+五个不同等:
// 1:存在商险,判断合规性+日期+五个不同等:
if
(
Common
.
isNotNull
(
employeeRegistrationPre
.
getServerItem
())
&&
employeeRegistrationPre
.
getServerItem
().
contains
(
"商险"
))
{
if
(
Common
.
isNotNull
(
employeeRegistrationPre
.
getServerItem
())
&&
employeeRegistrationPre
.
getServerItem
().
contains
(
"商险"
))
{
//商险是否购买为是时增加校验
//商险是否购买为是时增加校验
...
@@ -582,7 +582,8 @@ public class EmployeeRegistrationPreServiceImpl extends ServiceImpl<EmployeeRegi
...
@@ -582,7 +582,8 @@ public class EmployeeRegistrationPreServiceImpl extends ServiceImpl<EmployeeRegi
employeeRegistrationPre
.
getExitInsuranceInfoList
().
forEach
(
e
->
e
.
setCreateTime
(
null
));
employeeRegistrationPre
.
getExitInsuranceInfoList
().
forEach
(
e
->
e
.
setCreateTime
(
null
));
boolean
isTrue
=
checkInsuranceIsProcess
(
employeeRegistrationPre
);
boolean
isTrue
=
checkInsuranceIsProcess
(
employeeRegistrationPre
);
if
(
isTrue
)
{
if
(
isTrue
)
{
return
R
.
failed
(
"带出的商险已购买数据状态或条数发生变更,请重新确认!"
);
errorTemp
.
append
(
"带出的商险已购买数据状态或条数发生变更,请重新确认;"
);
// return R.failed("带出的商险已购买数据状态或条数发生变更,请重新确认!");
}
}
List
<
TEmployeeInsurancePre
>
newList
=
new
ArrayList
<>();
List
<
TEmployeeInsurancePre
>
newList
=
new
ArrayList
<>();
if
(
oldList
!=
null
&&
!
oldList
.
isEmpty
())
{
if
(
oldList
!=
null
&&
!
oldList
.
isEmpty
())
{
...
@@ -598,11 +599,12 @@ public class EmployeeRegistrationPreServiceImpl extends ServiceImpl<EmployeeRegi
...
@@ -598,11 +599,12 @@ public class EmployeeRegistrationPreServiceImpl extends ServiceImpl<EmployeeRegi
}
else
if
(
employeeRegistrationPre
.
getInsuranceIsBuy
().
equals
(
CommonConstants
.
ONE_STRING
))
{
}
else
if
(
employeeRegistrationPre
.
getInsuranceIsBuy
().
equals
(
CommonConstants
.
ONE_STRING
))
{
if
(
employeeRegistrationPre
.
getInsurancePreList
()
==
null
if
(
employeeRegistrationPre
.
getInsurancePreList
()
==
null
||
employeeRegistrationPre
.
getInsurancePreList
().
isEmpty
())
{
||
employeeRegistrationPre
.
getInsurancePreList
().
isEmpty
())
{
return
R
.
failed
(
"含商险服务,商险配置不可为空"
);
errorTemp
.
append
(
"含商险服务,商险配置不可为空;"
);
// return R.failed("含商险服务,商险配置不可为空");
}
}
List
<
TEmployeeInsurancePre
>
newList
=
employeeRegistrationPre
.
getInsurancePreList
();
List
<
TEmployeeInsurancePre
>
newList
=
employeeRegistrationPre
.
getInsurancePreList
();
// 1:合规性:查找信息是否允许:
// 1:合规性:查找信息是否允许:
List
<
TEmployeeInsuranceExitCheckVo
>
errorList
=
new
ArrayList
<>();
//
List<TEmployeeInsuranceExitCheckVo> errorList = new ArrayList<>();
TEmployeeInsuranceExitCheckVo
checkVo
;
TEmployeeInsuranceExitCheckVo
checkVo
;
Map
<
String
,
TEmployeeInsurancePre
>
newMap
=
new
HashMap
<>();
Map
<
String
,
TEmployeeInsurancePre
>
newMap
=
new
HashMap
<>();
// 新的KeyMap,存项目
// 新的KeyMap,存项目
...
@@ -622,7 +624,8 @@ public class EmployeeRegistrationPreServiceImpl extends ServiceImpl<EmployeeRegi
...
@@ -622,7 +624,8 @@ public class EmployeeRegistrationPreServiceImpl extends ServiceImpl<EmployeeRegi
key
=
this
.
getFiveKey
(
insurancePreVo
);
key
=
this
.
getFiveKey
(
insurancePreVo
);
newDeptNo
=
insurancePreVo
.
getDeptNo
();
newDeptNo
=
insurancePreVo
.
getDeptNo
();
if
(
Common
.
isEmpty
(
newDeptNo
))
{
if
(
Common
.
isEmpty
(
newDeptNo
))
{
return
R
.
failed
(
"请传项目编码"
);
errorTemp
.
append
(
"项目编码不可为空;"
);
// return R.failed("请传项目编码");
}
}
newKeyDeptNoMap
.
put
(
key
,
insurancePreVo
.
getDeptNo
());
newKeyDeptNoMap
.
put
(
key
,
insurancePreVo
.
getDeptNo
());
if
(
keyMap
.
get
(
key
)
==
null
)
{
if
(
keyMap
.
get
(
key
)
==
null
)
{
...
@@ -630,7 +633,8 @@ public class EmployeeRegistrationPreServiceImpl extends ServiceImpl<EmployeeRegi
...
@@ -630,7 +633,8 @@ public class EmployeeRegistrationPreServiceImpl extends ServiceImpl<EmployeeRegi
keyMap
.
put
(
key
,
CommonConstants
.
ONE_INT
);
keyMap
.
put
(
key
,
CommonConstants
.
ONE_INT
);
}
}
}
else
if
(
Common
.
isEmpty
(
insurancePreVo
.
getModelType
())
||
!
insurancePreVo
.
getModelType
().
equals
(
CommonConstants
.
THREE_STRING
))
{
}
else
if
(
Common
.
isEmpty
(
insurancePreVo
.
getModelType
())
||
!
insurancePreVo
.
getModelType
().
equals
(
CommonConstants
.
THREE_STRING
))
{
return
R
.
failed
(
"保险公司、险种、购买标准、保单起、止日期不可同时重复!"
);
errorTemp
.
append
(
"保险公司、险种、购买标准、保单起、止日期不可同时重复;"
);
// return R.failed("保险公司、险种、购买标准、保单起、止日期不可同时重复!");
}
}
insurancePreVo
.
setEmpIdcard
(
employeeRegistrationPre
.
getEmpIdcard
());
insurancePreVo
.
setEmpIdcard
(
employeeRegistrationPre
.
getEmpIdcard
());
...
@@ -650,7 +654,9 @@ public class EmployeeRegistrationPreServiceImpl extends ServiceImpl<EmployeeRegi
...
@@ -650,7 +654,9 @@ public class EmployeeRegistrationPreServiceImpl extends ServiceImpl<EmployeeRegi
||
!
CommonConstants
.
FOUR_STRING
.
equals
(
insurancePreVo
.
getModelType
()))
{
||
!
CommonConstants
.
FOUR_STRING
.
equals
(
insurancePreVo
.
getModelType
()))
{
checkVo
=
checkInsuranceExit
(
preVo
);
checkVo
=
checkInsuranceExit
(
preVo
);
if
(
null
!=
checkVo
)
{
if
(
null
!=
checkVo
)
{
errorList
.
add
(
checkVo
);
errorTemp
.
append
(
"保单开始日期:"
+
insurancePreVo
.
getPolicyStart
().
toString
()
+
",保单结束日期:"
+
insurancePreVo
.
getPolicyEnd
().
toString
()
+
"这条数据存在流程中/已完结的商险数据;"
);
// errorList.add(checkVo);
}
else
{
}
else
{
if
(
Common
.
isNotNull
(
preVo
.
getProcessStatus
()))
{
if
(
Common
.
isNotNull
(
preVo
.
getProcessStatus
()))
{
insurancePreVo
.
setProcessStatus
(
preVo
.
getProcessStatus
());
insurancePreVo
.
setProcessStatus
(
preVo
.
getProcessStatus
());
...
@@ -666,9 +672,9 @@ public class EmployeeRegistrationPreServiceImpl extends ServiceImpl<EmployeeRegi
...
@@ -666,9 +672,9 @@ public class EmployeeRegistrationPreServiceImpl extends ServiceImpl<EmployeeRegi
}
}
}
}
}
}
if
(!
errorList
.
isEmpty
())
{
//
if (!errorList.isEmpty()) {
return
R
.
other
(
CommonConstants
.
TWO_INT
,
null
,
errorList
);
//
return R.other(CommonConstants.TWO_INT, null, errorList);
}
//
}
// 2:商险待办 的判断:
// 2:商险待办 的判断:
if
(
oldList
!=
null
&&
!
oldList
.
isEmpty
())
{
if
(
oldList
!=
null
&&
!
oldList
.
isEmpty
())
{
...
@@ -684,7 +690,8 @@ public class EmployeeRegistrationPreServiceImpl extends ServiceImpl<EmployeeRegi
...
@@ -684,7 +690,8 @@ public class EmployeeRegistrationPreServiceImpl extends ServiceImpl<EmployeeRegi
&&
(
CommonConstants
.
ZERO_STRING
.
equals
(
oldInsurance
.
getProcessStatus
())
&&
(
CommonConstants
.
ZERO_STRING
.
equals
(
oldInsurance
.
getProcessStatus
())
||
CommonConstants
.
ONE_STRING
.
equals
(
oldInsurance
.
getProcessStatus
())
||
CommonConstants
.
ONE_STRING
.
equals
(
oldInsurance
.
getProcessStatus
())
||
CommonConstants
.
TWO_STRING
.
equals
(
oldInsurance
.
getProcessStatus
())))
{
||
CommonConstants
.
TWO_STRING
.
equals
(
oldInsurance
.
getProcessStatus
())))
{
return
R
.
failed
(
"不可变更项目,请检查商险配置!"
);
errorTemp
.
append
(
"不可变更项目,请检查商险配置;"
);
// return R.failed("不可变更项目,请检查商险配置!");
}
}
oldMap
.
put
(
oldInsurance
.
getId
(),
oldInsurance
);
oldMap
.
put
(
oldInsurance
.
getId
(),
oldInsurance
);
newPre
=
newMap
.
get
(
oldInsurance
.
getId
());
newPre
=
newMap
.
get
(
oldInsurance
.
getId
());
...
@@ -694,9 +701,11 @@ public class EmployeeRegistrationPreServiceImpl extends ServiceImpl<EmployeeRegi
...
@@ -694,9 +701,11 @@ public class EmployeeRegistrationPreServiceImpl extends ServiceImpl<EmployeeRegi
||
CommonConstants
.
FOUR_STRING
.
equals
(
oldInsurance
.
getProcessStatus
())
||
CommonConstants
.
FOUR_STRING
.
equals
(
oldInsurance
.
getProcessStatus
())
||
CommonConstants
.
SIX_STRING
.
equals
(
oldInsurance
.
getProcessStatus
())))
{
||
CommonConstants
.
SIX_STRING
.
equals
(
oldInsurance
.
getProcessStatus
())))
{
if
(
newPre
==
null
)
{
if
(
newPre
==
null
)
{
return
R
.
failed
(
"含有不可删除的商险,请刷新后再修改!"
);
errorTemp
.
append
(
"含有不可删除的商险,请刷新后再修改;"
);
// return R.failed("含有不可删除的商险,请刷新后再修改!");
}
else
if
(
Common
.
isNotNull
(
newPre
.
getModelType
())
&&
!
CommonConstants
.
FOUR_STRING
.
equals
(
newPre
.
getModelType
()))
{
}
else
if
(
Common
.
isNotNull
(
newPre
.
getModelType
())
&&
!
CommonConstants
.
FOUR_STRING
.
equals
(
newPre
.
getModelType
()))
{
return
R
.
failed
(
"含有不可更改的商险,请刷新后再修改!"
);
errorTemp
.
append
(
"含有不可更改的商险,请刷新后再修改;"
);
// return R.failed("含有不可更改的商险,请刷新后再修改!");
}
}
}
else
{
}
else
{
if
(
newPre
==
null
)
{
if
(
newPre
==
null
)
{
...
@@ -717,16 +726,15 @@ public class EmployeeRegistrationPreServiceImpl extends ServiceImpl<EmployeeRegi
...
@@ -717,16 +726,15 @@ public class EmployeeRegistrationPreServiceImpl extends ServiceImpl<EmployeeRegi
&&
(
CommonConstants
.
THREE_STRING
.
equals
(
oldInsurance
.
getProcessStatus
())
&&
(
CommonConstants
.
THREE_STRING
.
equals
(
oldInsurance
.
getProcessStatus
())
||
CommonConstants
.
FOUR_STRING
.
equals
(
oldInsurance
.
getProcessStatus
())
||
CommonConstants
.
FOUR_STRING
.
equals
(
oldInsurance
.
getProcessStatus
())
||
CommonConstants
.
SIX_STRING
.
equals
(
oldInsurance
.
getProcessStatus
())))
{
||
CommonConstants
.
SIX_STRING
.
equals
(
oldInsurance
.
getProcessStatus
())))
{
return
R
.
failed
(
"含有不可删除的商险,请刷新后再修改!"
);
errorTemp
.
append
(
"含有不可删除的商险,请刷新后再修改;"
);
// return R.failed("含有不可删除的商险,请刷新后再修改!");
}
}
}
}
}
}
}
}
//查询老的合同明细
//查询老的合同明细
TEmployeeContractPre
contractOld
=
contractPreMapper
.
selectOne
(
Wrappers
.<
TEmployeeContractPre
>
query
().
lambda
()
TEmployeeContractPre
contractOld
=
null
;
.
eq
(
TEmployeeContractPre:
:
getRegisterId
,
employeeRegistrationPre
.
getId
())
.
last
(
CommonConstants
.
LAST_ONE_SQL
));
//1.9.12合同自动化校验逻辑
//1.9.12合同自动化校验逻辑
//根据身份证号码和项目编号查询合同
//根据身份证号码和项目编号查询合同
boolean
flag
=
contractInfoMapper
.
selectCount
(
Wrappers
.<
TEmployeeContractInfo
>
query
().
lambda
()
boolean
flag
=
contractInfoMapper
.
selectCount
(
Wrappers
.<
TEmployeeContractInfo
>
query
().
lambda
()
...
@@ -739,37 +747,52 @@ public class EmployeeRegistrationPreServiceImpl extends ServiceImpl<EmployeeRegi
...
@@ -739,37 +747,52 @@ public class EmployeeRegistrationPreServiceImpl extends ServiceImpl<EmployeeRegi
)
)
.
eq
(
TEmployeeContractInfo:
:
getDeleteFlag
,
CommonConstants
.
ZERO_INT
)
.
eq
(
TEmployeeContractInfo:
:
getDeleteFlag
,
CommonConstants
.
ZERO_INT
)
.
last
(
CommonConstants
.
LAST_ONE_SQL
))
>
0
;
.
last
(
CommonConstants
.
LAST_ONE_SQL
))
>
0
;
if
(
employeeRegistrationPre
.
getServerItem
().
contains
(
"合同"
)
&&
Common
.
isEmpty
(
employeeRegistrationPre
.
getEmployeeContractPre
())
&&
!
flag
)
{
return
R
.
failed
(
"未找到流程中或者在用的合同!"
);
if
(
employeeRegistrationPre
.
getServerItem
().
contains
(
"合同"
)
}
&&
Common
.
isNotNull
(
employeeRegistrationPre
.
getContractUpdateFlag
())
if
(
employeeRegistrationPre
.
getServerItem
().
contains
(
"合同"
)
&&
null
!=
employeeRegistrationPre
.
getEmployeeContractPre
())
{
&&
employeeRegistrationPre
.
getContractUpdateFlag
())
{
TEmployeeContractPre
employeeContractPreVo
=
employeeRegistrationPre
.
getEmployeeContractPre
();
//查询老的合同明细
if
(
Common
.
isNotNull
(
employeeContractPreVo
.
getId
()))
{
contractOld
=
contractPreMapper
.
selectOne
(
Wrappers
.<
TEmployeeContractPre
>
query
().
lambda
()
TEmployeeContractPre
contractStatus
=
contractPreMapper
.
selectById
(
employeeContractPreVo
.
getId
());
.
eq
(
TEmployeeContractPre:
:
getRegisterId
,
employeeRegistrationPre
.
getId
())
//待确认/待发起/发起失败/线下签待审核/线下签审核不通过/线下签待归档 不能编辑
.
last
(
CommonConstants
.
LAST_ONE_SQL
));
if
(
Common
.
isNotNull
(
contractStatus
)
&&
(
CommonConstants
.
NINE_STRING
.
equals
(
contractStatus
.
getProcessStatus
())
||
CommonConstants
.
TWO_STRING
.
equals
(
contractStatus
.
getProcessStatus
())
if
(
Common
.
isEmpty
(
employeeRegistrationPre
.
getEmployeeContractPre
())
&&
!
flag
)
{
||
CommonConstants
.
SIX_STRING
.
equals
(
contractStatus
.
getProcessStatus
())
errorTemp
.
append
(
"未找到流程中或者在用的合同;"
);
||
CommonConstants
.
FOUR_STRING
.
equals
(
contractStatus
.
getProcessStatus
())
// return R.failed("未找到流程中或者在用的合同!");
||
CommonConstants
.
EIGHT_STRING
.
equals
(
contractStatus
.
getProcessStatus
()))
}
)
{
if
(
null
!=
employeeRegistrationPre
.
getEmployeeContractPre
())
{
return
R
.
failed
(
"流程中的合同待签订数据不可修改!"
);
TEmployeeContractPre
employeeContractPreVo
=
employeeRegistrationPre
.
getEmployeeContractPre
();
if
(
Common
.
isNotNull
(
employeeContractPreVo
.
getId
()))
{
TEmployeeContractPre
contractStatus
=
contractPreMapper
.
selectById
(
employeeContractPreVo
.
getId
());
//待确认/待发起/发起失败/线下签待审核/线下签审核不通过/线下签待归档 不能编辑
if
(
Common
.
isNotNull
(
contractStatus
)
&&
(
CommonConstants
.
NINE_STRING
.
equals
(
contractStatus
.
getProcessStatus
())
||
CommonConstants
.
TWO_STRING
.
equals
(
contractStatus
.
getProcessStatus
())
||
CommonConstants
.
SIX_STRING
.
equals
(
contractStatus
.
getProcessStatus
())
||
CommonConstants
.
FOUR_STRING
.
equals
(
contractStatus
.
getProcessStatus
())
||
CommonConstants
.
EIGHT_STRING
.
equals
(
contractStatus
.
getProcessStatus
()))
)
{
errorTemp
.
append
(
"流程中的合同待签订数据不可修改;"
);
// return R.failed("流程中的合同待签订数据不可修改!");
}
}
//是否已签署为否需要判断是否在用或者流程中的合同
if
((
CommonConstants
.
ONE_STRING
.
equals
(
employeeContractPreVo
.
getContractFlag
())
||
Common
.
isEmpty
(
employeeContractPreVo
.
getContractFlag
()))
&&
flag
)
{
errorTemp
.
append
(
"该人员已存在审核中或已签署的合同,请勿重复发起签署;"
);
// return R.failed("该人员已存在审核中或已签署的合同,请勿重复发起签署!");
}
if
(
CommonConstants
.
ONE_STRING
.
equals
(
employeeContractPreVo
.
getContractFlag
())
||
Common
.
isEmpty
(
employeeContractPreVo
.
getContractFlag
()))
{
initContractPreInfo
(
employeeRegistrationPre
,
employeeContractPreVo
,
user
,
id
);
employeeRegistrationPre
.
setEmployeeContractPre
(
employeeContractPreVo
);
}
else
{
employeeRegistrationPre
.
setEmployeeContractPre
(
null
);
}
}
}
//是否已签署为否需要判断是否在用或者流程中的合同
if
((
CommonConstants
.
ONE_STRING
.
equals
(
employeeContractPreVo
.
getContractFlag
())
||
Common
.
isEmpty
(
employeeContractPreVo
.
getContractFlag
()))
&&
flag
)
{
return
R
.
failed
(
"该人员已存在审核中或已签署的合同,请勿重复发起签署!"
);
}
if
(
CommonConstants
.
ONE_STRING
.
equals
(
employeeContractPreVo
.
getContractFlag
())
||
Common
.
isEmpty
(
employeeContractPreVo
.
getContractFlag
()))
{
initContractPreInfo
(
employeeRegistrationPre
,
employeeContractPreVo
,
user
,
id
);
employeeRegistrationPre
.
setEmployeeContractPre
(
employeeContractPreVo
);
}
else
{
employeeRegistrationPre
.
setEmployeeContractPre
(
null
);
}
}
}
}
//1.9.16社保自动化校验逻辑
//1.9.16社保自动化校验逻辑
if
(
employeeRegistrationPre
.
getServerItem
().
contains
(
"社保"
))
{
if
(
employeeRegistrationPre
.
getServerItem
().
contains
(
"社保"
)
&&
Common
.
isNotNull
(
employeeRegistrationPre
.
getSocialUpdateFlag
())
&&
employeeRegistrationPre
.
getSocialUpdateFlag
())
{
//根据身份证号码和项目编号查询合同
//根据身份证号码和项目编号查询合同
TEmployeeAutoRegistCheckVo
cardVo
=
new
TEmployeeAutoRegistCheckVo
();
TEmployeeAutoRegistCheckVo
cardVo
=
new
TEmployeeAutoRegistCheckVo
();
cardVo
.
setEmpIdcard
(
employeeRegistrationPre
.
getEmpIdcard
());
cardVo
.
setEmpIdcard
(
employeeRegistrationPre
.
getEmpIdcard
());
...
@@ -777,14 +800,16 @@ public class EmployeeRegistrationPreServiceImpl extends ServiceImpl<EmployeeRegi
...
@@ -777,14 +800,16 @@ public class EmployeeRegistrationPreServiceImpl extends ServiceImpl<EmployeeRegi
//是否已签署为是需要判断合同是否在用或者流程中
//是否已签署为是需要判断合同是否在用或者流程中
if
(
CommonConstants
.
ZERO_STRING
.
equals
(
employeeRegistrationPre
.
getSocialIsBuy
())
&&
if
(
CommonConstants
.
ZERO_STRING
.
equals
(
employeeRegistrationPre
.
getSocialIsBuy
())
&&
(
Common
.
isEmpty
(
socialFlag
)
||
Boolean
.
TRUE
.
equals
(!
socialFlag
.
getData
())))
{
(
Common
.
isEmpty
(
socialFlag
)
||
Boolean
.
TRUE
.
equals
(!
socialFlag
.
getData
())))
{
return
R
.
other
(
CommonConstants
.
TWO_INT
,
null
,
"未找到流程中或者在用的社保信息!"
);
errorTemp
.
append
(
"未找到流程中或者在用的社保信息;"
);
// return R.other(CommonConstants.TWO_INT, null, "未找到流程中或者在用的社保信息!");
}
}
//是否已签署为否需要判断是否在用或者流程中的合同
//是否已签署为否需要判断是否在用或者流程中的合同
if
(
CommonConstants
.
ONE_STRING
.
equals
(
employeeRegistrationPre
.
getSocialIsBuy
())
&&
if
(
CommonConstants
.
ONE_STRING
.
equals
(
employeeRegistrationPre
.
getSocialIsBuy
())
&&
Common
.
isNotNull
(
socialFlag
)
&&
Boolean
.
TRUE
.
equals
(
socialFlag
.
getData
())
&&
Common
.
isNotNull
(
socialFlag
)
&&
Boolean
.
TRUE
.
equals
(
socialFlag
.
getData
())
&&
null
!=
employeeRegistrationPre
.
getDispatchInfoPreVo
()
&&
null
!=
employeeRegistrationPre
.
getDispatchInfoPreVo
()
&&
Common
.
isEmpty
(
employeeRegistrationPre
.
getDispatchInfoPreVo
().
getId
()))
{
Common
.
isEmpty
(
employeeRegistrationPre
.
getDispatchInfoPreVo
().
getId
()))
{
return
R
.
other
(
CommonConstants
.
TWO_INT
,
null
,
"该人员存在在途/有效的社保数据,请将“是否已参保”调整为“是”"
);
errorTemp
.
append
(
"该人员存在在途/有效的社保数据,请将【是否已参保】调整为【是】;"
);
// return R.other(CommonConstants.TWO_INT, null, "该人员存在在途/有效的社保数据,请将“是否已参保”调整为“是”");
}
}
//流程中的社保数据不能修改
//流程中的社保数据不能修改
//查已购买社保明细
//查已购买社保明细
...
@@ -798,7 +823,8 @@ public class EmployeeRegistrationPreServiceImpl extends ServiceImpl<EmployeeRegi
...
@@ -798,7 +823,8 @@ public class EmployeeRegistrationPreServiceImpl extends ServiceImpl<EmployeeRegi
socialSdr
.
getData
().
getDispatchInfoPreVo
().
getProcessStatus
().
equals
(
CommonConstants
.
SIX_STRING
)
||
socialSdr
.
getData
().
getDispatchInfoPreVo
().
getProcessStatus
().
equals
(
CommonConstants
.
SIX_STRING
)
||
socialSdr
.
getData
().
getDispatchInfoPreVo
().
getProcessStatus
().
equals
(
CommonConstants
.
SEVEN_STRING
)
||
socialSdr
.
getData
().
getDispatchInfoPreVo
().
getProcessStatus
().
equals
(
CommonConstants
.
SEVEN_STRING
)
||
socialSdr
.
getData
().
getDispatchInfoPreVo
().
getProcessStatus
().
equals
(
CommonConstants
.
NINE_STRING
)))
{
socialSdr
.
getData
().
getDispatchInfoPreVo
().
getProcessStatus
().
equals
(
CommonConstants
.
NINE_STRING
)))
{
return
R
.
failed
(
"流程中的社保待购买数据不可修改!"
);
errorTemp
.
append
(
"流程中的社保待购买数据不可修改;"
);
// return R.failed("流程中的社保待购买数据不可修改!");
}
}
}
}
//更新合同签署状态
//更新合同签署状态
...
@@ -808,25 +834,28 @@ public class EmployeeRegistrationPreServiceImpl extends ServiceImpl<EmployeeRegi
...
@@ -808,25 +834,28 @@ public class EmployeeRegistrationPreServiceImpl extends ServiceImpl<EmployeeRegi
}
}
//1.9.17公积金自动化校验逻辑
//1.9.17公积金自动化校验逻辑
if
(
employeeRegistrationPre
.
getServerItem
().
contains
(
"公积金"
))
{
if
(
employeeRegistrationPre
.
getServerItem
().
contains
(
"公积金"
)
&&
Common
.
isNotNull
(
employeeRegistrationPre
.
getFundUpdateFlag
())
&&
employeeRegistrationPre
.
getFundUpdateFlag
())
{
//根据身份证号码和项目编号查询公积金
//根据身份证号码和项目编号查询公积金
TEmployeeAutoRegistCheckVo
cardVo
=
new
TEmployeeAutoRegistCheckVo
();
TEmployeeAutoRegistCheckVo
cardVo
=
new
TEmployeeAutoRegistCheckVo
();
cardVo
.
setEmpIdcard
(
employeeRegistrationPre
.
getEmpIdcard
());
cardVo
.
setEmpIdcard
(
employeeRegistrationPre
.
getEmpIdcard
());
R
<
Boolean
>
fundFlag
=
socialDaprUtils
.
selectExitEmpFund
(
cardVo
);
R
<
Boolean
>
fundFlag
=
socialDaprUtils
.
selectExitEmpFund
(
cardVo
);
if
(
null
!=
employeeRegistrationPre
.
getFundUpdateFlag
()
&&
employeeRegistrationPre
.
getFundUpdateFlag
().
booleanValue
()){
//是否已购买为是需要判断公积金是否在用或者流程中
//是否已购买为是需要判断公积金是否在用或者流程中
if
(
CommonConstants
.
ZERO_STRING
.
equals
(
employeeRegistrationPre
.
getFundIsBuy
())
&&
if
(
CommonConstants
.
ZERO_STRING
.
equals
(
employeeRegistrationPre
.
getFundIsBuy
())
&&
(
Common
.
isEmpty
(
fundFlag
)
||
Boolean
.
TRUE
.
equals
(!
fundFlag
.
getData
())))
{
(
Common
.
isEmpty
(
fundFlag
)
||
Boolean
.
TRUE
.
equals
(!
fundFlag
.
getData
())))
{
errorTemp
.
append
(
"未找到流程中或者在用的公积金信息;"
);
return
R
.
other
(
CommonConstants
.
TWO_INT
,
null
,
"未找到流程中或者在用的公积金信息!"
);
//
return R.other(CommonConstants.TWO_INT, null, "未找到流程中或者在用的公积金信息!");
}
}
//是否已购买为否需要判断是否在用或者流程中的公积金
//是否已购买为否需要判断是否在用或者流程中的公积金
if
(
CommonConstants
.
ONE_STRING
.
equals
(
employeeRegistrationPre
.
getFundIsBuy
())
&&
if
(
CommonConstants
.
ONE_STRING
.
equals
(
employeeRegistrationPre
.
getFundIsBuy
())
&&
Common
.
isNotNull
(
fundFlag
)
&&
Boolean
.
TRUE
.
equals
(
fundFlag
.
getData
())
&&
Common
.
isNotNull
(
fundFlag
)
&&
Boolean
.
TRUE
.
equals
(
fundFlag
.
getData
())
&&
null
!=
employeeRegistrationPre
.
getDispatchInfoFundPreVo
())
{
null
!=
employeeRegistrationPre
.
getDispatchInfoFundPreVo
())
{
return
R
.
other
(
CommonConstants
.
TWO_INT
,
null
,
"该人员存在在途/有效的公积金数据,请将“是否已参保”调整为“是”
"
);
errorTemp
.
append
(
"该人员存在在途/有效的公积金数据,请将【是否已参保】调整为【是】;
"
);
}
// return R.other(CommonConstants.TWO_INT, null, "该人员存在在途/有效的公积金数据,请将“是否已参保”调整为“是”");
}
}
//判断公积金基数 是否小于 公积金户配置的最低基数
//判断公积金基数 是否小于 公积金户配置的最低基数
/*if (Common.isNotNull(employeeRegistrationPre)
/*if (Common.isNotNull(employeeRegistrationPre)
&& Common.isNotNull(employeeRegistrationPre.getDispatchInfoFundPreVo())
&& Common.isNotNull(employeeRegistrationPre.getDispatchInfoFundPreVo())
...
@@ -846,14 +875,13 @@ public class EmployeeRegistrationPreServiceImpl extends ServiceImpl<EmployeeRegi
...
@@ -846,14 +875,13 @@ public class EmployeeRegistrationPreServiceImpl extends ServiceImpl<EmployeeRegi
//(公积金待办为在途在保)流程中的公积金数据不能修改
//(公积金待办为在途在保)流程中的公积金数据不能修改
//查已购买公积金明细
//查已购买公积金明细
if
(
null
!=
employeeRegistrationPre
.
getDispatchInfoFundPreVo
()
if
(
null
!=
employeeRegistrationPre
.
getDispatchInfoFundPreVo
()
&&
!
Common
.
isEmpty
(
employeeRegistrationPre
.
getDispatchInfoFundPreVo
().
getId
())
&&
!
Common
.
isEmpty
(
employeeRegistrationPre
.
getDispatchInfoFundPreVo
().
getId
()))
{
&&
null
!=
employeeRegistrationPre
.
getFundUpdateFlag
()
&&
employeeRegistrationPre
.
getFundUpdateFlag
().
booleanValue
())
{
R
<
Boolean
>
fundSdr
=
socialDaprUtils
.
getFundPreStatus
(
employeeRegistrationPre
.
getDispatchInfoFundPreVo
().
getId
());
R
<
Boolean
>
fundSdr
=
socialDaprUtils
.
getFundPreStatus
(
employeeRegistrationPre
.
getDispatchInfoFundPreVo
().
getId
());
//公积金购买状态,0待确认,1待派单,2派单失败,3待审核,4审核不通过,5待办理,7办理成功,8办理失败
//公积金购买状态,0待确认,1待派单,2派单失败,3待审核,4审核不通过,5待办理,7办理成功,8办理失败
if
(
fundSdr
!=
null
&&
null
!=
fundSdr
.
getData
()
if
(
fundSdr
!=
null
&&
null
!=
fundSdr
.
getData
()
&&
fundSdr
.
getData
().
booleanValue
())
{
&&
fundSdr
.
getData
().
booleanValue
())
{
return
R
.
failed
(
"流程中的公积金待购买数据不可修改!"
);
errorTemp
.
append
(
"流程中的公积金待购买数据不可修改;"
);
// return R.failed("流程中的公积金待购买数据不可修改!");
}
}
}
}
//更新合同签署状态
//更新合同签署状态
...
@@ -862,6 +890,11 @@ public class EmployeeRegistrationPreServiceImpl extends ServiceImpl<EmployeeRegi
...
@@ -862,6 +890,11 @@ public class EmployeeRegistrationPreServiceImpl extends ServiceImpl<EmployeeRegi
}
}
}
}
//错误信息全量返回
if
(
errorTemp
.
length
()
>
0
)
{
return
R
.
other
(
CommonConstants
.
TWO_INT
,
null
,
errorTemp
.
toString
());
}
//操作记录中字典值的转化
//操作记录中字典值的转化
String
natureItemBefore
=
null
;
String
natureItemBefore
=
null
;
String
natureItemAfter
=
null
;
String
natureItemAfter
=
null
;
...
...
yifu-archives/yifu-archives-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/archives/service/impl/TEmployeePreLogServiceImpl.java
View file @
b2476458
...
@@ -174,6 +174,8 @@ public class TEmployeePreLogServiceImpl extends ServiceImpl<TEmployeePreLogMappe
...
@@ -174,6 +174,8 @@ public class TEmployeePreLogServiceImpl extends ServiceImpl<TEmployeePreLogMappe
IGNORE_FIELD
.
add
(
"updateBy"
);
IGNORE_FIELD
.
add
(
"updateBy"
);
IGNORE_FIELD
.
add
(
"isAddress"
);
IGNORE_FIELD
.
add
(
"isAddress"
);
IGNORE_FIELD
.
add
(
"fundUpdateFlag"
);
IGNORE_FIELD
.
add
(
"fundUpdateFlag"
);
IGNORE_FIELD
.
add
(
"socialUpdateFlag"
);
IGNORE_FIELD
.
add
(
"contractUpdateFlag"
);
}
}
private
static
final
List
<
String
>
PRE_IGNORE_FIELD
=
new
ArrayList
<>();
private
static
final
List
<
String
>
PRE_IGNORE_FIELD
=
new
ArrayList
<>();
...
@@ -185,6 +187,8 @@ public class TEmployeePreLogServiceImpl extends ServiceImpl<TEmployeePreLogMappe
...
@@ -185,6 +187,8 @@ public class TEmployeePreLogServiceImpl extends ServiceImpl<TEmployeePreLogMappe
PRE_IGNORE_FIELD
.
add
(
"createName"
);
PRE_IGNORE_FIELD
.
add
(
"createName"
);
PRE_IGNORE_FIELD
.
add
(
"updateBy"
);
PRE_IGNORE_FIELD
.
add
(
"updateBy"
);
PRE_IGNORE_FIELD
.
add
(
"fundUpdateFlag"
);
PRE_IGNORE_FIELD
.
add
(
"fundUpdateFlag"
);
PRE_IGNORE_FIELD
.
add
(
"socialUpdateFlag"
);
PRE_IGNORE_FIELD
.
add
(
"contractUpdateFlag"
);
}
}
private
static
final
List
<
String
>
CONTRACT_IGNORE_FIELD
=
new
ArrayList
<>();
private
static
final
List
<
String
>
CONTRACT_IGNORE_FIELD
=
new
ArrayList
<>();
...
@@ -464,7 +468,8 @@ public class TEmployeePreLogServiceImpl extends ServiceImpl<TEmployeePreLogMappe
...
@@ -464,7 +468,8 @@ public class TEmployeePreLogServiceImpl extends ServiceImpl<TEmployeePreLogMappe
}
}
String
differenceSocialKey
;
String
differenceSocialKey
;
if
(
newInfo
.
getServerItem
().
contains
(
"社保"
)
&&
(
Common
.
isEmpty
(
isSocailBuyOld
)
||
if
(
newInfo
.
getServerItem
().
contains
(
"社保"
)
&&
null
!=
newInfo
.
getSocialUpdateFlag
()
&&
newInfo
.
getSocialUpdateFlag
()
&&
(
Common
.
isEmpty
(
isSocailBuyOld
)
||
(
Common
.
isNotNull
(
isSocailBuyOld
)
&&
!
isSocailBuyOld
.
equals
(
isSocailBuyNew
))))
{
(
Common
.
isNotNull
(
isSocailBuyOld
)
&&
!
isSocailBuyOld
.
equals
(
isSocailBuyNew
))))
{
//单独记录是否已购买社保的变更记录
//单独记录是否已购买社保的变更记录
differenceSocialKey
=
"socialIsBuy"
;
differenceSocialKey
=
"socialIsBuy"
;
...
@@ -511,7 +516,8 @@ public class TEmployeePreLogServiceImpl extends ServiceImpl<TEmployeePreLogMappe
...
@@ -511,7 +516,8 @@ public class TEmployeePreLogServiceImpl extends ServiceImpl<TEmployeePreLogMappe
}
}
}
}
if
(
newInfo
.
getServerItem
().
contains
(
"社保"
)
&&
dispatchInfoPreOldVo
!=
null
&&
dispatchInfoPreVo
!=
null
)
{
if
(
newInfo
.
getServerItem
().
contains
(
"社保"
)&&
null
!=
newInfo
.
getSocialUpdateFlag
()
&&
newInfo
.
getSocialUpdateFlag
()
&&
dispatchInfoPreOldVo
!=
null
&&
dispatchInfoPreVo
!=
null
)
{
differenceSocialKey
=
HrEquator
.
comparisonValueIgnoreField
(
dispatchInfoPreOldVo
differenceSocialKey
=
HrEquator
.
comparisonValueIgnoreField
(
dispatchInfoPreOldVo
,
dispatchInfoPreVo
,
SOCIAL_IGNORE_FIELD
);
,
dispatchInfoPreVo
,
SOCIAL_IGNORE_FIELD
);
if
(
differenceSocialKey
.
length
()
>
0
)
{
if
(
differenceSocialKey
.
length
()
>
0
)
{
...
@@ -531,7 +537,8 @@ public class TEmployeePreLogServiceImpl extends ServiceImpl<TEmployeePreLogMappe
...
@@ -531,7 +537,8 @@ public class TEmployeePreLogServiceImpl extends ServiceImpl<TEmployeePreLogMappe
// 公积金处理逻辑
// 公积金处理逻辑
String
differenceFundKey
;
String
differenceFundKey
;
if
(
newInfo
.
getServerItem
().
contains
(
"公积金"
)
&&
(
Common
.
isEmpty
(
isFundBuyOld
)
||
if
(
newInfo
.
getServerItem
().
contains
(
"公积金"
)
&&
null
!=
newInfo
.
getFundUpdateFlag
()
&&
newInfo
.
getFundUpdateFlag
()
&&
(
Common
.
isEmpty
(
isFundBuyOld
)
||
(
Common
.
isNotNull
(
isFundBuyOld
)
&&
!
isFundBuyOld
.
equals
(
isFundBuyNew
))))
{
(
Common
.
isNotNull
(
isFundBuyOld
)
&&
!
isFundBuyOld
.
equals
(
isFundBuyNew
))))
{
//单独记录是否已购买公积金的变更记录
//单独记录是否已购买公积金的变更记录
differenceFundKey
=
"fundIsBuy"
;
differenceFundKey
=
"fundIsBuy"
;
...
@@ -578,18 +585,15 @@ public class TEmployeePreLogServiceImpl extends ServiceImpl<TEmployeePreLogMappe
...
@@ -578,18 +585,15 @@ public class TEmployeePreLogServiceImpl extends ServiceImpl<TEmployeePreLogMappe
}
}
}
}
if
(
newInfo
.
getServerItem
().
contains
(
"公积金"
)
&&
dispatchInfoFundPreOldVo
!=
null
&&
dispatchInfoFundPreVo
!=
null
)
{
if
(
newInfo
.
getServerItem
().
contains
(
"公积金"
)
&&
null
!=
newInfo
.
getFundUpdateFlag
()
&&
newInfo
.
getFundUpdateFlag
()
&&
dispatchInfoFundPreOldVo
!=
null
&&
dispatchInfoFundPreVo
!=
null
)
{
Date
expectedCollectionTime
=
dispatchInfoFundPreVo
.
getExpectedCollectionTime
();
Date
expectedCollectionTime
=
dispatchInfoFundPreVo
.
getExpectedCollectionTime
();
Date
expectedConfirmTime
=
dispatchInfoFundPreVo
.
getExpectedConfirmTime
();
Date
expectedConfirmTime
=
dispatchInfoFundPreVo
.
getExpectedConfirmTime
();
//如果自动触发派增为是,计算派单发起时间和派单确认时间
//如果自动触发派增为是,计算派单发起时间和派单确认时间
initFundTime
(
dispatchInfoFundPreVo
);
initFundTime
(
dispatchInfoFundPreVo
);
differenceFundKey
=
HrEquator
.
comparisonValueIgnoreField
(
dispatchInfoFundPreOldVo
differenceFundKey
=
HrEquator
.
comparisonValueIgnoreField
(
dispatchInfoFundPreOldVo
,
dispatchInfoFundPreVo
,
SOCIAL_IGNORE_FIELD
);
,
dispatchInfoFundPreVo
,
SOCIAL_IGNORE_FIELD
);
//如果为不修改直接清空差异
if
(
null
!=
newInfo
.
getFundUpdateFlag
()
&&
!
newInfo
.
getFundUpdateFlag
().
booleanValue
()){
differenceFundKey
=
""
;
}
if
(
differenceFundKey
.
length
()
>
0
)
{
if
(
differenceFundKey
.
length
()
>
0
)
{
if
(
Common
.
isNotNull
(
diffTitle
))
{
if
(
Common
.
isNotNull
(
diffTitle
))
{
diffTitle
+=
"、公积金信息"
;
diffTitle
+=
"、公积金信息"
;
...
@@ -636,7 +640,8 @@ public class TEmployeePreLogServiceImpl extends ServiceImpl<TEmployeePreLogMappe
...
@@ -636,7 +640,8 @@ public class TEmployeePreLogServiceImpl extends ServiceImpl<TEmployeePreLogMappe
contractPreService
.
saveContractPreInfo
(
preVo
);
contractPreService
.
saveContractPreInfo
(
preVo
);
}
}
//社保待购买数据处理
//社保待购买数据处理
if
(
newInfo
.
getServerItem
().
contains
(
"社保"
))
{
if
(
newInfo
.
getServerItem
().
contains
(
"社保"
)
&&
null
!=
newInfo
.
getSocialUpdateFlag
()
&&
newInfo
.
getSocialUpdateFlag
())
{
EmployeeRegistrationPreVo
preVo
=
new
EmployeeRegistrationPreVo
();
EmployeeRegistrationPreVo
preVo
=
new
EmployeeRegistrationPreVo
();
BeanUtils
.
copyProperties
(
newInfo
,
preVo
);
BeanUtils
.
copyProperties
(
newInfo
,
preVo
);
if
(
null
!=
preVo
.
getExitSocialInfoList
()
&&
!
preVo
.
getExitSocialInfoList
().
isEmpty
())
{
if
(
null
!=
preVo
.
getExitSocialInfoList
()
&&
!
preVo
.
getExitSocialInfoList
().
isEmpty
())
{
...
@@ -647,7 +652,8 @@ public class TEmployeePreLogServiceImpl extends ServiceImpl<TEmployeePreLogMappe
...
@@ -647,7 +652,8 @@ public class TEmployeePreLogServiceImpl extends ServiceImpl<TEmployeePreLogMappe
socialDaprUtils
.
saveSocialPreInfo
(
preVo
);
socialDaprUtils
.
saveSocialPreInfo
(
preVo
);
}
}
//公积金待购买数据处理
//公积金待购买数据处理
if
(
newInfo
.
getServerItem
().
contains
(
"公积金"
))
{
if
(
newInfo
.
getServerItem
().
contains
(
"公积金"
)
&&
null
!=
newInfo
.
getFundUpdateFlag
()
&&
newInfo
.
getFundUpdateFlag
()
)
{
EmployeeRegistrationPreVo
preVo
=
new
EmployeeRegistrationPreVo
();
EmployeeRegistrationPreVo
preVo
=
new
EmployeeRegistrationPreVo
();
BeanUtils
.
copyProperties
(
newInfo
,
preVo
);
BeanUtils
.
copyProperties
(
newInfo
,
preVo
);
if
(
null
!=
preVo
.
getExitFundInfoList
()
&&
!
preVo
.
getExitFundInfoList
().
isEmpty
())
{
if
(
null
!=
preVo
.
getExitFundInfoList
()
&&
!
preVo
.
getExitFundInfoList
().
isEmpty
())
{
...
...
yifu-batch/yifu-batch-biz/src/main/java/com/yifu/cloud/plus/v1/batch/controller/TElectronicArchiveDetailController.java
View file @
b2476458
...
@@ -9,6 +9,9 @@ import com.yifu.cloud.plus.v1.batch.vo.ArchiveBatchDownloadRequestVO;
...
@@ -9,6 +9,9 @@ import com.yifu.cloud.plus.v1.batch.vo.ArchiveBatchDownloadRequestVO;
import
com.yifu.cloud.plus.v1.batch.vo.ArchiveSelectedExportRequestVO
;
import
com.yifu.cloud.plus.v1.batch.vo.ArchiveSelectedExportRequestVO
;
import
com.yifu.cloud.plus.v1.batch.vo.TElectronicArchiveDetailSearchVo
;
import
com.yifu.cloud.plus.v1.batch.vo.TElectronicArchiveDetailSearchVo
;
import
com.yifu.cloud.plus.v1.yifu.common.core.util.R
;
import
com.yifu.cloud.plus.v1.yifu.common.core.util.R
;
import
com.yifu.cloud.plus.v1.yifu.common.core.vo.YifuUser
;
import
com.yifu.cloud.plus.v1.yifu.common.dapr.util.MenuUtil
;
import
com.yifu.cloud.plus.v1.yifu.common.security.util.SecurityUtils
;
import
io.swagger.v3.oas.annotations.Operation
;
import
io.swagger.v3.oas.annotations.Operation
;
import
io.swagger.v3.oas.annotations.tags.Tag
;
import
io.swagger.v3.oas.annotations.tags.Tag
;
import
lombok.RequiredArgsConstructor
;
import
lombok.RequiredArgsConstructor
;
...
@@ -32,6 +35,8 @@ public class TElectronicArchiveDetailController {
...
@@ -32,6 +35,8 @@ public class TElectronicArchiveDetailController {
private
final
TElectronicArchiveDetailService
tElectronicArchiveDetailService
;
private
final
TElectronicArchiveDetailService
tElectronicArchiveDetailService
;
private
final
MenuUtil
menuUtil
;
/**
/**
* 简单分页查询
* 简单分页查询
*
*
...
@@ -43,6 +48,8 @@ public class TElectronicArchiveDetailController {
...
@@ -43,6 +48,8 @@ public class TElectronicArchiveDetailController {
@GetMapping
(
"/page"
)
@GetMapping
(
"/page"
)
public
R
<
IPage
<
TElectronicArchiveDetail
>>
getTElectronicArchiveDetailPage
(
Page
<
TElectronicArchiveDetail
>
page
public
R
<
IPage
<
TElectronicArchiveDetail
>>
getTElectronicArchiveDetailPage
(
Page
<
TElectronicArchiveDetail
>
page
,
TElectronicArchiveDetailSearchVo
tElectronicArchiveDetail
)
{
,
TElectronicArchiveDetailSearchVo
tElectronicArchiveDetail
)
{
YifuUser
user
=
SecurityUtils
.
getUser
();
menuUtil
.
setAuthSql
(
user
,
tElectronicArchiveDetail
);
return
new
R
<>(
tElectronicArchiveDetailService
.
getTElectronicArchiveDetailPage
(
page
,
tElectronicArchiveDetail
));
return
new
R
<>(
tElectronicArchiveDetailService
.
getTElectronicArchiveDetailPage
(
page
,
tElectronicArchiveDetail
));
}
}
...
...
yifu-batch/yifu-batch-biz/src/main/java/com/yifu/cloud/plus/v1/batch/service/impl/ElectronicArchiveImportServiceImpl.java
View file @
b2476458
...
@@ -19,6 +19,7 @@ import com.yifu.cloud.plus.v1.batch.vo.ArchiveFeedbackVO;
...
@@ -19,6 +19,7 @@ import com.yifu.cloud.plus.v1.batch.vo.ArchiveFeedbackVO;
import
com.yifu.cloud.plus.v1.batch.vo.ArchiveImportVO
;
import
com.yifu.cloud.plus.v1.batch.vo.ArchiveImportVO
;
import
com.yifu.cloud.plus.v1.yifu.archives.entity.TEmployeeInfo
;
import
com.yifu.cloud.plus.v1.yifu.archives.entity.TEmployeeInfo
;
import
com.yifu.cloud.plus.v1.yifu.archives.vo.IdNameNoVo
;
import
com.yifu.cloud.plus.v1.yifu.archives.vo.IdNameNoVo
;
import
com.yifu.cloud.plus.v1.yifu.archives.vo.TSettleDomainListVo
;
import
com.yifu.cloud.plus.v1.yifu.archives.vo.TSettleDomainSelectVo
;
import
com.yifu.cloud.plus.v1.yifu.archives.vo.TSettleDomainSelectVo
;
import
com.yifu.cloud.plus.v1.yifu.common.core.constant.CacheConstants
;
import
com.yifu.cloud.plus.v1.yifu.common.core.constant.CacheConstants
;
import
com.yifu.cloud.plus.v1.yifu.common.core.constant.CommonConstants
;
import
com.yifu.cloud.plus.v1.yifu.common.core.constant.CommonConstants
;
...
@@ -26,6 +27,7 @@ import com.yifu.cloud.plus.v1.yifu.common.core.util.*;
...
@@ -26,6 +27,7 @@ import com.yifu.cloud.plus.v1.yifu.common.core.util.*;
import
com.yifu.cloud.plus.v1.yifu.common.core.vo.YifuUser
;
import
com.yifu.cloud.plus.v1.yifu.common.core.vo.YifuUser
;
import
com.yifu.cloud.plus.v1.yifu.common.dapr.util.ArchivesDaprUtil
;
import
com.yifu.cloud.plus.v1.yifu.common.dapr.util.ArchivesDaprUtil
;
import
com.yifu.cloud.plus.v1.yifu.common.security.util.SecurityUtils
;
import
com.yifu.cloud.plus.v1.yifu.common.security.util.SecurityUtils
;
import
com.yifu.cloud.plus.v1.yifu.insurances.constants.InsurancesConstants
;
import
lombok.RequiredArgsConstructor
;
import
lombok.RequiredArgsConstructor
;
import
lombok.extern.log4j.Log4j2
;
import
lombok.extern.log4j.Log4j2
;
import
org.springframework.cache.Cache
;
import
org.springframework.cache.Cache
;
...
@@ -157,8 +159,22 @@ public class ElectronicArchiveImportServiceImpl implements ElectronicArchiveImpo
...
@@ -157,8 +159,22 @@ public class ElectronicArchiveImportServiceImpl implements ElectronicArchiveImpo
TSettleDomainSelectVo
settleResult
;
TSettleDomainSelectVo
settleResult
;
R
<
TEmployeeInfo
>
empResult
;
R
<
TEmployeeInfo
>
empResult
;
Map
<
String
,
String
>
map
=
new
HashMap
<>();
Map
<
String
,
String
>
map
=
new
HashMap
<>();
List
<
String
>
deptNoList
=
new
ArrayList
<>();
if
(
Common
.
isNotNull
(
user
)
&&
!
CommonConstants
.
ZERO_STRING
.
equals
(
user
.
getSystemFlag
()))
{
deptNoList
=
getDeptNoList
(
user
.
getId
());
}
for
(
ArchiveImportVO
data
:
dataList
)
{
for
(
ArchiveImportVO
data
:
dataList
)
{
try
{
try
{
//超管和档案管理员无需校验项目权限
if
(
Common
.
isNotNull
(
user
)
&&
!
CommonConstants
.
ZERO_STRING
.
equals
(
user
.
getSystemFlag
()))
{
if
(
Common
.
isEmpty
(
deptNoList
))
{
ErrorMessage
<
ArchiveImportVO
>
errorMessage
=
new
ErrorMessage
<>(
data
.
getRowIndex
()
,
InsurancesConstants
.
DEPT_NO_NOT_IN_USER_DEPT_LIST
,
data
);
errorMessageList
.
add
(
errorMessage
);
continue
;
}
}
// 1. 校验表格中一个姓名、身份证只能有一条
// 1. 校验表格中一个姓名、身份证只能有一条
String
uniqueKey
=
data
.
getEmpIdcard
()
+
"_"
+
data
.
getEmpName
()
+
"_"
+
data
.
getDeptNo
();
String
uniqueKey
=
data
.
getEmpIdcard
()
+
"_"
+
data
.
getEmpName
()
+
"_"
+
data
.
getDeptNo
();
if
(
null
!=
map
.
get
(
uniqueKey
))
{
if
(
null
!=
map
.
get
(
uniqueKey
))
{
...
@@ -243,7 +259,30 @@ public class ElectronicArchiveImportServiceImpl implements ElectronicArchiveImpo
...
@@ -243,7 +259,30 @@ public class ElectronicArchiveImportServiceImpl implements ElectronicArchiveImpo
log
.
error
(
"保存任务表附件失败"
,
e
);
log
.
error
(
"保存任务表附件失败"
,
e
);
}
}
}
}
/**
* 获取项目权限
*
* @author huych
* @param userId
* @return {@link List< String>}
*/
public
List
<
String
>
getDeptNoList
(
String
userId
){
List
<
String
>
deptList
=
new
ArrayList
<>(
16
);
try
{
R
<
TSettleDomainListVo
>
settleDomainList
=
archivesDaprUtil
.
getSettleDomainIdsByUserId
(
userId
);
if
(
Common
.
isNotNull
(
settleDomainList
)
&&
settleDomainList
.
getCode
()
==
CommonConstants
.
SUCCESS
){
TSettleDomainListVo
data
=
settleDomainList
.
getData
();
if
(
Optional
.
ofNullable
(
data
).
isPresent
()){
deptList
=
data
.
getDeptNos
();
}
}
}
catch
(
Exception
e
){
log
.
error
(
"查询项目信息出错:"
+
e
);
}
return
deptList
;
}
/**
/**
* 建立任务和档案详情的关联关系
* 建立任务和档案详情的关联关系
*/
*/
...
@@ -619,6 +658,17 @@ public class ElectronicArchiveImportServiceImpl implements ElectronicArchiveImpo
...
@@ -619,6 +658,17 @@ public class ElectronicArchiveImportServiceImpl implements ElectronicArchiveImpo
if
(
subFile
.
isDirectory
())
{
if
(
subFile
.
isDirectory
())
{
// 是资料类型目录
// 是资料类型目录
String
materialType
=
subFile
.
getName
();
String
materialType
=
subFile
.
getName
();
//存量、新签、续签、离职
if
(
materialType
.
contains
(
"存量"
))
{
materialType
=
"存量"
;
}
else
if
(
materialType
.
contains
(
"新签"
))
{
materialType
=
"新签"
;
}
else
if
(
materialType
.
contains
(
"续签"
))
{
materialType
=
"续签"
;
}
else
if
(
materialType
.
contains
(
"离职"
))
{
materialType
=
"离职"
;
}
if
(!
isValidMaterialType
(
materialType
))
{
if
(!
isValidMaterialType
(
materialType
))
{
// 不是有效的资料类型,跳过
// 不是有效的资料类型,跳过
continue
;
continue
;
...
@@ -672,8 +722,6 @@ public class ElectronicArchiveImportServiceImpl implements ElectronicArchiveImpo
...
@@ -672,8 +722,6 @@ public class ElectronicArchiveImportServiceImpl implements ElectronicArchiveImpo
String
fileName
=
file
.
getName
();
String
fileName
=
file
.
getName
();
long
fileSize
=
file
.
length
();
long
fileSize
=
file
.
length
();
log
.
info
(
"处理文件:{},大小:{},电子档案详情ID:{}"
,
fileName
,
fileSize
,
detail
.
getId
());
// 1. 校验文件大小
// 1. 校验文件大小
if
(
fileSize
>
ArchiveConstants
.
SINGLE_FILE_MAX_SIZE
)
{
if
(
fileSize
>
ArchiveConstants
.
SINGLE_FILE_MAX_SIZE
)
{
ArchiveFeedbackVO
feedback
=
createFeedbackVO
(
detail
,
materialType
,
ArchiveFeedbackVO
feedback
=
createFeedbackVO
(
detail
,
materialType
,
...
@@ -723,7 +771,6 @@ public class ElectronicArchiveImportServiceImpl implements ElectronicArchiveImpo
...
@@ -723,7 +771,6 @@ public class ElectronicArchiveImportServiceImpl implements ElectronicArchiveImpo
// 上传成功,记录附件信息
// 上传成功,记录附件信息
TAttaInfo
attaInfo
=
uploadResult
.
getData
();
TAttaInfo
attaInfo
=
uploadResult
.
getData
();
log
.
info
(
"文件上传成功:{},附件ID:{},domainId:{}"
,
fileName
,
attaInfo
.
getId
(),
attaInfo
.
getDomainId
());
// 记录该人员的资料类型
// 记录该人员的资料类型
materialTypes
.
add
(
materialType
);
materialTypes
.
add
(
materialType
);
...
...
yifu-batch/yifu-batch-biz/src/main/java/com/yifu/cloud/plus/v1/batch/service/impl/TElectronicArchiveDetailServiceImpl.java
View file @
b2476458
...
@@ -19,11 +19,15 @@ import com.yifu.cloud.plus.v1.batch.service.TElectronicArchiveDetailService;
...
@@ -19,11 +19,15 @@ import com.yifu.cloud.plus.v1.batch.service.TElectronicArchiveDetailService;
import
com.yifu.cloud.plus.v1.batch.service.TElectronicArchiveTaskService
;
import
com.yifu.cloud.plus.v1.batch.service.TElectronicArchiveTaskService
;
import
com.yifu.cloud.plus.v1.batch.service.TTaskArchiveRelationService
;
import
com.yifu.cloud.plus.v1.batch.service.TTaskArchiveRelationService
;
import
com.yifu.cloud.plus.v1.batch.vo.*
;
import
com.yifu.cloud.plus.v1.batch.vo.*
;
import
com.yifu.cloud.plus.v1.yifu.common.core.constant.ClientNameConstants
;
import
com.yifu.cloud.plus.v1.yifu.common.core.constant.CommonConstants
;
import
com.yifu.cloud.plus.v1.yifu.common.core.constant.CommonConstants
;
import
com.yifu.cloud.plus.v1.yifu.common.core.util.Common
;
import
com.yifu.cloud.plus.v1.yifu.common.core.util.Common
;
import
com.yifu.cloud.plus.v1.yifu.common.core.util.OSSUtil
;
import
com.yifu.cloud.plus.v1.yifu.common.core.util.OSSUtil
;
import
com.yifu.cloud.plus.v1.yifu.common.core.util.R
;
import
com.yifu.cloud.plus.v1.yifu.common.core.util.R
;
import
com.yifu.cloud.plus.v1.yifu.common.core.util.bean.OSSObjectBean
;
import
com.yifu.cloud.plus.v1.yifu.common.core.util.bean.OSSObjectBean
;
import
com.yifu.cloud.plus.v1.yifu.common.core.vo.YifuUser
;
import
com.yifu.cloud.plus.v1.yifu.common.dapr.util.ArchivesDaprUtil
;
import
com.yifu.cloud.plus.v1.yifu.common.security.util.SecurityUtils
;
import
lombok.RequiredArgsConstructor
;
import
lombok.RequiredArgsConstructor
;
import
lombok.extern.log4j.Log4j2
;
import
lombok.extern.log4j.Log4j2
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Autowired
;
...
@@ -54,6 +58,7 @@ public class TElectronicArchiveDetailServiceImpl extends ServiceImpl<TElectronic
...
@@ -54,6 +58,7 @@ public class TElectronicArchiveDetailServiceImpl extends ServiceImpl<TElectronic
private
final
TAttaInfoService
attaInfoService
;
private
final
TAttaInfoService
attaInfoService
;
private
final
TTaskArchiveRelationService
relationService
;
private
final
TTaskArchiveRelationService
relationService
;
private
final
TElectronicArchiveTaskService
taskService
;
private
final
TElectronicArchiveTaskService
taskService
;
private
final
ArchivesDaprUtil
archivesDaprUtil
;
@Autowired
@Autowired
private
OSSUtil
ossUtil
;
private
OSSUtil
ossUtil
;
...
@@ -65,7 +70,9 @@ public class TElectronicArchiveDetailServiceImpl extends ServiceImpl<TElectronic
...
@@ -65,7 +70,9 @@ public class TElectronicArchiveDetailServiceImpl extends ServiceImpl<TElectronic
*/
*/
@Override
@Override
public
IPage
<
TElectronicArchiveDetail
>
getTElectronicArchiveDetailPage
(
Page
<
TElectronicArchiveDetail
>
page
,
TElectronicArchiveDetailSearchVo
tElectronicArchiveDetail
){
public
IPage
<
TElectronicArchiveDetail
>
getTElectronicArchiveDetailPage
(
Page
<
TElectronicArchiveDetail
>
page
,
TElectronicArchiveDetailSearchVo
tElectronicArchiveDetail
){
return
baseMapper
.
getTElectronicArchiveDetailPage
(
page
,
tElectronicArchiveDetail
);
//权限赋值
initSearchVo
(
tElectronicArchiveDetail
);
return
baseMapper
.
getTElectronicArchiveDetailPage
(
page
,
tElectronicArchiveDetail
);
}
}
/**
/**
...
@@ -1011,4 +1018,24 @@ public class TElectronicArchiveDetailServiceImpl extends ServiceImpl<TElectronic
...
@@ -1011,4 +1018,24 @@ public class TElectronicArchiveDetailServiceImpl extends ServiceImpl<TElectronic
}
}
}
}
}
}
public
void
initSearchVo
(
TElectronicArchiveDetailSearchVo
searchVo
)
{
YifuUser
user
=
SecurityUtils
.
getUser
();
long
roleId
=
1839501715787390978L
;
boolean
isSsc
=
this
.
haveRole
(
user
,
roleId
);
if
(
isSsc
||
CommonConstants
.
ZERO_STRING
.
equals
(
user
.
getSystemFlag
()))
{
searchVo
.
setAuthSql
(
null
);
return
;
}
}
public
boolean
haveRole
(
YifuUser
user
,
long
roleId
)
{
List
<
Long
>
roleList
=
user
.
getClientRoleMap
().
get
(
ClientNameConstants
.
CLIENT_MVP
);
for
(
Long
role
:
roleList
)
{
if
(
role
==
roleId
)
{
return
true
;
}
}
return
false
;
}
}
}
yifu-batch/yifu-batch-biz/src/main/resources/mapper/TElectronicArchiveDetailMapper.xml
View file @
b2476458
...
@@ -88,6 +88,9 @@
...
@@ -88,6 +88,9 @@
<if
test=
"tElectronicArchiveDetail.createBy != null and tElectronicArchiveDetail.createBy.trim() != ''"
>
<if
test=
"tElectronicArchiveDetail.createBy != null and tElectronicArchiveDetail.createBy.trim() != ''"
>
AND a.CREATE_BY = #{tElectronicArchiveDetail.createBy}
AND a.CREATE_BY = #{tElectronicArchiveDetail.createBy}
</if>
</if>
<if
test=
"tElectronicArchiveDetail.authSql != null and tElectronicArchiveDetail.authSql.trim() != ''"
>
${tElectronicArchiveDetail.authSql}
</if>
</if>
</if>
</sql>
</sql>
<!--tElectronicArchiveDetail简单分页查询-->
<!--tElectronicArchiveDetail简单分页查询-->
...
...
yifu-csp/yifu-csp-biz/src/main/java/com/yifu/cloud/plus/v1/csp/service/impl/EmployeeRegistrationServiceImpl.java
View file @
b2476458
...
@@ -580,10 +580,12 @@ public class EmployeeRegistrationServiceImpl extends ServiceImpl<EmployeeRegistr
...
@@ -580,10 +580,12 @@ public class EmployeeRegistrationServiceImpl extends ServiceImpl<EmployeeRegistr
!
CommonConstants
.
ONE_STRING
.
equals
(
registration
.
getProcessStatus
())))
{
!
CommonConstants
.
ONE_STRING
.
equals
(
registration
.
getProcessStatus
())))
{
return
R
.
failed
(
CommonConstants
.
NO_DATA_TO_HANDLE
);
return
R
.
failed
(
CommonConstants
.
NO_DATA_TO_HANDLE
);
}
}
//错误信息
StringBuilder
errorTemp
=
new
StringBuilder
();
if
(
preVo
.
getServerItem
().
contains
(
"商险"
)
&&
!
preVo
.
getEmployeeInsurancePreVos
().
isEmpty
()
if
(
preVo
.
getServerItem
().
contains
(
"商险"
)
&&
!
preVo
.
getEmployeeInsurancePreVos
().
isEmpty
()
&&
Common
.
isNotNull
(
preVo
.
getInsuranceIsBuy
())
&&
Common
.
isNotNull
(
preVo
.
getInsuranceIsBuy
())
&&
preVo
.
getInsuranceIsBuy
().
equals
(
CommonConstants
.
ONE_STRING
))
{
&&
preVo
.
getInsuranceIsBuy
().
equals
(
CommonConstants
.
ONE_STRING
))
{
List
<
TEmployeeAutoRegistCheckVo
>
errorList
=
new
ArrayList
<>();
//
List<TEmployeeAutoRegistCheckVo> errorList = new ArrayList<>();
TEmployeeAutoRegistCheckVo
checkVo
;
TEmployeeAutoRegistCheckVo
checkVo
;
String
key
;
String
key
;
// 判断重复性MAP
// 判断重复性MAP
...
@@ -594,23 +596,26 @@ public class EmployeeRegistrationServiceImpl extends ServiceImpl<EmployeeRegistr
...
@@ -594,23 +596,26 @@ public class EmployeeRegistrationServiceImpl extends ServiceImpl<EmployeeRegistr
if
(
keyMap
.
get
(
key
)
==
null
)
{
if
(
keyMap
.
get
(
key
)
==
null
)
{
keyMap
.
put
(
key
,
CommonConstants
.
ONE_INT
);
keyMap
.
put
(
key
,
CommonConstants
.
ONE_INT
);
}
else
{
}
else
{
return
R
.
other
(
CommonConstants
.
TWO_INT
,
null
,
"保险公司、险种、购买标准、保单起/止日期不可同时重复!"
);
errorTemp
.
append
(
"保险公司、险种、购买标准、保单起/止日期不可同时重复;"
);
// return R.other(CommonConstants.TWO_INT,null,"保险公司、险种、购买标准、保单起/止日期不可同时重复!");
}
}
insurancePreVo
.
setEmpIdcard
(
registration
.
getEmpIdcard
());
insurancePreVo
.
setEmpIdcard
(
registration
.
getEmpIdcard
());
insurancePreVo
.
setDeptNo
(
registration
.
getDeptNo
());
insurancePreVo
.
setDeptNo
(
registration
.
getDeptNo
());
//商险是否存在判断
//商险是否存在判断
checkVo
=
checkInsuranceExit
(
insurancePreVo
,
registration
);
checkVo
=
checkInsuranceExit
(
insurancePreVo
,
registration
);
if
(
null
!=
checkVo
)
{
if
(
null
!=
checkVo
)
{
errorList
.
add
(
checkVo
);
errorTemp
.
append
(
"保单开始日期:"
+
insurancePreVo
.
getPolicyStart
().
toString
()
+
",保单结束日期:"
+
insurancePreVo
.
getPolicyEnd
().
toString
()
+
"这条数据存在流程中/已完结的商险数据;"
);
// errorList.add(checkVo);
}
else
{
}
else
{
if
(
Common
.
isEmpty
(
insurancePreVo
.
getProcessStatus
()))
{
if
(
Common
.
isEmpty
(
insurancePreVo
.
getProcessStatus
()))
{
insurancePreVo
.
setProcessStatus
(
CommonConstants
.
ZERO_STRING
);
insurancePreVo
.
setProcessStatus
(
CommonConstants
.
ZERO_STRING
);
}
}
}
}
}
}
if
(!
errorList
.
isEmpty
())
{
//
if (!errorList.isEmpty()) {
return
R
.
other
(
CommonConstants
.
TWO_INT
,
null
,
errorList
);
//
return R.other(CommonConstants.TWO_INT,null,errorList);
}
//
}
}
}
//1.9.12合同自动化校验逻辑
//1.9.12合同自动化校验逻辑
TEmployeeAutoRegistCheckVo
cardVo
=
new
TEmployeeAutoRegistCheckVo
();
TEmployeeAutoRegistCheckVo
cardVo
=
new
TEmployeeAutoRegistCheckVo
();
...
@@ -623,12 +628,14 @@ public class EmployeeRegistrationServiceImpl extends ServiceImpl<EmployeeRegistr
...
@@ -623,12 +628,14 @@ public class EmployeeRegistrationServiceImpl extends ServiceImpl<EmployeeRegistr
//是否已签署为是需要判断合同是否在用或者流程中
//是否已签署为是需要判断合同是否在用或者流程中
if
(
CommonConstants
.
ZERO_STRING
.
equals
(
employeeContractPreVo
.
getContractFlag
())
&&
if
(
CommonConstants
.
ZERO_STRING
.
equals
(
employeeContractPreVo
.
getContractFlag
())
&&
(
Common
.
isEmpty
(
flag
)
||
Boolean
.
TRUE
.
equals
(!
flag
.
getData
())))
{
(
Common
.
isEmpty
(
flag
)
||
Boolean
.
TRUE
.
equals
(!
flag
.
getData
())))
{
return
R
.
other
(
CommonConstants
.
TWO_INT
,
null
,
"未找到流程中或者在用的合同!"
);
errorTemp
.
append
(
"未找到流程中或者在用的合同;"
);
// return R.other(CommonConstants.TWO_INT,null,"未找到流程中或者在用的合同!");
}
}
//是否已签署为否需要判断是否在用或者流程中的合同
//是否已签署为否需要判断是否在用或者流程中的合同
if
(
CommonConstants
.
ONE_STRING
.
equals
(
employeeContractPreVo
.
getContractFlag
())
&&
if
(
CommonConstants
.
ONE_STRING
.
equals
(
employeeContractPreVo
.
getContractFlag
())
&&
Common
.
isNotNull
(
flag
)
&&
Boolean
.
TRUE
.
equals
(
flag
.
getData
()))
{
Common
.
isNotNull
(
flag
)
&&
Boolean
.
TRUE
.
equals
(
flag
.
getData
()))
{
return
R
.
other
(
CommonConstants
.
TWO_INT
,
null
,
"该项目下存在在途/有效的合同数据,请“是否已签署合同”是否调整为“是”"
);
errorTemp
.
append
(
"该项目下存在在途/有效的合同数据,请【是否已签署合同】是否调整为【是】;"
);
// return R.other(CommonConstants.TWO_INT,null,"该项目下存在在途/有效的合同数据,请“是否已签署合同”是否调整为“是”");
}
}
}
}
...
@@ -641,7 +648,8 @@ public class EmployeeRegistrationServiceImpl extends ServiceImpl<EmployeeRegistr
...
@@ -641,7 +648,8 @@ public class EmployeeRegistrationServiceImpl extends ServiceImpl<EmployeeRegistr
preVo
.
getExitInsuranceInfoList
().
forEach
(
e
->
e
.
setCreateTime
(
null
));
preVo
.
getExitInsuranceInfoList
().
forEach
(
e
->
e
.
setCreateTime
(
null
));
boolean
isTrue
=
checkInsuranceIsProcess
(
preVo
);
boolean
isTrue
=
checkInsuranceIsProcess
(
preVo
);
if
(
isTrue
)
{
if
(
isTrue
)
{
return
R
.
other
(
CommonConstants
.
TWO_INT
,
null
,
"带出的商险已购买数据状态或条数发生变更,请重新确认接收!"
);
errorTemp
.
append
(
"带出的商险已购买数据状态或条数发生变更,请重新确认;"
);
// return R.other(CommonConstants.TWO_INT,null,"带出的商险已购买数据状态或条数发生变更,请重新确认接收!");
}
}
}
}
...
@@ -660,12 +668,14 @@ public class EmployeeRegistrationServiceImpl extends ServiceImpl<EmployeeRegistr
...
@@ -660,12 +668,14 @@ public class EmployeeRegistrationServiceImpl extends ServiceImpl<EmployeeRegistr
//是否已签署为是需要判断合同是否在用或者流程中
//是否已签署为是需要判断合同是否在用或者流程中
if
(
CommonConstants
.
ZERO_STRING
.
equals
(
preVo
.
getSocialIsBuy
())
&&
if
(
CommonConstants
.
ZERO_STRING
.
equals
(
preVo
.
getSocialIsBuy
())
&&
(
Common
.
isEmpty
(
socialFlag
)
||
Boolean
.
TRUE
.
equals
(!
socialFlag
.
getData
())))
{
(
Common
.
isEmpty
(
socialFlag
)
||
Boolean
.
TRUE
.
equals
(!
socialFlag
.
getData
())))
{
return
R
.
other
(
CommonConstants
.
TWO_INT
,
null
,
"未找到流程中或者在用的社保信息!"
);
errorTemp
.
append
(
"未找到流程中或者在用的社保信息;"
);
// return R.other(CommonConstants.TWO_INT,null,"未找到流程中或者在用的社保信息!");
}
}
//是否已签署为否需要判断是否在用或者流程中的合同
//是否已签署为否需要判断是否在用或者流程中的合同
if
(
CommonConstants
.
ONE_STRING
.
equals
(
preVo
.
getSocialIsBuy
())
&&
if
(
CommonConstants
.
ONE_STRING
.
equals
(
preVo
.
getSocialIsBuy
())
&&
Common
.
isNotNull
(
socialFlag
)
&&
Boolean
.
TRUE
.
equals
(
socialFlag
.
getData
()))
{
Common
.
isNotNull
(
socialFlag
)
&&
Boolean
.
TRUE
.
equals
(
socialFlag
.
getData
()))
{
return
R
.
other
(
CommonConstants
.
TWO_INT
,
null
,
"该人员存在在途/有效的社保数据,请将“是否已参保”调整为“是”"
);
errorTemp
.
append
(
"该人员存在在途/有效的社保数据,请将【是否已参保】调整为【是】;"
);
// return R.other(CommonConstants.TWO_INT,null,"该人员存在在途/有效的社保数据,请将“是否已参保”调整为“是”");
}
}
}
}
...
@@ -676,12 +686,14 @@ public class EmployeeRegistrationServiceImpl extends ServiceImpl<EmployeeRegistr
...
@@ -676,12 +686,14 @@ public class EmployeeRegistrationServiceImpl extends ServiceImpl<EmployeeRegistr
//是否已签署为是需要判断是否在用或者流程中的公积金
//是否已签署为是需要判断是否在用或者流程中的公积金
if
(
CommonConstants
.
ZERO_STRING
.
equals
(
preVo
.
getFundIsBuy
())
&&
if
(
CommonConstants
.
ZERO_STRING
.
equals
(
preVo
.
getFundIsBuy
())
&&
(
Common
.
isEmpty
(
flag
)
||
Boolean
.
TRUE
.
equals
(!
flag
.
getData
())))
{
(
Common
.
isEmpty
(
flag
)
||
Boolean
.
TRUE
.
equals
(!
flag
.
getData
())))
{
return
R
.
other
(
CommonConstants
.
THREE_INT
,
null
,
"未找到流程中或者在用的公积金信息!"
);
errorTemp
.
append
(
"未找到流程中或者在用的公积金信息;"
);
// return R.other(CommonConstants.THREE_INT,null,"未找到流程中或者在用的公积金信息!");
}
}
// 是否已签署为否需要判断是否在用或者流程中的公积金
// 是否已签署为否需要判断是否在用或者流程中的公积金
if
(
CommonConstants
.
ONE_STRING
.
equals
(
preVo
.
getFundIsBuy
())
&&
if
(
CommonConstants
.
ONE_STRING
.
equals
(
preVo
.
getFundIsBuy
())
&&
Common
.
isNotNull
(
flag
)
&&
Boolean
.
TRUE
.
equals
(
flag
.
getData
()))
{
Common
.
isNotNull
(
flag
)
&&
Boolean
.
TRUE
.
equals
(
flag
.
getData
()))
{
return
R
.
other
(
CommonConstants
.
THREE_INT
,
null
,
"该人员存在在途/有效的公积金数据,请将'是否已参保'调整为'是'"
);
errorTemp
.
append
(
"该人员存在在途/有效的公积金数据,请将【是否已参保】调整为【是】;"
);
// return R.other(CommonConstants.THREE_INT,null,"该人员存在在途/有效的公积金数据,请将'是否已参保'调整为'是'");
}
}
//判断公积金基数 是否小于 公积金户配置的最低基数
//判断公积金基数 是否小于 公积金户配置的最低基数
/*if (Common.isNotNull(preVo.getDispatchInfoFundPreVo().getConfigHouseId())
/*if (Common.isNotNull(preVo.getDispatchInfoFundPreVo().getConfigHouseId())
...
@@ -699,6 +711,10 @@ public class EmployeeRegistrationServiceImpl extends ServiceImpl<EmployeeRegistr
...
@@ -699,6 +711,10 @@ public class EmployeeRegistrationServiceImpl extends ServiceImpl<EmployeeRegistr
}*/
}*/
}
}
//错误信息全量返回
if
(
errorTemp
.
length
()
>
0
)
{
return
R
.
other
(
CommonConstants
.
TWO_INT
,
null
,
errorTemp
.
toString
());
}
//点击“接收确认”的时候,监测到该人员该项目下已有在项的档案时,再次提醒:该人员已在项,
//点击“接收确认”的时候,监测到该人员该项目下已有在项的档案时,再次提醒:该人员已在项,
//状态将更新成“已处理”;处理记录中,针对此情况,记录真实的进项时间,备注:先于登记入项
//状态将更新成“已处理”;处理记录中,针对此情况,记录真实的进项时间,备注:先于登记入项
EmpProjectStatusVo
vo
=
new
EmpProjectStatusVo
();
EmpProjectStatusVo
vo
=
new
EmpProjectStatusVo
();
...
...
yifu-insurances/yifu-insurances-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/insurances/service/insurance/impl/TBusinessOperateServiceImpl.java
View file @
b2476458
...
@@ -96,7 +96,7 @@ public class TBusinessOperateServiceImpl extends ServiceImpl<TBusinessOperateMap
...
@@ -96,7 +96,7 @@ public class TBusinessOperateServiceImpl extends ServiceImpl<TBusinessOperateMap
}
}
List
<
TBusinessOperate
>
backList
=
new
ArrayList
<>();
List
<
TBusinessOperate
>
backList
=
new
ArrayList
<>();
if
(!
list
.
isEmpty
())
{
if
(!
list
.
isEmpty
())
{
backList
=
list
.
stream
().
sorted
(
Comparator
.
comparing
(
TBusinessOperate:
:
getCreateTime
)).
collect
(
Collectors
.
toList
());
backList
=
list
.
stream
().
sorted
(
Comparator
.
comparing
(
TBusinessOperate:
:
getCreateTime
)
.
reversed
()
).
collect
(
Collectors
.
toList
());
}
}
return
backList
;
return
backList
;
}
}
...
...
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