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
959f9289
Commit
959f9289
authored
Sep 18, 2024
by
fangxinjiang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
附件编辑-fxj
parent
a3f4b018
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
81 additions
and
8 deletions
+81
-8
EmployeeInsertVO.java
...yifu/cloud/plus/v1/yifu/archives/vo/EmployeeInsertVO.java
+26
-3
EmployeeConstants.java
...ud/plus/v1/yifu/archives/constants/EmployeeConstants.java
+2
-1
TEmployeeInfoServiceImpl.java
.../yifu/archives/service/impl/TEmployeeInfoServiceImpl.java
+53
-4
No files found.
yifu-archives/yifu-archives-api/src/main/java/com/yifu/cloud/plus/v1/yifu/archives/vo/EmployeeInsertVO.java
View file @
959f9289
...
...
@@ -215,11 +215,34 @@ public class EmployeeInsertVO extends RowIndex implements Serializable {
private
String
remark
;
/**
* 通信地址
* 通信地址
省
*/
@
Schema
(
description
=
"通信地址"
)
@
ExcelAttribute
(
name
=
"通信地址-省"
,
isArea
=
true
,
isNotEmpty
=
true
)
@HeadFontStyle
(
fontHeightInPoints
=
11
)
@ExcelProperty
(
value
=
"通信地址"
)
@ExcelProperty
(
"通信地址-省"
)
private
String
contactProvince
;
/**
* 通信地址市
*/
@ExcelAttribute
(
name
=
"通信地址-市"
,
isArea
=
true
,
parentField
=
"contactProvince"
)
@HeadFontStyle
(
fontHeightInPoints
=
11
)
@ExcelProperty
(
"通信地址-市"
)
private
String
contactCity
;
/**
* 通信地址县
*/
@ExcelAttribute
(
name
=
"通信地址-区/县"
,
isArea
=
true
,
parentField
=
"contactCity"
)
@HeadFontStyle
(
fontHeightInPoints
=
11
)
@ExcelProperty
(
"通信地址-区/县"
)
private
String
contactTown
;
/**
* 通信地址-详细地址 fxj 20240911 通信地址 调整为 通信地址-详细地址
*/
@ExcelAttribute
(
name
=
"通信地址-详细地址"
)
@Schema
(
description
=
"通信地址-详细地址"
)
@HeadFontStyle
(
fontHeightInPoints
=
11
)
@ExcelProperty
(
value
=
"通信地址-详细地址"
)
private
String
contactAddress
;
}
yifu-archives/yifu-archives-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/archives/constants/EmployeeConstants.java
View file @
959f9289
...
...
@@ -15,9 +15,10 @@ public class EmployeeConstants {
public
static
final
String
EMP_NATIONAL
=
"民族必填"
;
public
static
final
String
ID_PROVINCE
=
"户籍所在地必填"
;
public
static
final
String
FILE_PROVINCE
=
"档案所在地必填"
;
public
static
final
String
CONTACT_PROVINCE
=
"通信地址(省市县)必填"
;
public
static
final
String
EMP_REGIS_TYPE
=
"户口性质必填"
;
public
static
final
String
IS_COLLEGE
=
"是否大专及以上必填"
;
public
static
final
String
CONTACT_ADDRESS
=
"通信地址必填"
;
public
static
final
String
CONTACT_ADDRESS
=
"通信地址
(详细地址)
必填"
;
public
static
final
String
EMP_NATRUE_ZERO
=
"派遣"
;
public
static
final
String
EMP_NATRUE_ONE
=
"外包"
;
public
static
final
String
EMP_NATRUE_THREE
=
"内部员工"
;
...
...
yifu-archives/yifu-archives-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/archives/service/impl/TEmployeeInfoServiceImpl.java
View file @
959f9289
...
...
@@ -277,6 +277,9 @@ public class TEmployeeInfoServiceImpl extends ServiceImpl<TEmployeeInfoMapper, T
adds
.
add
(
attaInfo
);
}
if
(
CommonConstants
.
ONE_STRING
.
equals
(
attaInfo
.
getHandleType
())){
adds
.
add
(
attaInfo
);
}
if
(
CommonConstants
.
TWO_STRING
.
equals
(
attaInfo
.
getHandleType
())){
deleteIds
.
add
(
attaInfo
.
getId
());
}
}
...
...
@@ -284,7 +287,7 @@ public class TEmployeeInfoServiceImpl extends ServiceImpl<TEmployeeInfoMapper, T
attaInfoService
.
removeBatchByIds
(
deleteIds
);
}
if
(
Common
.
isNotNull
(
adds
)){
attaInfoService
.
saveBatch
(
adds
);
attaInfoService
.
updateBatchById
(
adds
);
}
}
}
...
...
@@ -299,7 +302,17 @@ public class TEmployeeInfoServiceImpl extends ServiceImpl<TEmployeeInfoMapper, T
info
.
setDomainId
(
otherFile
.
getId
());
}
}
// 删除时
// 更新
}
if
(
CommonConstants
.
ONE_STRING
.
equals
(
otherFile
.
getHandleType
())){
if
(
Common
.
isNotNull
(
otherFile
.
getId
())){
empOtherFileService
.
updateById
(
otherFile
);
if
(
Common
.
isNotNull
(
otherFile
.
getAttaList
())){
for
(
TAttaInfo
info:
otherFile
.
getAttaList
()){
info
.
setDomainId
(
otherFile
.
getId
());
}
}
}
// 删除时
}
else
if
(
CommonConstants
.
TWO_STRING
.
equals
(
otherFile
.
getHandleType
())){
empOtherFileService
.
removeById
(
otherFile
.
getId
());
}
...
...
@@ -307,9 +320,20 @@ public class TEmployeeInfoServiceImpl extends ServiceImpl<TEmployeeInfoMapper, T
private
void
getAttaInfo
(
TEmployeeInfo
emp
)
{
List
<
TEmpOtherFile
>
otherFiles
=
otherFileService
.
getListByEmpId
(
emp
.
getId
());
if
(
Common
.
isEmpty
(
otherFiles
)){
if
(
Common
.
isNotNull
(
otherFiles
)){
List
<
TAttaInfo
>
attaInfos
;
for
(
TEmpOtherFile
file:
otherFiles
){
file
.
setAttaList
(
attaInfoService
.
list
(
Wrappers
.<
TAttaInfo
>
query
().
lambda
().
eq
(
TAttaInfo:
:
getDomainId
,
file
.
getId
())));
attaInfos
=
attaInfoService
.
list
(
Wrappers
.<
TAttaInfo
>
query
().
lambda
().
eq
(
TAttaInfo:
:
getDomainId
,
file
.
getId
()));
if
(
Common
.
isNotNull
(
attaInfos
)){
URL
url
;
for
(
TAttaInfo
atta:
attaInfos
){
url
=
ossUtil
.
getObjectUrl
(
null
,
atta
.
getAttaSrc
());
if
(
Common
.
isNotNull
(
url
)){
atta
.
setAttaUrl
(
url
.
toString
());
}
}
}
file
.
setAttaList
(
attaInfos
);
}
}
emp
.
setOtherFiles
(
otherFiles
);
...
...
@@ -923,6 +947,11 @@ public class TEmployeeInfoServiceImpl extends ServiceImpl<TEmployeeInfoMapper, T
errorMsg
.
add
(
EmployeeConstants
.
FILE_PROVINCE
);
errorMsgMap
.
put
(
lineNum
,
new
ErrorMessage
(
EmployeeConstants
.
FILE_PROVINCE
));
}
if
(
Common
.
isEmpty
(
employeeInfo
.
getContactTown
()))
{
errorMsg
.
add
(
EmployeeConstants
.
CONTACT_PROVINCE
);
errorMsgMap
.
put
(
lineNum
,
new
ErrorMessage
(
EmployeeConstants
.
CONTACT_PROVINCE
));
}
if
(
Common
.
isEmpty
(
employeeInfo
.
getContactAddress
()))
{
errorMsg
.
add
(
EmployeeConstants
.
CONTACT_ADDRESS
);
errorMsgMap
.
put
(
lineNum
,
new
ErrorMessage
(
EmployeeConstants
.
CONTACT_ADDRESS
));
...
...
@@ -1398,6 +1427,16 @@ public class TEmployeeInfoServiceImpl extends ServiceImpl<TEmployeeInfoMapper, T
saveEmp
.
setMajor
(
excel
.
getMajor
());
}
}
// 通信地址所在地
if
(
Common
.
isNotNull
(
excel
.
getContactProvince
()))
{
saveEmp
.
setContactProvince
(
excel
.
getContactProvince
());
}
if
(
Common
.
isNotNull
(
excel
.
getContactCity
()))
{
saveEmp
.
setContactCity
(
excel
.
getContactCity
());
}
if
(
Common
.
isNotNull
(
excel
.
getContactTown
()))
{
saveEmp
.
setContactTown
(
excel
.
getContactTown
());
}
if
(
Common
.
isNotNull
(
excel
.
getContactAddress
()))
{
if
(
excel
.
getContactAddress
().
length
()
>
200
)
{
errorMsg
.
add
(
EmployeeConstants
.
CONTACT_ADDRESS_LENGTH
);
...
...
@@ -1911,6 +1950,16 @@ public class TEmployeeInfoServiceImpl extends ServiceImpl<TEmployeeInfoMapper, T
saveEmp
.
setMajor
(
excel
.
getMajor
());
}
}
// 通信地址所在地
if
(
Common
.
isNotNull
(
excel
.
getContactProvince
()))
{
saveEmp
.
setContactProvince
(
excel
.
getContactProvince
());
}
if
(
Common
.
isNotNull
(
excel
.
getContactCity
()))
{
saveEmp
.
setContactCity
(
excel
.
getContactCity
());
}
if
(
Common
.
isNotNull
(
excel
.
getContactTown
()))
{
saveEmp
.
setContactTown
(
excel
.
getContactTown
());
}
if
(
Common
.
isNotNull
(
excel
.
getContactAddress
()))
{
if
(
excel
.
getContactAddress
().
length
()
>
200
)
{
errorMsg
.
add
(
EmployeeConstants
.
CONTACT_ADDRESS_LENGTH
);
...
...
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