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
fcad5961
Commit
fcad5961
authored
Jul 25, 2022
by
hongguangwu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
合同变更-仅作废之前选的合同
parent
c660337b
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 @
fcad5961
...
@@ -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 @
fcad5961
...
@@ -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 @
fcad5961
...
@@ -17,8 +17,6 @@
...
@@ -17,8 +17,6 @@
package
com
.
yifu
.
cloud
.
plus
.
v1
.
yifu
.
social
.
vo
;
package
com
.
yifu
.
cloud
.
plus
.
v1
.
yifu
.
social
.
vo
;
import
com.alibaba.excel.annotation.ExcelProperty
;
import
com.alibaba.excel.annotation.ExcelProperty
;
import
com.baomidou.mybatisplus.annotation.IdType
;
import
com.baomidou.mybatisplus.annotation.TableId
;
import
com.yifu.cloud.plus.v1.yifu.common.core.constant.ExcelAttribute
;
import
com.yifu.cloud.plus.v1.yifu.common.core.constant.ExcelAttribute
;
import
com.yifu.cloud.plus.v1.yifu.common.core.vo.RowIndex
;
import
com.yifu.cloud.plus.v1.yifu.common.core.vo.RowIndex
;
import
io.swagger.v3.oas.annotations.media.Schema
;
import
io.swagger.v3.oas.annotations.media.Schema
;
...
@@ -29,7 +27,7 @@ import java.io.Serializable;
...
@@ -29,7 +27,7 @@ import java.io.Serializable;
import
java.math.BigDecimal
;
import
java.math.BigDecimal
;
/**
/**
* 社保公积金调基
历史记录
表
* 社保公积金调基
导出
表
*
*
* @author fxj
* @author fxj
* @date 2022-07-15 11:38:05
* @date 2022-07-15 11:38:05
...
@@ -37,332 +35,75 @@ import java.math.BigDecimal;
...
@@ -37,332 +35,75 @@ import java.math.BigDecimal;
@Data
@Data
public
class
TSocialFundHistoryVo
extends
RowIndex
implements
Serializable
{
public
class
TSocialFundHistoryVo
extends
RowIndex
implements
Serializable
{
/**
@ExcelProperty
(
value
=
"项目编码"
)
* id
private
String
deptNo
;
*/
@TableId
(
type
=
IdType
.
ASSIGN_ID
)
@Length
(
max
=
20
,
message
=
"员工姓名 不能超过20 个字符"
)
@Schema
(
description
=
"id"
)
@ExcelAttribute
(
name
=
"员工姓名"
,
isNotEmpty
=
true
,
maxLength
=
20
,
needExport
=
true
,
errorInfo
=
"员工姓名必填且不可超过20位"
)
@ExcelProperty
(
"id"
)
@Schema
(
description
=
"员工姓名"
)
private
String
id
;
@ExcelProperty
(
"员工姓名"
)
/**
* name
*/
@Length
(
max
=
20
,
message
=
"name 不能超过20 个字符"
)
@ExcelAttribute
(
name
=
"name"
,
maxLength
=
20
)
@Schema
(
description
=
"name"
)
@ExcelProperty
(
"name"
)
private
String
name
;
private
String
name
;
/**
* idCard
@Length
(
max
=
20
,
message
=
"身份证号 不能超过20 个字符"
)
*/
@ExcelAttribute
(
name
=
"身份证号"
,
isNotEmpty
=
true
,
maxLength
=
20
,
needExport
=
true
,
errorInfo
=
"身份证号必填且不可超过20位"
)
@Length
(
max
=
20
,
message
=
"idCard 不能超过20 个字符"
)
@Schema
(
description
=
"身份证号"
)
@ExcelAttribute
(
name
=
"idCard"
,
maxLength
=
20
)
@ExcelProperty
(
"身份证号"
)
@Schema
(
description
=
"idCard"
)
@ExcelProperty
(
"idCard"
)
private
String
idCard
;
private
String
idCard
;
/**
* employeeId
@ExcelAttribute
(
name
=
"缴纳类型"
,
isNotEmpty
=
true
,
errorInfo
=
"缴纳类型必填"
,
readConverterExp
=
"0=最低缴纳,1=自定义缴纳,2=最高缴纳"
)
*/
@Schema
(
description
=
"缴纳类型(0最低缴纳、1自定义缴纳、2最高缴纳)"
)
@Length
(
max
=
32
,
message
=
"employeeId 不能超过32 个字符"
)
@ExcelProperty
(
"缴纳类型"
)
@ExcelAttribute
(
name
=
"employeeId"
,
maxLength
=
32
)
private
String
paymentType
;
@Schema
(
description
=
"employeeId"
)
@ExcelProperty
(
"employeeId"
)
@ExcelAttribute
(
name
=
"养老基数"
)
private
String
employeeId
;
@Schema
(
description
=
"养老基数"
)
/**
@ExcelProperty
(
"养老基数"
)
* 单位养老基数
*/
@ExcelAttribute
(
name
=
"单位养老基数"
)
@Schema
(
description
=
"单位养老基数"
)
@ExcelProperty
(
"单位养老基数"
)
private
BigDecimal
unitPensionBase
;
private
BigDecimal
unitPensionBase
;
/**
@ExcelAttribute
(
name
=
"医疗基数"
)
* 单位医疗基数
@Schema
(
description
=
"医疗基数"
)
*/
@ExcelProperty
(
"医疗基数"
)
@ExcelAttribute
(
name
=
"单位医疗基数"
)
@Schema
(
description
=
"单位医疗基数"
)
@ExcelProperty
(
"单位医疗基数"
)
private
BigDecimal
unitMedicalBase
;
private
BigDecimal
unitMedicalBase
;
/**
@ExcelAttribute
(
name
=
"失业基数"
)
* 单位失业基数
@Schema
(
description
=
"失业基数"
)
*/
@ExcelProperty
(
"失业基数"
)
@ExcelAttribute
(
name
=
"单位失业基数"
)
@Schema
(
description
=
"单位失业基数"
)
@ExcelProperty
(
"单位失业基数"
)
private
BigDecimal
unitUnemploymentBase
;
private
BigDecimal
unitUnemploymentBase
;
/**
@ExcelAttribute
(
name
=
"工伤基数"
)
* 单位工伤基数
@Schema
(
description
=
"工伤基数"
)
*/
@ExcelProperty
(
"工伤基数"
)
@ExcelAttribute
(
name
=
"单位工伤基数"
)
@Schema
(
description
=
"单位工伤基数"
)
@ExcelProperty
(
"单位工伤基数"
)
private
BigDecimal
unitInjuryBase
;
private
BigDecimal
unitInjuryBase
;
/**
@ExcelAttribute
(
name
=
"生育基数"
)
* 单位生育基数
@Schema
(
description
=
"生育基数"
)
*/
@ExcelProperty
(
"生育基数"
)
@ExcelAttribute
(
name
=
"单位生育基数"
)
@Schema
(
description
=
"单位生育基数"
)
@ExcelProperty
(
"单位生育基数"
)
private
BigDecimal
unitBirthBase
;
private
BigDecimal
unitBirthBase
;
/**
* 单位大病基数
@ExcelAttribute
(
name
=
"单位大病救助金额"
)
*/
@Schema
(
description
=
"单位大病救助金额"
)
@ExcelAttribute
(
name
=
"单位大病基数"
)
@ExcelProperty
(
"单位大病救助金额"
)
@Schema
(
description
=
"单位大病基数"
)
@ExcelProperty
(
"单位大病基数"
)
private
BigDecimal
unitBigailmentBase
;
/**
* 个人养老基数
*/
@ExcelAttribute
(
name
=
"个人养老基数"
)
@Schema
(
description
=
"个人养老基数"
)
@ExcelProperty
(
"个人养老基数"
)
private
BigDecimal
personalPensionBase
;
/**
* 个人医疗基数
*/
@ExcelAttribute
(
name
=
"个人医疗基数"
)
@Schema
(
description
=
"个人医疗基数"
)
@ExcelProperty
(
"个人医疗基数"
)
private
BigDecimal
personalMedicalBase
;
/**
* 个人失业基数
*/
@ExcelAttribute
(
name
=
"个人失业基数"
)
@Schema
(
description
=
"个人失业基数"
)
@ExcelProperty
(
"个人失业基数"
)
private
BigDecimal
personalUnemploymentBase
;
/**
* 个人大病基数
*/
@ExcelAttribute
(
name
=
"个人大病基数"
)
@Schema
(
description
=
"个人大病基数"
)
@ExcelProperty
(
"个人大病基数"
)
private
BigDecimal
personalBigailmentBase
;
/**
* 单位养老比例
*/
@ExcelAttribute
(
name
=
"单位养老比例"
)
@Schema
(
description
=
"单位养老比例"
)
@ExcelProperty
(
"单位养老比例"
)
private
BigDecimal
unitPersionPro
;
/**
* unitPersionMoney
*/
@ExcelAttribute
(
name
=
"unitPersionMoney"
)
@Schema
(
description
=
"unitPersionMoney"
)
@ExcelProperty
(
"unitPersionMoney"
)
private
BigDecimal
unitPersionMoney
;
/**
* 单位医疗比例
*/
@ExcelAttribute
(
name
=
"单位医疗比例"
)
@Schema
(
description
=
"单位医疗比例"
)
@ExcelProperty
(
"单位医疗比例"
)
private
BigDecimal
unitMedicalPro
;
/**
* unitMedicalMoney
*/
@ExcelAttribute
(
name
=
"unitMedicalMoney"
)
@Schema
(
description
=
"unitMedicalMoney"
)
@ExcelProperty
(
"unitMedicalMoney"
)
private
BigDecimal
unitMedicalMoney
;
/**
* 单位失业比例
*/
@ExcelAttribute
(
name
=
"单位失业比例"
)
@Schema
(
description
=
"单位失业比例"
)
@ExcelProperty
(
"单位失业比例"
)
private
BigDecimal
unitUnemploymentPro
;
/**
* unitUnemploymentMoney
*/
@ExcelAttribute
(
name
=
"unitUnemploymentMoney"
)
@Schema
(
description
=
"unitUnemploymentMoney"
)
@ExcelProperty
(
"unitUnemploymentMoney"
)
private
BigDecimal
unitUnemploymentMoney
;
/**
* 单位工伤比例
*/
@ExcelAttribute
(
name
=
"单位工伤比例"
)
@Schema
(
description
=
"单位工伤比例"
)
@ExcelProperty
(
"单位工伤比例"
)
private
BigDecimal
unitInjuryPro
;
/**
* unitInjuryMoney
*/
@ExcelAttribute
(
name
=
"unitInjuryMoney"
)
@Schema
(
description
=
"unitInjuryMoney"
)
@ExcelProperty
(
"unitInjuryMoney"
)
private
BigDecimal
unitInjuryMoney
;
/**
* 单位生育比例
*/
@ExcelAttribute
(
name
=
"单位生育比例"
)
@Schema
(
description
=
"单位生育比例"
)
@ExcelProperty
(
"单位生育比例"
)
private
BigDecimal
unitBirthPro
;
/**
* unitBirthMoney
*/
@ExcelAttribute
(
name
=
"unitBirthMoney"
)
@Schema
(
description
=
"unitBirthMoney"
)
@ExcelProperty
(
"unitBirthMoney"
)
private
BigDecimal
unitBirthMoney
;
/**
* 单位大病比例
*/
@ExcelAttribute
(
name
=
"单位大病比例"
)
@Schema
(
description
=
"单位大病比例"
)
@ExcelProperty
(
"单位大病比例"
)
private
BigDecimal
unitBigailmentPro
;
/**
* unitBigailmentMoney
*/
@ExcelAttribute
(
name
=
"unitBigailmentMoney"
)
@Schema
(
description
=
"unitBigailmentMoney"
)
@ExcelProperty
(
"unitBigailmentMoney"
)
private
BigDecimal
unitBigailmentMoney
;
private
BigDecimal
unitBigailmentMoney
;
/**
* 个人养老比例
@ExcelAttribute
(
name
=
"个人大病救助金额"
)
*/
@Schema
(
description
=
"个人大病救助金额"
)
@ExcelAttribute
(
name
=
"个人养老比例"
)
@ExcelProperty
(
"个人大病救助金额"
)
@Schema
(
description
=
"个人养老比例"
)
@ExcelProperty
(
"个人养老比例"
)
private
BigDecimal
personalPersionPro
;
/**
* personalPersionMoney
*/
@ExcelAttribute
(
name
=
"personalPersionMoney"
)
@Schema
(
description
=
"personalPersionMoney"
)
@ExcelProperty
(
"personalPersionMoney"
)
private
BigDecimal
personalPersionMoney
;
/**
* 个人医疗比例
*/
@ExcelAttribute
(
name
=
"个人医疗比例"
)
@Schema
(
description
=
"个人医疗比例"
)
@ExcelProperty
(
"个人医疗比例"
)
private
BigDecimal
personalMedicalPro
;
/**
* personalMedicalMoney
*/
@ExcelAttribute
(
name
=
"personalMedicalMoney"
)
@Schema
(
description
=
"personalMedicalMoney"
)
@ExcelProperty
(
"personalMedicalMoney"
)
private
BigDecimal
personalMedicalMoney
;
/**
* 个人失业比例
*/
@ExcelAttribute
(
name
=
"个人失业比例"
)
@Schema
(
description
=
"个人失业比例"
)
@ExcelProperty
(
"个人失业比例"
)
private
BigDecimal
personalUnemploymentPro
;
/**
* personalUnemploymentMoney
*/
@ExcelAttribute
(
name
=
"personalUnemploymentMoney"
)
@Schema
(
description
=
"personalUnemploymentMoney"
)
@ExcelProperty
(
"personalUnemploymentMoney"
)
private
BigDecimal
personalUnemploymentMoney
;
/**
* 个人大病比例
*/
@ExcelAttribute
(
name
=
"个人大病比例"
)
@Schema
(
description
=
"个人大病比例"
)
@ExcelProperty
(
"个人大病比例"
)
private
BigDecimal
personalBigailmentPro
;
/**
* personalBigailmentMoney
*/
@ExcelAttribute
(
name
=
"personalBigailmentMoney"
)
@Schema
(
description
=
"personalBigailmentMoney"
)
@ExcelProperty
(
"personalBigailmentMoney"
)
private
BigDecimal
personalBigailmentMoney
;
private
BigDecimal
personalBigailmentMoney
;
/**
* 单位公积金基数
@ExcelAttribute
(
name
=
"单位公积金基数"
)
*/
@Schema
(
description
=
"单位公积金基数"
)
@ExcelAttribute
(
name
=
"单位公积金基数"
)
@ExcelProperty
(
"单位公积金基数"
)
@Schema
(
description
=
"单位公积金基数"
)
@ExcelProperty
(
"单位公积金基数"
)
private
BigDecimal
unitFundBase
;
private
BigDecimal
unitFundBase
;
/**
* 个人公积金基数
@ExcelAttribute
(
name
=
"单位公积金比例"
)
*/
@Schema
(
description
=
"单位公积金比例"
)
@ExcelAttribute
(
name
=
"个人公积金基数"
)
@ExcelProperty
(
"单位公积金比例"
)
@Schema
(
description
=
"个人公积金基数"
)
@ExcelProperty
(
"个人公积金基数"
)
private
BigDecimal
personalFundBase
;
/**
* 单位公积金比例
*/
@ExcelAttribute
(
name
=
"单位公积金比例"
)
@Schema
(
description
=
"单位公积金比例"
)
@ExcelProperty
(
"单位公积金比例"
)
private
BigDecimal
unitFundProp
;
private
BigDecimal
unitFundProp
;
/**
* 个人公积金比例
@ExcelAttribute
(
name
=
"个人公积金基数"
)
*/
@Schema
(
description
=
"个人公积金基数"
)
@ExcelAttribute
(
name
=
"个人公积金比例"
)
@ExcelProperty
(
"个人公积金基数"
)
@Schema
(
description
=
"个人公积金比例"
)
private
BigDecimal
personalFundBase
;
@ExcelProperty
(
"个人公积金比例"
)
@ExcelAttribute
(
name
=
"个人公积金比例"
)
@Schema
(
description
=
"个人公积金比例"
)
@ExcelProperty
(
"个人公积金比例"
)
private
BigDecimal
personalFundProp
;
private
BigDecimal
personalFundProp
;
/**
* unitFundMoney
*/
@ExcelAttribute
(
name
=
"unitFundMoney"
)
@Schema
(
description
=
"unitFundMoney"
)
@ExcelProperty
(
"unitFundMoney"
)
private
BigDecimal
unitFundMoney
;
/**
* personalFundMoney
*/
@ExcelAttribute
(
name
=
"personalFundMoney"
)
@Schema
(
description
=
"personalFundMoney"
)
@ExcelProperty
(
"personalFundMoney"
)
private
BigDecimal
personalFundMoney
;
/**
* 0老的调基,数据不对,将不使用;1新逻辑调基
*/
@ExcelAttribute
(
name
=
"0老的调基,数据不对,将不使用;1新逻辑调基"
)
@Schema
(
description
=
"0老的调基,数据不对,将不使用;1新逻辑调基"
)
@ExcelProperty
(
"0老的调基,数据不对,将不使用;1新逻辑调基"
)
private
Integer
isOld
;
/**
* 缴纳类型(0最低缴纳、1自定义缴纳、2最高缴纳)
*/
@ExcelAttribute
(
name
=
"缴纳类型(0最低缴纳、1自定义缴纳、2最高缴纳)"
)
@Schema
(
description
=
"缴纳类型(0最低缴纳、1自定义缴纳、2最高缴纳)"
)
@ExcelProperty
(
"缴纳类型(0最低缴纳、1自定义缴纳、2最高缴纳)"
)
private
Integer
paymentType
;
/**
* 是否是社保:0否1是
*/
@ExcelAttribute
(
name
=
"是否是社保:0否1是"
)
@Schema
(
description
=
"是否是社保:0否1是"
)
@ExcelProperty
(
"是否是社保:0否1是"
)
private
Integer
isSocial
;
/**
* 是否是公积金:0否1是
*/
@ExcelAttribute
(
name
=
"是否是公积金:0否1是"
)
@Schema
(
description
=
"是否是公积金:0否1是"
)
@ExcelProperty
(
"是否是公积金:0否1是"
)
private
Integer
isFund
;
/**
* 社保id
*/
@Length
(
max
=
32
,
message
=
"社保id 不能超过32 个字符"
)
@ExcelAttribute
(
name
=
"社保id"
,
maxLength
=
32
)
@Schema
(
description
=
"社保id"
)
@ExcelProperty
(
"社保id"
)
private
String
socialId
;
/**
* 公积金id
*/
@Length
(
max
=
32
,
message
=
"公积金id 不能超过32 个字符"
)
@ExcelAttribute
(
name
=
"公积金id"
,
maxLength
=
32
)
@Schema
(
description
=
"公积金id"
)
@ExcelProperty
(
"公积金id"
)
private
String
fundId
;
}
}
yifu-social/yifu-social-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/social/constants/SocialConstants.java
View file @
fcad5961
...
@@ -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 @
fcad5961
...
@@ -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