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
25c396b5
Commit
25c396b5
authored
Nov 22, 2022
by
fangxinjiang
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/develop' into develop
parents
0ff98dd3
739a5365
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
109 additions
and
42 deletions
+109
-42
EmployeeConstants.java
...ud/plus/v1/yifu/archives/constants/EmployeeConstants.java
+1
-3
TEmployeeProjectMapper.java
.../plus/v1/yifu/archives/mapper/TEmployeeProjectMapper.java
+2
-0
TEmployeeProjectServiceImpl.java
...fu/archives/service/impl/TEmployeeProjectServiceImpl.java
+17
-25
DoJointTask.java
...m/yifu/cloud/plus/v1/yifu/archives/utils/DoJointTask.java
+18
-4
TEmployeeProjectMapper.xml
...-biz/src/main/resources/mapper/TEmployeeProjectMapper.xml
+33
-1
TIncomeServiceImpl.java
.../plus/v1/yifu/social/service/impl/TIncomeServiceImpl.java
+38
-9
No files found.
yifu-archives/yifu-archives-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/archives/constants/EmployeeConstants.java
View file @
25c396b5
...
@@ -48,6 +48,7 @@ public class EmployeeConstants {
...
@@ -48,6 +48,7 @@ public class EmployeeConstants {
public
static
final
String
CONTRACT_START_EMPTY
=
"起始日期不能为空"
;
public
static
final
String
CONTRACT_START_EMPTY
=
"起始日期不能为空"
;
public
static
final
String
POST_EMPTY
=
"合同岗位不能为空"
;
public
static
final
String
POST_EMPTY
=
"合同岗位不能为空"
;
public
static
final
String
WORKING_HOURS_EMPTY
=
"工时制不能为空"
;
public
static
final
String
WORKING_HOURS_EMPTY
=
"工时制不能为空"
;
public
static
final
String
EXIT_PRIJECT_STATUS
=
"人员已有该项目信息,禁止重复添加"
;
public
static
final
String
CONTRACT_REDUCE_INFO_NOT_EMPTY
=
"合同终止时离职日期和减少原因必填"
;
public
static
final
String
CONTRACT_REDUCE_INFO_NOT_EMPTY
=
"合同终止时离职日期和减少原因必填"
;
...
@@ -55,9 +56,6 @@ public class EmployeeConstants {
...
@@ -55,9 +56,6 @@ public class EmployeeConstants {
* 无数据可更新
* 无数据可更新
**/
**/
public
static
final
String
NO_DATA_UPDATE
=
"无数据可更新"
;
public
static
final
String
NO_DATA_UPDATE
=
"无数据可更新"
;
public
static
final
String
NO_DATA
=
"无数据"
;
public
static
final
String
FILE_EXPORT_EXCEPTION
=
"档案导出异常"
;
public
static
final
String
CONCART_EXPORT_EXCEPTION
=
"合同导出异常"
;
public
static
final
String
CONCART_ALL_EXPORT_EXCEPTION
=
"合同[合并]导出异常"
;
public
static
final
String
CONCART_ALL_EXPORT_EXCEPTION
=
"合同[合并]导出异常"
;
/**
/**
...
...
yifu-archives/yifu-archives-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/archives/mapper/TEmployeeProjectMapper.java
View file @
25c396b5
...
@@ -40,6 +40,8 @@ public interface TEmployeeProjectMapper extends BaseMapper<TEmployeeProject> {
...
@@ -40,6 +40,8 @@ public interface TEmployeeProjectMapper extends BaseMapper<TEmployeeProject> {
void
updateExcelEmpProject
(
@Param
(
"list"
)
List
<
TEmployeeProject
>
list
);
void
updateExcelEmpProject
(
@Param
(
"list"
)
List
<
TEmployeeProject
>
list
);
void
updateReduceEmpProject
(
@Param
(
"list"
)
List
<
TEmployeeProject
>
list
);
int
insertExcelEmpProject
(
@Param
(
"list"
)
List
<
TEmployeeProject
>
list
);
int
insertExcelEmpProject
(
@Param
(
"list"
)
List
<
TEmployeeProject
>
list
);
void
updateEmpIdById
(
@Param
(
"list"
)
List
<
TEmployeeInfo
>
list
);
void
updateEmpIdById
(
@Param
(
"list"
)
List
<
TEmployeeInfo
>
list
);
...
...
yifu-archives/yifu-archives-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/archives/service/impl/TEmployeeProjectServiceImpl.java
View file @
25c396b5
...
@@ -582,7 +582,6 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
...
@@ -582,7 +582,6 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
}
else
{
}
else
{
TEmployeeProject
tEmployeeProjectOld
=
this
.
getById
(
tEmployeeProject
.
getId
());
TEmployeeProject
tEmployeeProjectOld
=
this
.
getById
(
tEmployeeProject
.
getId
());
tEmployeeProject
.
setProjectStatus
(
CommonConstants
.
dingleDigitIntArray
[
1
]);
tEmployeeProject
.
setProjectStatus
(
CommonConstants
.
dingleDigitIntArray
[
1
]);
tEmployeeProject
.
setLeaveReason
(
excel
.
getLeaveReason
());
tEmployeeProject
.
setLeaveReason
(
excel
.
getLeaveReason
());
tEmployeeProject
.
setLeaveRemark
(
excel
.
getLeaveRemark
());
tEmployeeProject
.
setLeaveRemark
(
excel
.
getLeaveRemark
());
tEmployeeProject
.
setLeaveTime
(
LocalDateTime
.
now
());
tEmployeeProject
.
setLeaveTime
(
LocalDateTime
.
now
());
...
@@ -607,17 +606,17 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
...
@@ -607,17 +606,17 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
return
R
.
failed
(
errorMessageList
);
return
R
.
failed
(
errorMessageList
);
}
else
{
}
else
{
//更新项目档案
//更新项目档案
if
(
updProjectList
.
size
()
>
CommonConstants
.
dingleDigitIntArray
[
0
]
)
{
if
(
!
updProjectList
.
isEmpty
()
)
{
this
.
updateBatchById
(
updProjectList
);
baseMapper
.
updateReduceEmpProject
(
updProjectList
);
}
}
//更新人员档案
//更新人员档案
if
(
updList
.
size
()
>
CommonConstants
.
dingleDigitIntArray
[
0
]
)
{
if
(
!
updList
.
isEmpty
()
)
{
List
<
TEmployeeInfo
>
updEmpInfoList
=
updList
.
stream
().
distinct
().
collect
(
Collectors
.
toList
());
List
<
TEmployeeInfo
>
updEmpInfoList
=
updList
.
stream
().
distinct
().
collect
(
Collectors
.
toList
());
YifuUser
user
=
SecurityUtils
.
getUser
();
YifuUser
user
=
SecurityUtils
.
getUser
();
doJointTask
.
doUpdateEmployeeInfo
(
updEmpInfoList
,
user
);
doJointTask
.
doUpdateEmployeeInfo
(
updEmpInfoList
,
user
);
}
}
// 记录变更日志
// 记录变更日志
if
(
updateProjectList
.
size
()
>
CommonConstants
.
dingleDigitIntArray
[
0
]
)
{
if
(
!
updateProjectList
.
isEmpty
()
)
{
for
(
EmployeeProjectNewOldVO
newOldVO
:
updateProjectList
)
{
for
(
EmployeeProjectNewOldVO
newOldVO
:
updateProjectList
)
{
tEmployeeLogService
.
saveModificationRecord
(
CommonConstants
.
dingleDigitIntArray
[
1
]
tEmployeeLogService
.
saveModificationRecord
(
CommonConstants
.
dingleDigitIntArray
[
1
]
,
""
,
newOldVO
.
getNewProjectEmployee
().
getId
()
,
""
,
newOldVO
.
getNewProjectEmployee
().
getId
()
...
@@ -727,7 +726,8 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
...
@@ -727,7 +726,8 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
}
}
}
}
if
(
idCardMap
.
get
(
idCard
.
concat
(
deptNo
))
!=
null
)
{
if
(
idCardMap
.
get
(
idCard
.
concat
(
deptNo
))
!=
null
)
{
errorMessageList
.
add
(
new
ErrorMessage
(
excel
.
getRowIndex
(),
"第"
+
(
excel
.
getRowIndex
())
+
"行身份证号+项目编码与第"
+
idCardMap
.
get
(
idCard
)
+
"行重复!"
));
errorMessageList
.
add
(
new
ErrorMessage
(
excel
.
getRowIndex
(),
"第"
+
(
excel
.
getRowIndex
())
+
"行身份证号+项目编码与第"
+
idCardMap
.
get
(
idCard
)
+
"行重复!"
));
}
else
{
}
else
{
idCardMap
.
put
(
idCard
.
concat
(
deptNo
),
i
+
2
);
idCardMap
.
put
(
idCard
.
concat
(
deptNo
),
i
+
2
);
}
}
...
@@ -751,11 +751,15 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
...
@@ -751,11 +751,15 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
.
eq
(
TEmployeeProject:
:
getDeptNo
,
excel
.
getDeptNo
())
.
eq
(
TEmployeeProject:
:
getDeptNo
,
excel
.
getDeptNo
())
.
eq
(
TEmployeeProject:
:
getDeleteFlag
,
CommonConstants
.
STATUS_NORMAL
));
.
eq
(
TEmployeeProject:
:
getDeleteFlag
,
CommonConstants
.
STATUS_NORMAL
));
//状态为草稿、已审核
if
(
Common
.
isNotNull
(
tEmployeeProject
)
&&
(
CommonConstants
.
dingleDigitIntArray
[
0
]
==
tEmployeeProject
.
getStatus
()
||
CommonConstants
.
dingleDigitIntArray
[
1
]
==
tEmployeeProject
.
getStatus
()))
{
errorMessageList
.
add
(
new
ErrorMessage
(
excel
.
getRowIndex
(),
EmployeeConstants
.
EXIT_PRIJECT_STATUS
));
}
//不存在复档或复项的情况
//不存在复档或复项的情况
//档案无(在档人员、离职库皆无),项目无
//档案无(在档人员、离职库皆无),项目无
if
(
Common
.
isEmpty
(
tEmployeeInfo
)
&&
Common
.
isEmpty
(
tEmployeeProject
))
{
if
(
Common
.
isEmpty
(
tEmployeeInfo
)
&&
Common
.
isEmpty
(
tEmployeeProject
))
{
errorMessageList
.
add
(
new
ErrorMessage
(
excel
.
getRowIndex
(),
MsgUtils
.
getMessage
(
ErrorCodes
.
CHECKS_EXIT_EMPPROJECT_ERROR
)));
errorMessageList
.
add
(
new
ErrorMessage
(
excel
.
getRowIndex
(),
MsgUtils
.
getMessage
(
ErrorCodes
.
CHECKS_EXIT_EMPPROJECT_ERROR
)));
//档案有(在档人员),项目无
//档案有(在档人员),项目无
}
else
if
(
Common
.
isNotNull
(
tEmployeeInfo
)
&&
Common
.
isEmpty
(
tEmployeeProject
)
}
else
if
(
Common
.
isNotNull
(
tEmployeeInfo
)
&&
Common
.
isEmpty
(
tEmployeeProject
)
&&
CommonConstants
.
dingleDigitIntArray
[
0
]
==
tEmployeeInfo
.
getFileStatus
())
{
&&
CommonConstants
.
dingleDigitIntArray
[
0
]
==
tEmployeeInfo
.
getFileStatus
())
{
...
@@ -845,14 +849,14 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
...
@@ -845,14 +849,14 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
if
(
CollUtil
.
isEmpty
(
errorMessageList
))
{
if
(
CollUtil
.
isEmpty
(
errorMessageList
))
{
try
{
try
{
if
(
updateList
.
size
()
>
CommonConstants
.
dingleDigitIntArray
[
0
]
)
{
if
(
!
updateList
.
isEmpty
()
)
{
YifuUser
user
=
SecurityUtils
.
getUser
();
YifuUser
user
=
SecurityUtils
.
getUser
();
doJointTask
.
doUpdateEmployeeInfo
(
updateList
,
user
);
doJointTask
.
doUpdateEmployeeInfo
(
updateList
,
user
);
}
}
if
(
proInsList
.
size
()
>
CommonConstants
.
dingleDigitIntArray
[
0
]
)
{
if
(
!
proInsList
.
isEmpty
()
)
{
baseMapper
.
insertExcelEmpProject
(
proInsList
);
doJointTask
.
insertExcelEmpProject
(
proInsList
);
}
}
if
(
proupdateList
.
size
()
>
CommonConstants
.
dingleDigitIntArray
[
0
]
)
{
if
(
!
proupdateList
.
isEmpty
()
)
{
baseMapper
.
updateExcelEmpProject
(
proupdateList
);
baseMapper
.
updateExcelEmpProject
(
proupdateList
);
}
}
}
catch
(
Exception
e
)
{
}
catch
(
Exception
e
)
{
...
@@ -1103,12 +1107,12 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
...
@@ -1103,12 +1107,12 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
if
(
CollUtil
.
isNotEmpty
(
errorList
))
{
if
(
CollUtil
.
isNotEmpty
(
errorList
))
{
return
R
.
failed
(
errorList
);
return
R
.
failed
(
errorList
);
}
else
{
}
else
{
if
(
updList
.
size
()
>
CommonConstants
.
dingleDigitIntArray
[
0
]
)
{
if
(
!
updList
.
isEmpty
()
)
{
for
(
TEmployeeProject
tEmployeeProject
:
updList
)
{
for
(
TEmployeeProject
tEmployeeProject
:
updList
)
{
baseMapper
.
updateById
(
tEmployeeProject
);
baseMapper
.
updateById
(
tEmployeeProject
);
}
}
}
}
if
(
infoUpdList
.
size
()
>
CommonConstants
.
dingleDigitIntArray
[
0
]
)
{
if
(
!
infoUpdList
.
isEmpty
()
)
{
YifuUser
user
=
SecurityUtils
.
getUser
();
YifuUser
user
=
SecurityUtils
.
getUser
();
doJointTask
.
doUpdateEmployeeInfo
(
infoUpdList
,
user
);
doJointTask
.
doUpdateEmployeeInfo
(
infoUpdList
,
user
);
}
}
...
@@ -1236,18 +1240,6 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
...
@@ -1236,18 +1240,6 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
baseMapper
.
insert
(
tEmployeeProject
);
baseMapper
.
insert
(
tEmployeeProject
);
}
}
/**
* 获取导出的项目档案列表
*/
private
List
<
EmployeeProjectExportVO
>
gettEmpProInfoExportVos
(
String
idstr
,
EmployeeProjectExportParamVO
projectDTO
)
{
List
<
EmployeeProjectExportVO
>
list
;
if
(!
Common
.
isEmpty
(
idstr
))
{
projectDTO
.
setIdList
(
Common
.
initStrToList
(
idstr
,
CommonConstants
.
COMMA_STRING
));
}
list
=
baseMapper
.
getTEmployeeProjectExportPage
(
projectDTO
);
return
list
;
}
/**
/**
* 更新人员档案
* 更新人员档案
*/
*/
...
...
yifu-archives/yifu-archives-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/archives/utils/DoJointTask.java
View file @
25c396b5
...
@@ -4,9 +4,9 @@ import com.baomidou.mybatisplus.core.toolkit.Wrappers;
...
@@ -4,9 +4,9 @@ import com.baomidou.mybatisplus.core.toolkit.Wrappers;
import
com.yifu.cloud.plus.v1.yifu.archives.entity.FddContractAttachInfo
;
import
com.yifu.cloud.plus.v1.yifu.archives.entity.FddContractAttachInfo
;
import
com.yifu.cloud.plus.v1.yifu.archives.entity.TEmployeeInfo
;
import
com.yifu.cloud.plus.v1.yifu.archives.entity.TEmployeeInfo
;
import
com.yifu.cloud.plus.v1.yifu.archives.entity.TEmployeeProject
;
import
com.yifu.cloud.plus.v1.yifu.archives.entity.TEmployeeProject
;
import
com.yifu.cloud.plus.v1.yifu.archives.mapper.TEmployeeProjectMapper
;
import
com.yifu.cloud.plus.v1.yifu.archives.service.TEmployeeInfoService
;
import
com.yifu.cloud.plus.v1.yifu.archives.service.TEmployeeInfoService
;
import
com.yifu.cloud.plus.v1.yifu.archives.service.TEmployeeLogService
;
import
com.yifu.cloud.plus.v1.yifu.archives.service.TEmployeeLogService
;
import
com.yifu.cloud.plus.v1.yifu.archives.service.TEmployeeProjectService
;
import
com.yifu.cloud.plus.v1.yifu.common.core.constant.CommonConstants
;
import
com.yifu.cloud.plus.v1.yifu.common.core.constant.CommonConstants
;
import
com.yifu.cloud.plus.v1.yifu.common.core.util.Common
;
import
com.yifu.cloud.plus.v1.yifu.common.core.util.Common
;
import
com.yifu.cloud.plus.v1.yifu.common.core.vo.YifuUser
;
import
com.yifu.cloud.plus.v1.yifu.common.core.vo.YifuUser
;
...
@@ -33,7 +33,7 @@ public class DoJointTask {
...
@@ -33,7 +33,7 @@ public class DoJointTask {
private
TEmployeeInfoService
tEmployeeInfoService
;
private
TEmployeeInfoService
tEmployeeInfoService
;
@Autowired
@Autowired
private
TEmployeeProject
Service
tEmployeeProjectService
;
private
TEmployeeProject
Mapper
tEmployeeProjectMapper
;
@Autowired
@Autowired
private
TEmployeeLogService
tEmployeeLogService
;
private
TEmployeeLogService
tEmployeeLogService
;
...
@@ -51,7 +51,7 @@ public class DoJointTask {
...
@@ -51,7 +51,7 @@ public class DoJointTask {
for
(
TEmployeeInfo
tEmployeeInfo:
tEmployeeInfoList
)
{
for
(
TEmployeeInfo
tEmployeeInfo:
tEmployeeInfoList
)
{
TEmployeeInfo
tEmployeeInfoOld
=
tEmployeeInfoService
.
getById
(
tEmployeeInfo
.
getId
());
TEmployeeInfo
tEmployeeInfoOld
=
tEmployeeInfoService
.
getById
(
tEmployeeInfo
.
getId
());
//查询该人员所有的项目档案
//查询该人员所有的项目档案
List
<
TEmployeeProject
>
list
=
tEmployeeProject
Service
.
l
ist
(
Wrappers
.<
TEmployeeProject
>
query
().
lambda
()
List
<
TEmployeeProject
>
list
=
tEmployeeProject
Mapper
.
selectL
ist
(
Wrappers
.<
TEmployeeProject
>
query
().
lambda
()
.
eq
(
TEmployeeProject:
:
getEmpIdcard
,
tEmployeeInfo
.
getEmpIdcard
())
.
eq
(
TEmployeeProject:
:
getEmpIdcard
,
tEmployeeInfo
.
getEmpIdcard
())
.
eq
(
TEmployeeProject:
:
getDeleteFlag
,
CommonConstants
.
STATUS_NORMAL
)
.
eq
(
TEmployeeProject:
:
getDeleteFlag
,
CommonConstants
.
STATUS_NORMAL
)
.
eq
(
TEmployeeProject:
:
getProjectStatus
,
CommonConstants
.
ZERO_INT
));
.
eq
(
TEmployeeProject:
:
getProjectStatus
,
CommonConstants
.
ZERO_INT
));
...
@@ -93,7 +93,7 @@ public class DoJointTask {
...
@@ -93,7 +93,7 @@ public class DoJointTask {
for
(
TEmployeeInfo
tEmployeeInfo:
tEmployeeInfoList
)
{
for
(
TEmployeeInfo
tEmployeeInfo:
tEmployeeInfoList
)
{
TEmployeeInfo
tEmployeeInfoOld
=
tEmployeeInfoService
.
getById
(
tEmployeeInfo
.
getId
());
TEmployeeInfo
tEmployeeInfoOld
=
tEmployeeInfoService
.
getById
(
tEmployeeInfo
.
getId
());
//查询该人员所有的项目档案
//查询该人员所有的项目档案
List
<
TEmployeeProject
>
list
=
tEmployeeProject
Service
.
l
ist
(
Wrappers
.<
TEmployeeProject
>
query
().
lambda
()
List
<
TEmployeeProject
>
list
=
tEmployeeProject
Mapper
.
selectL
ist
(
Wrappers
.<
TEmployeeProject
>
query
().
lambda
()
.
eq
(
TEmployeeProject:
:
getEmpIdcard
,
tEmployeeInfo
.
getEmpIdcard
())
.
eq
(
TEmployeeProject:
:
getEmpIdcard
,
tEmployeeInfo
.
getEmpIdcard
())
.
eq
(
TEmployeeProject:
:
getDeleteFlag
,
CommonConstants
.
STATUS_NORMAL
)
.
eq
(
TEmployeeProject:
:
getDeleteFlag
,
CommonConstants
.
STATUS_NORMAL
)
.
eq
(
TEmployeeProject:
:
getProjectStatus
,
CommonConstants
.
ZERO_INT
));
.
eq
(
TEmployeeProject:
:
getProjectStatus
,
CommonConstants
.
ZERO_INT
));
...
@@ -120,4 +120,18 @@ public class DoJointTask {
...
@@ -120,4 +120,18 @@ public class DoJointTask {
log
.
info
(
"法大大档案-批量更新人员档案结束"
);
log
.
info
(
"法大大档案-批量更新人员档案结束"
);
}
}
/**
* @Description: 批量插入项目档案
* @Author: huyc
* @Date: 2022-11-22
* @return: void
**/
@Async
public
void
insertExcelEmpProject
(
List
<
TEmployeeProject
>
proInsList
)
{
try
{
tEmployeeProjectMapper
.
insertExcelEmpProject
(
proInsList
);
}
catch
(
Exception
e
)
{
log
.
error
(
"档案-批量插入项目档案错误"
,
e
);
}
}
}
}
yifu-archives/yifu-archives-biz/src/main/resources/mapper/TEmployeeProjectMapper.xml
View file @
25c396b5
...
@@ -727,7 +727,39 @@
...
@@ -727,7 +727,39 @@
)
)
</foreach>
</foreach>
</insert>
</insert>
<update
id=
"updateReduceEmpProject"
parameterType=
"java.util.List"
>
update t_employee_project
<trim
prefix=
"set"
suffixOverrides=
","
>
<trim
prefix=
"LEAVE_TIME =case"
suffix=
"end,"
>
<foreach
collection=
"list"
item=
"i"
index=
"index"
>
when ID=#{i.id} then now()
</foreach>
</trim>
<trim
prefix=
"LEAVE_REASON =case"
suffix=
"end,"
>
<foreach
collection=
"list"
item=
"i"
index=
"index"
>
<if
test=
"i.leaveReason!=null"
>
when ID=#{i.id} then #{i.leaveReason}
</if>
</foreach>
</trim>
<trim
prefix=
"LEAVE_REMARK =case"
suffix=
"end,"
>
<foreach
collection=
"list"
item=
"i"
index=
"index"
>
<if
test=
"i.leaveRemark!=null"
>
when ID=#{i.id} then #{i.leaveRemark}
</if>
</foreach>
</trim>
<trim
prefix=
"PROJECT_STATUS =case"
suffix=
"end,"
>
<foreach
collection=
"list"
item=
"i"
index=
"index"
>
when ID=#{i.id} then 1
</foreach>
</trim>
</trim>
where
<foreach
collection=
"list"
separator=
"or"
item=
"i"
index=
"index"
>
ID=#{i.id}
</foreach>
</update>
<!--查询部门编码和最大员工数-->
<!--查询部门编码和最大员工数-->
<select
id=
"findEmployeeMaxOnlyNoByDepId"
resultType=
"java.lang.String"
>
<select
id=
"findEmployeeMaxOnlyNoByDepId"
resultType=
"java.lang.String"
>
SELECT
SELECT
...
...
yifu-social/yifu-social-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/social/service/impl/TIncomeServiceImpl.java
View file @
25c396b5
...
@@ -277,7 +277,7 @@ public class TIncomeServiceImpl extends ServiceImpl<TIncomeMapper, TIncome> impl
...
@@ -277,7 +277,7 @@ public class TIncomeServiceImpl extends ServiceImpl<TIncomeMapper, TIncome> impl
return
this
.
saveIncome
(
tIncomeDetail
);
return
this
.
saveIncome
(
tIncomeDetail
);
}
else
{
}
else
{
// 核心判断
// 核心判断
return
this
.
copyCore
(
tIncomeDetail
,
incomeList
,
detailList
);
return
this
.
copyCore
(
tIncomeDetail
,
incomeList
,
detailList
,
null
);
}
}
}
}
...
@@ -313,7 +313,7 @@ public class TIncomeServiceImpl extends ServiceImpl<TIncomeMapper, TIncome> impl
...
@@ -313,7 +313,7 @@ public class TIncomeServiceImpl extends ServiceImpl<TIncomeMapper, TIncome> impl
return
this
.
savePaymentIncome
(
tIncomeDetail
,
paymentInfo
);
return
this
.
savePaymentIncome
(
tIncomeDetail
,
paymentInfo
);
}
else
{
}
else
{
// 核心判断
// 核心判断
return
this
.
copyCore
(
tIncomeDetail
,
incomeList
,
detailList
);
return
this
.
copyCore
(
tIncomeDetail
,
incomeList
,
detailList
,
paymentInfo
);
}
}
}
}
...
@@ -570,10 +570,15 @@ public class TIncomeServiceImpl extends ServiceImpl<TIncomeMapper, TIncome> impl
...
@@ -570,10 +570,15 @@ public class TIncomeServiceImpl extends ServiceImpl<TIncomeMapper, TIncome> impl
* @Date: 2022/9/2 10:22
* @Date: 2022/9/2 10:22
* @return: boolean
* @return: boolean
**/
**/
private
boolean
copyCore
(
TIncomeDetail
tIncomeDetail
,
List
<
TIncome
>
incomeList
,
List
<
TIncomeDetail
>
detailList
)
{
private
boolean
copyCore
(
TIncomeDetail
tIncomeDetail
,
List
<
TIncome
>
incomeList
,
List
<
TIncomeDetail
>
detailList
,
TPaymentInfo
paymentInfo
)
{
// 判断,比例,直接加
// 判断,比例,直接加
if
(
CommonConstants
.
ONE_STRING
.
equals
(
tIncomeDetail
.
getFeeMode
()))
{
if
(
CommonConstants
.
ONE_STRING
.
equals
(
tIncomeDetail
.
getFeeMode
()))
{
return
this
.
saveIncome
(
tIncomeDetail
);
if
(
Common
.
isNotNull
(
paymentInfo
))
{
return
this
.
savePaymentIncome
(
tIncomeDetail
,
paymentInfo
);
}
else
{
return
this
.
saveIncome
(
tIncomeDetail
);
}
}
else
{
}
else
{
Map
<
String
,
Integer
>
numMap
=
new
HashMap
<>();
Map
<
String
,
Integer
>
numMap
=
new
HashMap
<>();
Map
<
String
,
Integer
>
incomeMap
=
new
HashMap
<>();
Map
<
String
,
Integer
>
incomeMap
=
new
HashMap
<>();
...
@@ -625,11 +630,21 @@ public class TIncomeServiceImpl extends ServiceImpl<TIncomeMapper, TIncome> impl
...
@@ -625,11 +630,21 @@ public class TIncomeServiceImpl extends ServiceImpl<TIncomeMapper, TIncome> impl
if
(
CommonConstants
.
ZERO_STRING
.
equals
(
tIncomeDetail
.
getRedData
()))
{
if
(
CommonConstants
.
ZERO_STRING
.
equals
(
tIncomeDetail
.
getRedData
()))
{
if
(
incomeMap
.
get
(
tIncomeDetail
.
getPayMonth
()
+
CommonConstants
.
DOWN_LINE_STRING
+
tIncomeDetail
.
getFeeType
())
==
null
if
(
incomeMap
.
get
(
tIncomeDetail
.
getPayMonth
()
+
CommonConstants
.
DOWN_LINE_STRING
+
tIncomeDetail
.
getFeeType
())
==
null
||
incomeMap
.
get
(
tIncomeDetail
.
getPayMonth
()
+
CommonConstants
.
DOWN_LINE_STRING
+
tIncomeDetail
.
getFeeType
())
<=
CommonConstants
.
ZERO_INT
)
{
||
incomeMap
.
get
(
tIncomeDetail
.
getPayMonth
()
+
CommonConstants
.
DOWN_LINE_STRING
+
tIncomeDetail
.
getFeeType
())
<=
CommonConstants
.
ZERO_INT
)
{
return
this
.
saveIncome
(
tIncomeDetail
);
if
(
Common
.
isNotNull
(
paymentInfo
))
{
return
this
.
savePaymentIncome
(
tIncomeDetail
,
paymentInfo
);
}
else
{
return
this
.
saveIncome
(
tIncomeDetail
);
}
}
}
}
else
{
}
else
{
// 红冲判断:当本类型是最大值,才可以红冲
// 红冲判断:当本类型是最大值,才可以红冲
if
(
this
.
redDateJudge
(
tIncomeDetail
,
numMap
))
return
this
.
saveIncome
(
tIncomeDetail
);
if
(
this
.
redDateJudge
(
tIncomeDetail
,
numMap
))
{
if
(
Common
.
isNotNull
(
paymentInfo
))
{
return
this
.
savePaymentIncome
(
tIncomeDetail
,
paymentInfo
);
}
else
{
return
this
.
saveIncome
(
tIncomeDetail
);
}
}
}
}
}
else
if
(
CommonConstants
.
THREE_STRING
.
equals
(
tIncomeDetail
.
getSourceType
()))
{
}
else
if
(
CommonConstants
.
THREE_STRING
.
equals
(
tIncomeDetail
.
getSourceType
()))
{
// 商险。收费方式:2金额-人数
// 商险。收费方式:2金额-人数
...
@@ -637,10 +652,20 @@ public class TIncomeServiceImpl extends ServiceImpl<TIncomeMapper, TIncome> impl
...
@@ -637,10 +652,20 @@ public class TIncomeServiceImpl extends ServiceImpl<TIncomeMapper, TIncome> impl
if
(
CommonConstants
.
ZERO_STRING
.
equals
(
tIncomeDetail
.
getRedData
()))
{
if
(
CommonConstants
.
ZERO_STRING
.
equals
(
tIncomeDetail
.
getRedData
()))
{
if
(
insureMap
.
get
(
tIncomeDetail
.
getDataCreateMonth
()
+
CommonConstants
.
DOWN_LINE_STRING
+
tIncomeDetail
.
getFeeType
())
==
null
if
(
insureMap
.
get
(
tIncomeDetail
.
getDataCreateMonth
()
+
CommonConstants
.
DOWN_LINE_STRING
+
tIncomeDetail
.
getFeeType
())
==
null
||
insureMap
.
get
(
tIncomeDetail
.
getDataCreateMonth
()
+
CommonConstants
.
DOWN_LINE_STRING
+
tIncomeDetail
.
getFeeType
())
<=
CommonConstants
.
ZERO_INT
)
{
||
insureMap
.
get
(
tIncomeDetail
.
getDataCreateMonth
()
+
CommonConstants
.
DOWN_LINE_STRING
+
tIncomeDetail
.
getFeeType
())
<=
CommonConstants
.
ZERO_INT
)
{
return
this
.
saveIncome
(
tIncomeDetail
);
if
(
Common
.
isNotNull
(
paymentInfo
))
{
return
this
.
savePaymentIncome
(
tIncomeDetail
,
paymentInfo
);
}
else
{
return
this
.
saveIncome
(
tIncomeDetail
);
}
}
}
}
else
{
}
else
{
if
(
this
.
redDateJudge
(
tIncomeDetail
,
numMap
))
return
this
.
saveIncome
(
tIncomeDetail
);
if
(
this
.
redDateJudge
(
tIncomeDetail
,
numMap
))
{
if
(
Common
.
isNotNull
(
paymentInfo
))
{
return
this
.
savePaymentIncome
(
tIncomeDetail
,
paymentInfo
);
}
else
{
return
this
.
saveIncome
(
tIncomeDetail
);
}
}
}
}
}
else
{
}
else
{
// 各个模式累加逻辑:
// 各个模式累加逻辑:
...
@@ -651,7 +676,11 @@ public class TIncomeServiceImpl extends ServiceImpl<TIncomeMapper, TIncome> impl
...
@@ -651,7 +676,11 @@ public class TIncomeServiceImpl extends ServiceImpl<TIncomeMapper, TIncome> impl
if
(
CommonConstants
.
TWO_STRING
.
equals
(
tIncomeDetail
.
getFeeMode
()))
{
if
(
CommonConstants
.
TWO_STRING
.
equals
(
tIncomeDetail
.
getFeeMode
()))
{
if
(
incomeMap
.
get
(
tIncomeDetail
.
getPayMonth
()
+
CommonConstants
.
DOWN_LINE_STRING
+
tIncomeDetail
.
getFeeType
())
==
null
if
(
incomeMap
.
get
(
tIncomeDetail
.
getPayMonth
()
+
CommonConstants
.
DOWN_LINE_STRING
+
tIncomeDetail
.
getFeeType
())
==
null
||
incomeMap
.
get
(
tIncomeDetail
.
getPayMonth
()
+
CommonConstants
.
DOWN_LINE_STRING
+
tIncomeDetail
.
getFeeType
())
<=
CommonConstants
.
ZERO_INT
)
{
||
incomeMap
.
get
(
tIncomeDetail
.
getPayMonth
()
+
CommonConstants
.
DOWN_LINE_STRING
+
tIncomeDetail
.
getFeeType
())
<=
CommonConstants
.
ZERO_INT
)
{
return
this
.
saveIncome
(
tIncomeDetail
);
if
(
Common
.
isNotNull
(
paymentInfo
))
{
return
this
.
savePaymentIncome
(
tIncomeDetail
,
paymentInfo
);
}
else
{
return
this
.
saveIncome
(
tIncomeDetail
);
}
}
}
}
else
{
}
else
{
// 3金额-人次
// 3金额-人次
...
...
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