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
0b3bad94
Commit
0b3bad94
authored
Jul 25, 2022
by
fangxinjiang
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/develop' into develop
parents
ed7932dd
40856258
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
114 additions
and
339 deletions
+114
-339
EmployeeVO.java
...a/com/yifu/cloud/plus/v1/yifu/archives/vo/EmployeeVO.java
+1
-1
TEmployeeContractInfoServiceImpl.java
...chives/service/impl/TEmployeeContractInfoServiceImpl.java
+3
-1
TSocialFundHistoryVo.java
...fu/cloud/plus/v1/yifu/social/vo/TSocialFundHistoryVo.java
+59
-318
SocialConstants.java
.../cloud/plus/v1/yifu/social/constants/SocialConstants.java
+1
-0
TSocialFundInfoServiceImpl.java
.../yifu/social/service/impl/TSocialFundInfoServiceImpl.java
+50
-19
No files found.
yifu-archives/yifu-archives-api/src/main/java/com/yifu/cloud/plus/v1/yifu/archives/vo/EmployeeVO.java
View file @
0b3bad94
...
@@ -66,7 +66,7 @@ public class EmployeeVO extends RowIndex implements Serializable {
...
@@ -66,7 +66,7 @@ public class EmployeeVO extends RowIndex implements Serializable {
* 项目编码
* 项目编码
*/
*/
@ExcelProperty
(
value
=
"项目编码"
)
@ExcelProperty
(
value
=
"项目编码"
)
@ExcelAttribute
(
name
=
"项目编码"
,
maxLength
=
32
,
needExport
=
true
,
errorInfo
=
"
身份证号
必填且不可超过20位"
)
@ExcelAttribute
(
name
=
"项目编码"
,
maxLength
=
32
,
needExport
=
true
,
errorInfo
=
"
项目编码
必填且不可超过20位"
)
@Size
(
max
=
32
,
message
=
"项目编码不可超过32位"
)
@Size
(
max
=
32
,
message
=
"项目编码不可超过32位"
)
private
String
deptNo
;
private
String
deptNo
;
...
...
yifu-archives/yifu-archives-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/archives/service/impl/TEmployeeContractInfoServiceImpl.java
View file @
0b3bad94
...
@@ -416,10 +416,12 @@ public class TEmployeeContractInfoServiceImpl extends ServiceImpl<TEmployeeContr
...
@@ -416,10 +416,12 @@ public class TEmployeeContractInfoServiceImpl extends ServiceImpl<TEmployeeContr
}
}
if
(
tEmployeeContractInfo
.
getAuditStatus
()
==
CommonConstants
.
dingleDigitIntArray
[
2
])
{
if
(
tEmployeeContractInfo
.
getAuditStatus
()
==
CommonConstants
.
dingleDigitIntArray
[
2
])
{
//
作废、终止,不
变为在用
//
非作废、终止,本条
变为在用
if
(
Common
.
isEmpty
(
contractInfo
.
getSituation
())
if
(
Common
.
isEmpty
(
contractInfo
.
getSituation
())
||
(!
EmployeeConstants
.
SITUATION_SIX
.
equals
(
contractInfo
.
getSituation
())
||
(!
EmployeeConstants
.
SITUATION_SIX
.
equals
(
contractInfo
.
getSituation
())
&&
!
EmployeeConstants
.
SITUATION_SEVEN
.
equals
(
contractInfo
.
getSituation
())))
{
&&
!
EmployeeConstants
.
SITUATION_SEVEN
.
equals
(
contractInfo
.
getSituation
())))
{
// 其他变为不在用
baseMapper
.
updateInUseStatusById
(
contractInfo
.
getEmpId
(),
contractInfo
.
getSettleDomain
(),
contractInfo
.
getId
(),
CommonConstants
.
ONE_STRING
);
tEmployeeContractInfo
.
setAuditTimeLast
(
LocalDateTime
.
now
());
tEmployeeContractInfo
.
setAuditTimeLast
(
LocalDateTime
.
now
());
tEmployeeContractInfo
.
setInUse
(
CommonConstants
.
ZERO_STRING
);
tEmployeeContractInfo
.
setInUse
(
CommonConstants
.
ZERO_STRING
);
// 更新档案、项目合同状态为(1可用)
// 更新档案、项目合同状态为(1可用)
...
...
yifu-social/yifu-social-api/src/main/java/com/yifu/cloud/plus/v1/yifu/social/vo/TSocialFundHistoryVo.java
View file @
0b3bad94
This diff is collapsed.
Click to expand it.
yifu-social/yifu-social-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/social/constants/SocialConstants.java
View file @
0b3bad94
...
@@ -8,4 +8,5 @@ package com.yifu.cloud.plus.v1.yifu.social.constants;
...
@@ -8,4 +8,5 @@ package com.yifu.cloud.plus.v1.yifu.social.constants;
public
class
SocialConstants
{
public
class
SocialConstants
{
// 社保补缴配置有误!
// 社保补缴配置有误!
public
static
final
String
SOCIAL_SET_ERROR
=
"社保补缴配置有误!"
;
public
static
final
String
SOCIAL_SET_ERROR
=
"社保补缴配置有误!"
;
public
static
final
String
EMP_NAME_ERROR
=
"员工姓名错误!"
;
}
}
yifu-social/yifu-social-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/social/service/impl/TSocialFundInfoServiceImpl.java
View file @
0b3bad94
...
@@ -36,15 +36,11 @@ import com.yifu.cloud.plus.v1.yifu.common.core.constant.CommonConstants;
...
@@ -36,15 +36,11 @@ 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.*
;
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.mybatis.base.BaseEntity
;
import
com.yifu.cloud.plus.v1.yifu.common.mybatis.base.BaseEntity
;
import
com.yifu.cloud.plus.v1.yifu.social.entity.TAuditInfo
;
import
com.yifu.cloud.plus.v1.yifu.social.constants.SocialConstants
;
import
com.yifu.cloud.plus.v1.yifu.social.entity.TDispatchInfo
;
import
com.yifu.cloud.plus.v1.yifu.social.entity.*
;
import
com.yifu.cloud.plus.v1.yifu.social.entity.TSocialFundInfo
;
import
com.yifu.cloud.plus.v1.yifu.social.entity.TSocialLog
;
import
com.yifu.cloud.plus.v1.yifu.social.mapper.TSocialFundInfoMapper
;
import
com.yifu.cloud.plus.v1.yifu.social.mapper.TSocialFundInfoMapper
;
import
com.yifu.cloud.plus.v1.yifu.social.service.TAuditInfoService
;
import
com.yifu.cloud.plus.v1.yifu.social.service.*
;
import
com.yifu.cloud.plus.v1.yifu.social.service.TDispatchInfoService
;
import
com.yifu.cloud.plus.v1.yifu.social.vo.TSocialFundHistoryVo
;
import
com.yifu.cloud.plus.v1.yifu.social.service.TSocialFundInfoService
;
import
com.yifu.cloud.plus.v1.yifu.social.service.TSocialLogService
;
import
com.yifu.cloud.plus.v1.yifu.social.vo.TSocialFundInfoDetailVo
;
import
com.yifu.cloud.plus.v1.yifu.social.vo.TSocialFundInfoDetailVo
;
import
com.yifu.cloud.plus.v1.yifu.social.vo.TSocialFundInfoSearchVo
;
import
com.yifu.cloud.plus.v1.yifu.social.vo.TSocialFundInfoSearchVo
;
import
com.yifu.cloud.plus.v1.yifu.social.vo.TSocialFundInfoVo
;
import
com.yifu.cloud.plus.v1.yifu.social.vo.TSocialFundInfoVo
;
...
@@ -58,7 +54,9 @@ import java.io.IOException;
...
@@ -58,7 +54,9 @@ import java.io.IOException;
import
java.io.InputStream
;
import
java.io.InputStream
;
import
java.net.URLEncoder
;
import
java.net.URLEncoder
;
import
java.util.ArrayList
;
import
java.util.ArrayList
;
import
java.util.HashMap
;
import
java.util.List
;
import
java.util.List
;
import
java.util.Map
;
/**
/**
* 社保公积金查询表
* 社保公积金查询表
...
@@ -75,6 +73,7 @@ public class TSocialFundInfoServiceImpl extends ServiceImpl<TSocialFundInfoMappe
...
@@ -75,6 +73,7 @@ public class TSocialFundInfoServiceImpl extends ServiceImpl<TSocialFundInfoMappe
private
final
TDispatchInfoService
tDispatchInfoService
;
private
final
TDispatchInfoService
tDispatchInfoService
;
private
final
TSocialLogService
tSocialLogService
;
private
final
TSocialLogService
tSocialLogService
;
private
final
TAuditInfoService
tAuditInfoService
;
private
final
TAuditInfoService
tAuditInfoService
;
private
final
TForecastLibraryService
tForecastLibraryService
;
/**
/**
* 社保公积金查询表简单分页查询
* 社保公积金查询表简单分页查询
...
@@ -191,12 +190,12 @@ public class TSocialFundInfoServiceImpl extends ServiceImpl<TSocialFundInfoMappe
...
@@ -191,12 +190,12 @@ public class TSocialFundInfoServiceImpl extends ServiceImpl<TSocialFundInfoMappe
@Override
@Override
public
R
<
List
<
ErrorMessage
>>
importDiy
(
InputStream
inputStream
)
{
public
R
<
List
<
ErrorMessage
>>
importDiy
(
InputStream
inputStream
)
{
List
<
ErrorMessage
>
errorMessageList
=
new
ArrayList
<>();
List
<
ErrorMessage
>
errorMessageList
=
new
ArrayList
<>();
ExcelUtil
<
TSocialFund
InfoVo
>
util1
=
new
ExcelUtil
<>(
TSocialFundInfo
Vo
.
class
);
ExcelUtil
<
TSocialFund
HistoryVo
>
util1
=
new
ExcelUtil
<>(
TSocialFundHistory
Vo
.
class
);
// 写法2:
// 写法2:
// 匿名内部类 不用额外写一个DemoDataListener
// 匿名内部类 不用额外写一个DemoDataListener
// 这里 需要指定读用哪个class去读,然后读取第一个sheet 文件流会自动关闭
// 这里 需要指定读用哪个class去读,然后读取第一个sheet 文件流会自动关闭
try
{
try
{
EasyExcel
.
read
(
inputStream
,
TSocialFundInfoVo
.
class
,
new
ReadListener
<
TSocialFund
Info
Vo
>()
{
EasyExcel
.
read
(
inputStream
,
TSocialFundInfoVo
.
class
,
new
ReadListener
<
TSocialFund
History
Vo
>()
{
/**
/**
* 单次缓存的数据量
* 单次缓存的数据量
*/
*/
...
@@ -204,10 +203,10 @@ public class TSocialFundInfoServiceImpl extends ServiceImpl<TSocialFundInfoMappe
...
@@ -204,10 +203,10 @@ public class TSocialFundInfoServiceImpl extends ServiceImpl<TSocialFundInfoMappe
/**
/**
*临时存储
*临时存储
*/
*/
private
List
<
TSocialFund
Info
Vo
>
cachedDataList
=
ListUtils
.
newArrayListWithExpectedSize
(
BATCH_COUNT
);
private
List
<
TSocialFund
History
Vo
>
cachedDataList
=
ListUtils
.
newArrayListWithExpectedSize
(
BATCH_COUNT
);
@Override
@Override
public
void
invoke
(
TSocialFund
Info
Vo
data
,
AnalysisContext
context
)
{
public
void
invoke
(
TSocialFund
History
Vo
data
,
AnalysisContext
context
)
{
ReadRowHolder
readRowHolder
=
context
.
readRowHolder
();
ReadRowHolder
readRowHolder
=
context
.
readRowHolder
();
Integer
rowIndex
=
readRowHolder
.
getRowIndex
();
Integer
rowIndex
=
readRowHolder
.
getRowIndex
();
data
.
setRowIndex
(
rowIndex
+
1
);
data
.
setRowIndex
(
rowIndex
+
1
);
...
@@ -245,24 +244,56 @@ public class TSocialFundInfoServiceImpl extends ServiceImpl<TSocialFundInfoMappe
...
@@ -245,24 +244,56 @@ public class TSocialFundInfoServiceImpl extends ServiceImpl<TSocialFundInfoMappe
return
R
.
ok
(
errorMessageList
);
return
R
.
ok
(
errorMessageList
);
}
}
private
void
importTSocialFundInfo
(
List
<
TSocialFund
Info
Vo
>
excelVOList
,
List
<
ErrorMessage
>
errorMessageList
)
{
private
void
importTSocialFundInfo
(
List
<
TSocialFund
History
Vo
>
excelVOList
,
List
<
ErrorMessage
>
errorMessageList
)
{
// 个性化校验逻辑
// 个性化校验逻辑
ErrorMessage
errorMsg
;
ErrorMessage
errorMsg
;
// 执行数据插入操作 组装
// 执行数据插入操作 组装
TSocialFundHistoryVo
excel
;
List
<
String
>
idCardList
=
new
ArrayList
<>();
for
(
int
i
=
0
;
i
<
excelVOList
.
size
();
i
++)
{
idCardList
.
add
(
excelVOList
.
get
(
i
).
getIdCard
());
}
List
<
TSocialFundInfo
>
socialFundInfoList
=
this
.
list
(
Wrappers
.<
TSocialFundInfo
>
query
().
lambda
()
.
in
(
TSocialFundInfo:
:
getEmpIdcard
,
idCardList
));
Map
<
String
,
TSocialFundInfo
>
socialFundInfoMap
=
new
HashMap
<>();
if
(
socialFundInfoList
!=
null
&&
!
socialFundInfoList
.
isEmpty
())
{
for
(
TSocialFundInfo
socialFundInfo
:
socialFundInfoList
)
{
socialFundInfoMap
.
put
(
socialFundInfo
.
getEmpIdcard
(),
socialFundInfo
);
}
socialFundInfoList
.
clear
();
}
TSocialFundInfo
oldSocialFundInfo
;
TSocialFundInfo
socialFundInfo
;
for
(
int
i
=
0
;
i
<
excelVOList
.
size
();
i
++)
{
for
(
int
i
=
0
;
i
<
excelVOList
.
size
();
i
++)
{
TSocialFundInfoVo
excel
=
excelVOList
.
get
(
i
);
excel
=
excelVOList
.
get
(
i
);
// 数据合法情况 TODO
socialFundInfo
=
socialFundInfoMap
.
get
(
excel
.
getIdCard
());
if
(
socialFundInfo
.
getEmpName
().
equals
(
excel
.
getName
()))
{
// 插入
// 0:校验数据有效性-TODO
// 1:更新社保公积金查询-TODO
//updateSocialFundInfo(socialFundInfo, excel);
// 2:新增调基记录
insertExcel
(
excel
);
insertExcel
(
excel
);
errorMessageList
.
add
(
new
ErrorMessage
(
excel
.
getRowIndex
(),
CommonConstants
.
SAVE_SUCCESS
));
// 3:新增变更日志
oldSocialFundInfo
=
new
TSocialFundInfo
();
BeanUtil
.
copyProperties
(
socialFundInfo
,
oldSocialFundInfo
);
tSocialLogService
.
saveModificationRecord
(
CommonConstants
.
ONE_INT
,
oldSocialFundInfo
.
getId
(),
oldSocialFundInfo
,
socialFundInfo
);
// 4:同步预估库-TODO
//tForecastLibraryService.
errorMessageList
.
add
(
new
ErrorMessage
(
excel
.
getRowIndex
(),
CommonConstants
.
SAVE_SUCCESS
,
CommonConstants
.
GREEN
));
}
else
{
errorMessageList
.
add
(
new
ErrorMessage
(
excel
.
getRowIndex
(),
SocialConstants
.
EMP_NAME_ERROR
));
}
}
}
}
}
/**
/**
* 插入excel bad record
* 插入excel bad record
*/
*/
private
void
insertExcel
(
TSocialFund
Info
Vo
excel
)
{
private
void
insertExcel
(
TSocialFund
History
Vo
excel
)
{
TSocialFundInfo
insert
=
new
TSocialFundInfo
();
TSocialFundInfo
insert
=
new
TSocialFundInfo
();
BeanUtil
.
copyProperties
(
excel
,
insert
);
BeanUtil
.
copyProperties
(
excel
,
insert
);
this
.
save
(
insert
);
this
.
save
(
insert
);
...
...
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