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
e052cc84
Commit
e052cc84
authored
Jul 20, 2022
by
hongguangwu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
合同优化-归档
parent
ab1ac225
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
33 additions
and
11 deletions
+33
-11
TEmployeeContractInfoServiceImpl.java
...chives/service/impl/TEmployeeContractInfoServiceImpl.java
+23
-11
CommonConstants.java
...ud.plus.v1/yifu/common/core/constant/CommonConstants.java
+10
-0
No files found.
yifu-archives/yifu-archives-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/archives/service/impl/TEmployeeContractInfoServiceImpl.java
View file @
e052cc84
...
...
@@ -316,17 +316,7 @@ public class TEmployeeContractInfoServiceImpl extends ServiceImpl<TEmployeeContr
}
baseMapper
.
insert
(
tEmployeeContractInfo
);
if
(
Common
.
isNotNull
(
tEmployeeContractInfo
.
getAttaList
())
&&
Common
.
isNotNull
(
tEmployeeContractInfo
.
getId
()))
{
List
<
String
>
attaList
=
tEmployeeContractInfo
.
getAttaList
();
if
(
null
!=
attaList
&&
!
attaList
.
isEmpty
())
{
TAttaInfo
contractAtta
;
for
(
String
attaId
:
attaList
)
{
contractAtta
=
tAttaInfoService
.
getById
(
attaId
);
if
(
contractAtta
!=
null
&&
Common
.
isEmpty
(
contractAtta
.
getDomainId
()))
{
contractAtta
.
setDomainId
(
tEmployeeContractInfo
.
getId
());
tAttaInfoService
.
updateById
(
contractAtta
);
}
}
}
this
.
updateFileMainId
(
tEmployeeContractInfo
);
}
}
else
{
baseMapper
.
updateById
(
tEmployeeContractInfo
);
...
...
@@ -339,6 +329,27 @@ public class TEmployeeContractInfoServiceImpl extends ServiceImpl<TEmployeeContr
return
R
.
ok
(
null
,
CommonConstants
.
SAVE_SUCCESS
);
}
/**
* @param tEmployeeContractInfo
* @Description: 更新附件的合同id
* @Author: hgw
* @Date: 2022/7/20 10:07
* @return: void
**/
private
void
updateFileMainId
(
TEmployeeContractInfo
tEmployeeContractInfo
)
{
List
<
String
>
attaList
=
tEmployeeContractInfo
.
getAttaList
();
if
(
null
!=
attaList
&&
!
attaList
.
isEmpty
())
{
TAttaInfo
contractAtta
;
for
(
String
attaId
:
attaList
)
{
contractAtta
=
tAttaInfoService
.
getById
(
attaId
);
if
(
contractAtta
!=
null
&&
Common
.
isEmpty
(
contractAtta
.
getDomainId
()))
{
contractAtta
.
setDomainId
(
tEmployeeContractInfo
.
getId
());
tAttaInfoService
.
updateById
(
contractAtta
);
}
}
}
}
/**
* @param tEmployeeContractInfo
* @Description: 保存审核操作记录
...
...
@@ -498,6 +509,7 @@ public class TEmployeeContractInfoServiceImpl extends ServiceImpl<TEmployeeContr
}
//档案柜存在就自动归档
if
(
Common
.
isNotNull
(
tEmployeeContractInfo
.
getAttaList
()))
{
this
.
updateFileMainId
(
tEmployeeContractInfo
);
this
.
setFileInfo
(
tEmployeeContractInfo
.
getId
(),
"添加附件"
);
tEmployeeContractInfo
.
setIsFile
(
CommonConstants
.
ZERO_STRING
);
}
else
{
...
...
yifu-common/yifu-common-core/src/main/java/com/yifu.cloud.plus.v1/yifu/common/core/constant/CommonConstants.java
View file @
e052cc84
...
...
@@ -16,6 +16,7 @@
package
com
.
yifu
.
cloud
.
plus
.
v1
.
yifu
.
common
.
core
.
constant
;
import
java.math.BigDecimal
;
import
java.util.List
;
import
java.util.Set
;
...
...
@@ -130,6 +131,8 @@ public interface CommonConstants {
* number 0
*/
int
ZERO_INT
=
0
;
int
ONE_INT
=
1
;
int
TWO_INT
=
2
;
/**
* number 1
...
...
@@ -359,4 +362,11 @@ public interface CommonConstants {
public
static
final
int
SIXTEEN_INT
=
16
;
public
static
final
String
FIFTEEN
=
"15"
;
public
static
final
String
NINETEEN
=
"19"
;
//百分之一 1/100
public
static
final
BigDecimal
ONE_OF_PERCENT
=
new
BigDecimal
(
"0.01"
);
// 1/2
public
static
final
BigDecimal
HALF_OF_ONE
=
new
BigDecimal
(
"0.5"
);
public
static
final
BigDecimal
TWO_BIG
=
new
BigDecimal
(
"2"
);
}
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