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
00d3b9a0
Commit
00d3b9a0
authored
May 23, 2023
by
zhenbin wang
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/MVP1.5.4' into MVP1.5.4
parents
ab7e4e72
3c83d31f
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
68 additions
and
27 deletions
+68
-27
UpdateEmpVo.java
.../com/yifu/cloud/plus/v1/yifu/archives/vo/UpdateEmpVo.java
+13
-0
TEmployeeInfoServiceImpl.java
.../yifu/archives/service/impl/TEmployeeInfoServiceImpl.java
+2
-2
TEmployeeInfoMapper.xml
...ves-biz/src/main/resources/mapper/TEmployeeInfoMapper.xml
+3
-8
ArchivesDaprUtil.java
...cloud/plus/v1/yifu/common/dapr/util/ArchivesDaprUtil.java
+4
-1
TDispatchInfoServiceImpl.java
...v1/yifu/social/service/impl/TDispatchInfoServiceImpl.java
+46
-16
No files found.
yifu-archives/yifu-archives-api/src/main/java/com/yifu/cloud/plus/v1/yifu/archives/vo/UpdateEmpVo.java
View file @
00d3b9a0
package
com
.
yifu
.
cloud
.
plus
.
v1
.
yifu
.
archives
.
vo
;
import
com.alibaba.excel.annotation.ExcelIgnore
;
import
com.baomidou.mybatisplus.annotation.FieldFill
;
import
com.baomidou.mybatisplus.annotation.TableField
;
import
io.swagger.v3.oas.annotations.media.Schema
;
import
lombok.Data
;
import
java.io.Serializable
;
...
...
@@ -23,4 +27,13 @@ public class UpdateEmpVo implements Serializable {
// type 0 审核通过 2.审核不通过
String
type
;
/**
* @Description: 合同审核人要传过去
* @Author: hgw
* @Date: 2023/5/23 9:59
* @return:
**/
private
String
createName
;
private
String
createBy
;
}
yifu-archives/yifu-archives-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/archives/service/impl/TEmployeeInfoServiceImpl.java
View file @
00d3b9a0
...
...
@@ -2241,8 +2241,8 @@ public class TEmployeeInfoServiceImpl extends ServiceImpl<TEmployeeInfoMapper, T
TEmployeeContractAudit
contractAudit
=
new
TEmployeeContractAudit
();
contractAudit
.
setLinkId
(
c
.
getId
());
contractAudit
.
setLinkType
(
CommonConstants
.
ONE_INT
);
contractAudit
.
setCreateBy
(
c
.
getCreateBy
());
contractAudit
.
setCreateName
(
c
.
getCreateName
());
contractAudit
.
setCreateBy
(
vo
.
getCreateBy
());
contractAudit
.
setCreateName
(
vo
.
getCreateName
());
contractAudit
.
setCreateTime
(
LocalDateTime
.
now
());
//审核通过
c
.
setAuditUserName
(
c
.
getCreateBy
());
...
...
yifu-archives/yifu-archives-biz/src/main/resources/mapper/TEmployeeInfoMapper.xml
View file @
00d3b9a0
...
...
@@ -925,14 +925,9 @@
WHERE
x.DELETE_FLAG = '0'
AND (
(
x.AUDIT_STATUS = '2'
AND x.IN_USE = '0'
)
OR (
x.AUDIT_STATUS = '1'
AND x.IN_USE = '1'
)
( x.AUDIT_STATUS = '2' AND x.IN_USE = '0' )
OR
( x.AUDIT_STATUS = '1' AND x.IN_USE = '1' )
)
<if
test=
"checkVo != null"
>
<if
test=
"checkVo.idCards != null"
>
...
...
yifu-common/yifu-common-dapr/src/main/java/com/yifu/cloud/plus/v1/yifu/common/dapr/util/ArchivesDaprUtil.java
View file @
00d3b9a0
...
...
@@ -11,6 +11,7 @@ import com.yifu.cloud.plus.v1.yifu.common.core.constant.CommonConstants;
import
com.yifu.cloud.plus.v1.yifu.common.core.constant.SecurityConstants
;
import
com.yifu.cloud.plus.v1.yifu.common.core.util.Common
;
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.config.DaprArchivesProperties
;
import
lombok.extern.log4j.Log4j2
;
import
org.springframework.beans.factory.annotation.Autowired
;
...
...
@@ -280,7 +281,7 @@ public class ArchivesDaprUtil {
* @Param type 0 审核通过 1 审核不通过
* @return
**/
public
R
<
Boolean
>
updateEmpInfo
(
String
empIdCard
,
String
projectNo
,
String
contractId
,
String
type
,
String
remarkTemp
){
public
R
<
Boolean
>
updateEmpInfo
(
String
empIdCard
,
String
projectNo
,
String
contractId
,
String
type
,
String
remarkTemp
,
YifuUser
user
){
if
(
Common
.
isEmpty
(
empIdCard
)
||
Common
.
isEmpty
(
projectNo
)
||
Common
.
isEmpty
(
type
)){
...
...
@@ -292,6 +293,8 @@ public class ArchivesDaprUtil {
vo
.
setContractId
(
contractId
);
vo
.
setRemarkTemp
(
remarkTemp
);
vo
.
setType
(
type
);
vo
.
setCreateBy
(
user
.
getId
());
vo
.
setCreateName
(
user
.
getNickname
());
R
<
Boolean
>
res
=
HttpDaprUtil
.
invokeMethodPost
(
daprArchivesProperties
.
getAppUrl
(),
daprArchivesProperties
.
getAppId
()
,
"/temployeeinfo/inner/updateEmpInfo"
,
JSON
.
toJSONString
(
vo
),
Boolean
.
class
,
SecurityConstants
.
FROM_IN
);
...
...
yifu-social/yifu-social-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/social/service/impl/TDispatchInfoServiceImpl.java
View file @
00d3b9a0
...
...
@@ -1250,7 +1250,6 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
if
(
isSsc
)
{
dispatch
.
setStatus
(
CommonConstants
.
FIVE_STRING
);
}
dispatch
.
setStatus
(
CommonConstants
.
ONE_STRING
);
dispatch
.
setDeleteFlag
(
CommonConstants
.
ZERO_STRING
);
// 封装项目客户信息
dispatch
.
setBelongUnit
(
excel
.
getCustomerId
());
...
...
@@ -2250,9 +2249,28 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
return
true
;
}
// 档案无合同 合同起日期、合同类型必填
if
(
Common
.
isEmpty
(
empVo
.
getContractName
())
&&
validContractInfo
(
errorMessageList
,
excel
)){
if
(
Common
.
isEmpty
(
empVo
.
getContractName
())
&&
validContractInfo
(
errorMessageList
,
excel
))
{
return
true
;
}
if
(
Common
.
isNotNull
(
empVo
.
getContractStart
()))
{
// 系统已存在的合同起缴日期
String
conYearMonthDay
=
DateUtil
.
formatDatePatten
(
empVo
.
getContractStart
(),
DateUtil
.
ISO_EXPANDED_DATE_FORMAT
);
String
excelConYearMonthDay
=
DateUtil
.
formatDatePatten
(
excel
.
getContractStart
(),
DateUtil
.
ISO_EXPANDED_DATE_FORMAT
);
if
(!
conYearMonthDay
.
equals
(
excelConYearMonthDay
))
{
errorMessageList
.
add
(
new
ErrorMessage
(
excel
.
getRowIndex
(),
"系统内[合同]起缴日期年月日【"
+
conYearMonthDay
+
"】与派单[合同]日期的年月日【"
+
excelConYearMonthDay
+
"】不一致!禁止派单!"
));
return
true
;
}
String
conYearMonth
=
DateUtil
.
formatDatePatten
(
empVo
.
getContractStart
(),
DateUtil
.
DATETIME_YYYYMM
);
if
(
Common
.
isEmpty
(
excel
.
getTrustRemark
()))
{
if
(
judgeConStartAndSocialFund
(
errorMessageList
,
excel
,
conYearMonth
,
excel
.
getPensionStart
(),
"养老"
))
{
return
true
;}
if
(
judgeConStartAndSocialFund
(
errorMessageList
,
excel
,
conYearMonth
,
excel
.
getMedicalStart
(),
"医疗"
))
{
return
true
;}
if
(
judgeConStartAndSocialFund
(
errorMessageList
,
excel
,
conYearMonth
,
excel
.
getUnemployStart
(),
"失业"
))
{
return
true
;}
if
(
judgeConStartAndSocialFund
(
errorMessageList
,
excel
,
conYearMonth
,
excel
.
getWorkInjuryStart
(),
"工伤"
))
{
return
true
;}
if
(
judgeConStartAndSocialFund
(
errorMessageList
,
excel
,
conYearMonth
,
excel
.
getBirthStart
(),
"生育"
))
{
return
true
;}
if
(
judgeConStartAndSocialFund
(
errorMessageList
,
excel
,
conYearMonth
,
excel
.
getBigailmentStart
(),
"大病"
))
{
return
true
;}
}
}
if
(
Common
.
isNotNull
(
empVo
.
getEmpNatrue
())){
excel
.
setEmpType
(
empVo
.
getEmpNatrue
());
}
...
...
@@ -2423,6 +2441,29 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
return
false
;
}
/**
* @param errorMessageList
* @param excel
* @param conYearMonth
* @param startDate
* @Description: 判断合同日期与社保公积金日期是否一致
* @Author: hgw
* @Date: 2023/5/22 17:06
* @return: boolean
**/
private
boolean
judgeConStartAndSocialFund
(
List
<
ErrorMessage
>
errorMessageList
,
TDispatchImportVo
excel
,
String
conYearMonth
,
Date
startDate
,
String
message
)
{
if
(
Common
.
isNotNull
(
startDate
))
{
String
startD
=
DateUtil
.
formatDatePatten
(
startDate
,
DateUtil
.
DATETIME_YYYYMM
);
if
(!
conYearMonth
.
equals
(
startD
)
)
{
errorMessageList
.
add
(
new
ErrorMessage
(
excel
.
getRowIndex
(),
"系统内[合同]起缴日期年月【"
+
conYearMonth
+
"】与派单["
+
message
+
"]日期的年月【"
+
startD
+
"】不一致!委托备注必填!"
));
return
true
;
}
}
return
false
;
}
private
boolean
checkMobileAndIdcard
(
List
<
ErrorMessage
>
errorMessageList
,
TDispatchImportVo
excel
)
{
// 如果没有人员档案和项目档案的时候校验身份证和手机号码
R
<
Boolean
>
checkRes
=
checkDaprUtil
.
checkIdCardAndMobile
(
null
,
null
,
excel
.
getEmpMobile
());
...
...
@@ -2510,17 +2551,6 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
errorMessageList
.
add
(
new
ErrorMessage
(
excel
.
getRowIndex
(),
MsgUtils
.
getMessage
(
ErrorCodes
.
EMP_DISPATCH_SOCIAL_BASE_LIMIT_ERROR
)));
return
true
;
}
flag
=
(
Common
.
isNotNull
(
contractDateTemp
)
&&
((!
contractDateTemp
.
equals
(
excel
.
getPensionStart
())
&&
Common
.
isNotNull
(
excel
.
getPensionStart
()))
||
(!
contractDateTemp
.
equals
(
excel
.
getMedicalStart
())
&&
Common
.
isNotNull
(
excel
.
getMedicalStart
()))
||
(!
contractDateTemp
.
equals
(
excel
.
getUnemployStart
())
&&
Common
.
isNotNull
(
excel
.
getUnemployStart
()))
||
(!
contractDateTemp
.
equals
(
excel
.
getBirthStart
())
&&
Common
.
isNotNull
(
excel
.
getBirthStart
()))
||
(!
contractDateTemp
.
equals
(
excel
.
getWorkInjuryStart
())
&&
Common
.
isNotNull
(
excel
.
getWorkInjuryStart
()))
||
(!
contractDateTemp
.
equals
(
excel
.
getBigailmentStart
())
&&
Common
.
isNotNull
(
excel
.
getBigailmentStart
()))));
if
(
flag
){
errorMessageList
.
add
(
new
ErrorMessage
(
excel
.
getRowIndex
(),
MsgUtils
.
getMessage
(
ErrorCodes
.
EMP_DISPATCH_SOCIAL_DATE_LIMIT_ERROR2
)));
return
true
;
}
}
Date
temp
;
if
(
Common
.
isEmpty
(
empVo
)){
...
...
@@ -2540,7 +2570,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
}
// 其他 只用判断对应养老基数和时间 与合同时间 即可
if
(!
CommonConstants
.
ONE_STRING
.
equals
(
excel
.
getPaymentType
())
&&
Common
.
isEmpty
(
excel
.
getTrustRemark
())
&&
!
temp
.
equals
(
excel
.
getPensionStart
(
))
&&
!
DateUtil
.
formatDatePatten
(
temp
,
DateUtil
.
DATETIME_YYYYMM
).
equals
(
DateUtil
.
formatDatePatten
(
excel
.
getPensionStart
(),
DateUtil
.
DATETIME_YYYYMM
))
){
errorMessageList
.
add
(
new
ErrorMessage
(
excel
.
getRowIndex
(),
MsgUtils
.
getMessage
(
ErrorCodes
.
EMP_DISPATCH_SOCIAL_DATE_LIMIT_ERROR2
)));
return
true
;
...
...
@@ -3283,10 +3313,10 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
if
(
CommonConstants
.
dingleDigitStrArray
[
0
].
equals
(
dis
.
getType
())){
R
<
Boolean
>
res
=
null
;
if
(
CommonConstants
.
ZERO_INT
==
flag
&&
!
isSSC
){
res
=
archivesDaprUtil
.
updateEmpInfo
(
dis
.
getEmpIdcard
(),
dis
.
getSettleDomainCode
(),
dis
.
getContractId
(),
CommonConstants
.
ZERO_STRING
,
remarkTemp
);
res
=
archivesDaprUtil
.
updateEmpInfo
(
dis
.
getEmpIdcard
(),
dis
.
getSettleDomainCode
(),
dis
.
getContractId
(),
CommonConstants
.
ZERO_STRING
,
remarkTemp
,
user
);
}
if
(
CommonConstants
.
ONE_INT
==
flag
){
res
=
archivesDaprUtil
.
updateEmpInfo
(
dis
.
getEmpIdcard
(),
dis
.
getSettleDomainCode
(),
dis
.
getContractId
(),
CommonConstants
.
ONE_STRING
,
remarkTemp
);
res
=
archivesDaprUtil
.
updateEmpInfo
(
dis
.
getEmpIdcard
(),
dis
.
getSettleDomainCode
(),
dis
.
getContractId
(),
CommonConstants
.
ONE_STRING
,
remarkTemp
,
user
);
}
if
((
Common
.
isEmpty
(
res
)
||
CommonConstants
.
SUCCESS
!=
res
.
getCode
())
&&
!
isSSC
){
ServiceUtil
.
runTimeExceptionDiy
(
"更新人员档案、项目档案、合同状态异常:"
+
(
Common
.
isNotNull
(
res
)?
res
.
getMsg
():
CommonConstants
.
EMPTY_STRING
));
...
...
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