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
b3ed8e19
Commit
b3ed8e19
authored
Jul 05, 2022
by
hongguangwu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
合同-date
parent
a2d87422
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
21 additions
and
18 deletions
+21
-18
FddContractAttachInfo.java
...d/plus/v1/yifu/archives/entity/FddContractAttachInfo.java
+6
-5
FddContractAttachInfoServiceImpl.java
...chives/service/impl/FddContractAttachInfoServiceImpl.java
+5
-2
TEmpContractAlertServiceImpl.java
...u/archives/service/impl/TEmpContractAlertServiceImpl.java
+10
-11
No files found.
yifu-archives/yifu-archives-api/src/main/java/com/yifu/cloud/plus/v1/yifu/archives/entity/FddContractAttachInfo.java
View file @
b3ed8e19
...
...
@@ -23,9 +23,10 @@ import com.yifu.cloud.plus.v1.yifu.common.mybatis.base.BaseEntity;
import
io.swagger.v3.oas.annotations.media.Schema
;
import
lombok.Data
;
import
lombok.EqualsAndHashCode
;
import
java.math.BigDecimal
;
import
java.time.LocalDate
;
import
java.time.LocalDateTime
;
import
java.util.Date
;
/**
* 法大大合同附属信息表
...
...
@@ -56,25 +57,25 @@ public class FddContractAttachInfo extends BaseEntity {
* 合同试用期开始时间
*/
@Schema
(
description
=
"合同试用期开始时间"
)
private
Local
Date
periodStart
;
private
Date
periodStart
;
/**
* 合同试用期结束时间
*/
@Schema
(
description
=
"合同试用期结束时间"
)
private
Local
Date
periodEnd
;
private
Date
periodEnd
;
/**
* 合同起始时间
*/
@Schema
(
description
=
"合同起始时间"
)
private
Local
Date
contractStart
;
private
Date
contractStart
;
/**
* 合同到期时间
*/
@Schema
(
description
=
"合同到期时间"
)
private
Local
Date
contractEnd
;
private
Date
contractEnd
;
/**
* 试用期工资 元/月
...
...
yifu-archives/yifu-archives-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/archives/service/impl/FddContractAttachInfoServiceImpl.java
View file @
b3ed8e19
...
...
@@ -29,7 +29,10 @@ import com.yifu.cloud.plus.v1.yifu.archives.mapper.TEmployeeProjectMapper;
import
com.yifu.cloud.plus.v1.yifu.archives.service.*
;
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.*
;
import
com.yifu.cloud.plus.v1.yifu.common.core.util.Common
;
import
com.yifu.cloud.plus.v1.yifu.common.core.util.ErrorMessage
;
import
com.yifu.cloud.plus.v1.yifu.common.core.util.NoUtil
;
import
com.yifu.cloud.plus.v1.yifu.common.core.util.R
;
import
com.yifu.cloud.plus.v1.yifu.common.dapr.config.DaprUpmsProperties
;
import
com.yifu.cloud.plus.v1.yifu.common.dapr.util.HttpDaprUtil
;
import
lombok.RequiredArgsConstructor
;
...
...
@@ -334,7 +337,7 @@ public class FddContractAttachInfoServiceImpl extends ServiceImpl<FddContractAtt
.
eq
(
TEmployeeContractInfo:
:
getInUse
,
CommonConstants
.
ZERO_STRING
));
if
(
employeeContractInfo
!=
null
)
{
long
count
=
this
.
count
(
Wrappers
.<
FddContractAttachInfo
>
query
().
lambda
().
eq
(
FddContractAttachInfo:
:
getContractId
,
employeeContractInfo
.
getId
()));
if
(
count
>
CommonConstants
.
ZERO_INT
&&
attachInfo
.
getContractStart
().
isB
efore
(
employeeContractInfo
.
getContractEnd
()))
{
if
(
count
>
CommonConstants
.
ZERO_INT
&&
attachInfo
.
getContractStart
().
b
efore
(
employeeContractInfo
.
getContractEnd
()))
{
errorList
.
add
(
new
ErrorMessage
(
i
,
"已导入合同相关基础数据"
,
CommonConstants
.
RED
));
continue
;
}
...
...
yifu-archives/yifu-archives-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/archives/service/impl/TEmpContractAlertServiceImpl.java
View file @
b3ed8e19
...
...
@@ -28,15 +28,16 @@ import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import
com.yifu.cloud.plus.v1.yifu.archives.constants.ArchivesConstants
;
import
com.yifu.cloud.plus.v1.yifu.archives.entity.TEmpBadRecord
;
import
com.yifu.cloud.plus.v1.yifu.archives.entity.TEmpContractAlert
;
import
com.yifu.cloud.plus.v1.yifu.archives.entity.TEmpFamily
;
import
com.yifu.cloud.plus.v1.yifu.archives.entity.TEmployeeContractInfo
;
import
com.yifu.cloud.plus.v1.yifu.archives.mapper.TEmpContractAlertMapper
;
import
com.yifu.cloud.plus.v1.yifu.archives.mapper.TEmployeeContractInfoMapper
;
import
com.yifu.cloud.plus.v1.yifu.archives.service.TEmpContractAlertService
;
import
com.yifu.cloud.plus.v1.yifu.archives.vo.ContractAlertSearchVo
;
import
com.yifu.cloud.plus.v1.yifu.archives.vo.FamilySearchVO
;
import
com.yifu.cloud.plus.v1.yifu.common.core.constant.CommonConstants
;
import
com.yifu.cloud.plus.v1.yifu.common.core.util.*
;
import
com.yifu.cloud.plus.v1.yifu.common.core.util.Common
;
import
com.yifu.cloud.plus.v1.yifu.common.core.util.DateUtil
;
import
com.yifu.cloud.plus.v1.yifu.common.core.util.ExcelUtil
;
import
com.yifu.cloud.plus.v1.yifu.common.core.util.R
;
import
com.yifu.cloud.plus.v1.yifu.common.mybatis.base.BaseEntity
;
import
lombok.RequiredArgsConstructor
;
import
org.springframework.stereotype.Service
;
...
...
@@ -45,7 +46,6 @@ import javax.servlet.ServletOutputStream;
import
javax.servlet.http.HttpServletResponse
;
import
java.io.IOException
;
import
java.net.URLEncoder
;
import
java.time.LocalDate
;
import
java.time.LocalDateTime
;
import
java.util.*
;
...
...
@@ -218,10 +218,9 @@ public class TEmpContractAlertServiceImpl extends ServiceImpl<TEmpContractAlertM
.
eq
(
TEmployeeContractInfo:
:
getDeleteFlag
,
CommonConstants
.
ZERO_STRING
));
Map
<
String
,
TEmpContractAlert
>
alertMap
=
new
HashMap
<>();
if
(
Common
.
isNotNull
(
alertList
)){
LocalDate
now
=
LocalDate
.
now
();
Date
nowDate
=
new
Date
();
for
(
TEmployeeContractInfo
contract:
alertList
){
extracted
(
now
,
now
Date
,
contract
,
alertMap
);
extracted
(
nowDate
,
contract
,
alertMap
);
}
}
if
(
Common
.
isNotNull
(
notAccessList
)
&&
Common
.
isNotNull
(
alertMap
)){
...
...
@@ -241,13 +240,13 @@ public class TEmpContractAlertServiceImpl extends ServiceImpl<TEmpContractAlertM
return
R
.
ok
();
}
private
void
extracted
(
LocalDate
now
,
Date
nowDate
,
private
void
extracted
(
Date
nowDate
,
TEmployeeContractInfo
contract
,
Map
<
String
,
TEmpContractAlert
>
alertMap
)
{
TEmpContractAlert
alert
=
alertMap
.
get
(
contract
.
getEmpIdcard
());
// 存在多个审核通过的数据 用最新的审核通过的合同覆盖已有的
if
(
Common
.
isNotNull
(
alert
)
&&
alert
.
getContractEnd
().
after
(
LocalDateTimeUtils
.
convertLDToDate
(
contract
.
getContractEnd
()
))){
alert
.
getContractEnd
().
after
(
contract
.
getContractEnd
(
))){
return
;
}
alert
=
new
TEmpContractAlert
();
...
...
@@ -257,8 +256,8 @@ public class TEmpContractAlertServiceImpl extends ServiceImpl<TEmpContractAlertM
alert
.
setProject
(
contract
.
getSubjectDepart
());
alert
.
setProjectNo
(
contract
.
getDeptNo
());
alert
.
setEmpIdcard
(
contract
.
getEmpIdcard
());
alert
.
setContractStart
(
LocalDateTimeUtils
.
convertLDToDate
(
contract
.
getContractStart
()
));
alert
.
setContractEnd
(
LocalDateTimeUtils
.
convertLDToDate
(
contract
.
getContractEnd
()
));
alert
.
setContractStart
(
contract
.
getContractStart
(
));
alert
.
setContractEnd
(
contract
.
getContractEnd
(
));
if
(
Common
.
isNotNull
(
contract
.
getFileProvince
())){
alert
.
setFileProvince
(
Integer
.
toString
(
contract
.
getFileProvince
()));
}
...
...
@@ -272,7 +271,7 @@ public class TEmpContractAlertServiceImpl extends ServiceImpl<TEmpContractAlertM
alert
.
setContractTerm
(
contract
.
getContractType
());
alert
.
setContractTerm
(
contract
.
getContractTerm
());
if
(
Common
.
isNotNull
(
alert
.
getContractEnd
())){
if
(
Common
.
isNotNull
(
contract
.
getContractEnd
())
&&
contract
.
getContractEnd
().
isBefore
(
now
)){
if
(
Common
.
isNotNull
(
contract
.
getContractEnd
())
&&
contract
.
getContractEnd
().
before
(
nowDate
)){
alert
.
setDueFlag
(
CommonConstants
.
ONE_STRING
);
alert
.
setDaysOver
(
DateUtil
.
daysBetween
(
nowDate
,
alert
.
getContractEnd
()));
}
else
{
...
...
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