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
2e9ba8dc
Commit
2e9ba8dc
authored
Jul 11, 2022
by
hongguangwu
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/develop' into develop
parents
99b2dc14
a7820974
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
48 additions
and
7 deletions
+48
-7
TEmpBadRecordServiceImpl.java
.../yifu/archives/service/impl/TEmpBadRecordServiceImpl.java
+1
-1
TEmployeeProjectServiceImpl.java
...fu/archives/service/impl/TEmployeeProjectServiceImpl.java
+44
-4
TElecEmployeeInfoMapper.xml
...biz/src/main/resources/mapper/TElecEmployeeInfoMapper.xml
+1
-1
ErrorCodes.java
....cloud.plus.v1/yifu/common/core/exception/ErrorCodes.java
+2
-1
No files found.
yifu-archives/yifu-archives-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/archives/service/impl/TEmpBadRecordServiceImpl.java
View file @
2e9ba8dc
...
@@ -276,7 +276,7 @@ public class TEmpBadRecordServiceImpl extends ServiceImpl<TEmpBadRecordMapper, T
...
@@ -276,7 +276,7 @@ public class TEmpBadRecordServiceImpl extends ServiceImpl<TEmpBadRecordMapper, T
if
(
Common
.
isNotNull
(
idList
)){
if
(
Common
.
isNotNull
(
idList
)){
wrapper
.
in
(
TEmpBadRecord:
:
getId
,
idList
);
wrapper
.
in
(
TEmpBadRecord:
:
getId
,
idList
);
}
}
if
(
tEmpBadRecord
.
getLimitStart
()
>=
0
&&
tEmpBadRecord
.
getLimitEnd
()
>
=
0
){
if
(
tEmpBadRecord
.
getLimitStart
()
>=
0
&&
tEmpBadRecord
.
getLimitEnd
()
>
0
){
wrapper
.
last
(
" limit "
+
tEmpBadRecord
.
getLimitStart
()
+
","
+
tEmpBadRecord
.
getLimitEnd
());
wrapper
.
last
(
" limit "
+
tEmpBadRecord
.
getLimitStart
()
+
","
+
tEmpBadRecord
.
getLimitEnd
());
}
}
return
baseMapper
.
selectList
(
wrapper
);
return
baseMapper
.
selectList
(
wrapper
);
...
...
yifu-archives/yifu-archives-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/archives/service/impl/TEmployeeProjectServiceImpl.java
View file @
2e9ba8dc
...
@@ -41,13 +41,18 @@ import com.yifu.cloud.plus.v1.yifu.archives.service.TSettleDomainService;
...
@@ -41,13 +41,18 @@ import com.yifu.cloud.plus.v1.yifu.archives.service.TSettleDomainService;
import
com.yifu.cloud.plus.v1.yifu.archives.utils.DoJointTask
;
import
com.yifu.cloud.plus.v1.yifu.archives.utils.DoJointTask
;
import
com.yifu.cloud.plus.v1.yifu.archives.vo.*
;
import
com.yifu.cloud.plus.v1.yifu.archives.vo.*
;
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.constant.SecurityConstants
;
import
com.yifu.cloud.plus.v1.yifu.common.core.exception.ErrorCodes
;
import
com.yifu.cloud.plus.v1.yifu.common.core.exception.ErrorCodes
;
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.core.vo.YifuUser
;
import
com.yifu.cloud.plus.v1.yifu.common.core.vo.YifuUser
;
import
com.yifu.cloud.plus.v1.yifu.common.dapr.config.DaprCheckProperties
;
import
com.yifu.cloud.plus.v1.yifu.common.dapr.config.DaprUpmsProperties
;
import
com.yifu.cloud.plus.v1.yifu.common.dapr.util.HttpDaprUtil
;
import
com.yifu.cloud.plus.v1.yifu.common.security.util.SecurityUtils
;
import
com.yifu.cloud.plus.v1.yifu.common.security.util.SecurityUtils
;
import
lombok.RequiredArgsConstructor
;
import
lombok.RequiredArgsConstructor
;
import
lombok.extern.log4j.Log4j2
;
import
lombok.extern.log4j.Log4j2
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.boot.context.properties.EnableConfigurationProperties
;
import
org.springframework.context.annotation.Lazy
;
import
org.springframework.context.annotation.Lazy
;
import
org.springframework.stereotype.Service
;
import
org.springframework.stereotype.Service
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.transaction.annotation.Transactional
;
...
@@ -71,6 +76,7 @@ import java.util.stream.Collectors;
...
@@ -71,6 +76,7 @@ import java.util.stream.Collectors;
@Service
@Service
@RequiredArgsConstructor
@RequiredArgsConstructor
@Log4j2
@Log4j2
@EnableConfigurationProperties
(
DaprUpmsProperties
.
class
)
public
class
TEmployeeProjectServiceImpl
extends
ServiceImpl
<
TEmployeeProjectMapper
,
TEmployeeProject
>
implements
TEmployeeProjectService
{
public
class
TEmployeeProjectServiceImpl
extends
ServiceImpl
<
TEmployeeProjectMapper
,
TEmployeeProject
>
implements
TEmployeeProjectService
{
@Autowired
@Autowired
...
@@ -89,6 +95,9 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
...
@@ -89,6 +95,9 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
@Lazy
@Lazy
private
DoJointTask
doJointTask
;
private
DoJointTask
doJointTask
;
@Autowired
private
DaprUpmsProperties
daprUpmsProperties
;
@Override
@Override
public
R
addCheck
(
TEmployeeProject
tEmployeeProject
)
{
public
R
addCheck
(
TEmployeeProject
tEmployeeProject
)
{
...
@@ -354,6 +363,7 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
...
@@ -354,6 +363,7 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
String
code
=
""
;
String
code
=
""
;
if
(
Common
.
isNotNull
(
tEmployeeProject
))
{
if
(
Common
.
isNotNull
(
tEmployeeProject
))
{
tEmployeeProject
.
setProjectStatus
(
CommonConstants
.
dingleDigitIntArray
[
1
]);
tEmployeeProject
.
setProjectStatus
(
CommonConstants
.
dingleDigitIntArray
[
1
]);
tEmployeeProject
.
setLeaveTime
(
LocalDateTime
.
now
());
this
.
updateById
(
tEmployeeProject
);
this
.
updateById
(
tEmployeeProject
);
TEmployeeInfo
tEmployeeInfo
=
tEmployeeInfoMapper
.
selectById
(
tEmployeeProject
.
getEmpId
());
TEmployeeInfo
tEmployeeInfo
=
tEmployeeInfoMapper
.
selectById
(
tEmployeeProject
.
getEmpId
());
...
@@ -413,6 +423,24 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
...
@@ -413,6 +423,24 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
// 新老项目档案List
// 新老项目档案List
List
<
EmployeeProjectNewOldVO
>
updateProjectList
=
new
ArrayList
<>();
List
<
EmployeeProjectNewOldVO
>
updateProjectList
=
new
ArrayList
<>();
// 调用字典服务,渲染字典值
R
<
Map
<
String
,
Map
<
String
,
Map
<
String
,
String
>>>>
dictR
=
HttpDaprUtil
.
invokeMethodPost
(
daprUpmsProperties
.
getAppUrl
(),
daprUpmsProperties
.
getAppId
()
,
"/dict/inner/getDictToLable"
,
null
,
Map
.
class
,
SecurityConstants
.
FROM_IN
);
Map
<
String
,
Map
<
String
,
Map
<
String
,
String
>>>
dictDataMap
;
Map
<
String
,
Map
<
String
,
String
>>
dictMap
;
// 民族
Map
<
String
,
String
>
empLabelMap
;
if
(
dictR
==
null
||
dictR
.
getData
()
==
null
)
{
return
R
.
failed
(
"获取字典失败!"
);
}
else
{
dictDataMap
=
dictR
.
getData
();
dictMap
=
dictDataMap
.
get
(
"data"
);
if
(
dictMap
==
null
)
{
return
R
.
failed
(
"获取字典失败!!"
);
}
empLabelMap
=
dictMap
.
get
(
"reduce_project_reason"
);
}
// 执行数据插入操作 组装 PostDto
// 执行数据插入操作 组装 PostDto
for
(
int
i
=
0
;
i
<
excelVOList
.
size
();
i
++)
{
for
(
int
i
=
0
;
i
<
excelVOList
.
size
();
i
++)
{
EmployeeXProjectVO
excel
=
excelVOList
.
get
(
i
);
EmployeeXProjectVO
excel
=
excelVOList
.
get
(
i
);
...
@@ -432,7 +460,14 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
...
@@ -432,7 +460,14 @@ 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
());
// 校验字典数据是否正确-减项原因
if
(
Common
.
isNotNull
(
excel
.
getLeaveReason
()))
{
if
(
empLabelMap
.
get
(
excel
.
getLeaveReason
())
==
null
)
{
errorMessageList
.
add
(
new
ErrorMessage
(
excel
.
getRowIndex
(),
MsgUtils
.
getMessage
(
ErrorCodes
.
ARCHIVES_IMPORT_EMP_REDUCE_ERROR
)));
}
else
{
tEmployeeProject
.
setLeaveReason
(
empLabelMap
.
get
(
excel
.
getLeaveReason
()));
}
}
tEmployeeProject
.
setLeaveRemark
(
excel
.
getLeaveRemark
());
tEmployeeProject
.
setLeaveRemark
(
excel
.
getLeaveRemark
());
tEmployeeProject
.
setLeaveTime
(
LocalDateTime
.
now
());
tEmployeeProject
.
setLeaveTime
(
LocalDateTime
.
now
());
updProjectList
.
add
(
tEmployeeProject
);
updProjectList
.
add
(
tEmployeeProject
);
...
@@ -1087,9 +1122,13 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
...
@@ -1087,9 +1122,13 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
@Override
@Override
public
R
getItemByEmpNo
(
String
empIdcard
,
String
empNo
)
{
public
R
getItemByEmpNo
(
String
empIdcard
,
String
empNo
)
{
TSettleDomain
tSettleDomain
=
tSettleDomainService
.
getOne
(
Wrappers
.<
TSettleDomain
>
query
().
lambda
()
TSettleDomain
tSettleDomain
=
tSettleDomainService
.
getOne
(
Wrappers
.<
TSettleDomain
>
query
().
lambda
()
.
eq
(
TSettleDomain:
:
getDepartNo
,
empNo
));
.
eq
(
TSettleDomain:
:
getDepartNo
,
empNo
)
.
eq
(
TSettleDomain:
:
getStopFlag
,
CommonConstants
.
ZERO_STRING
)
.
eq
(
TSettleDomain:
:
getDeleteFlag
,
CommonConstants
.
ZERO_STRING
));
TEmployeeInfo
tEmployeeInfo
=
tEmployeeInfoMapper
.
selectOne
(
Wrappers
.<
TEmployeeInfo
>
query
().
lambda
()
TEmployeeInfo
tEmployeeInfo
=
tEmployeeInfoMapper
.
selectOne
(
Wrappers
.<
TEmployeeInfo
>
query
().
lambda
()
.
eq
(
TEmployeeInfo:
:
getEmpIdcard
,
empIdcard
));
.
eq
(
TEmployeeInfo:
:
getEmpIdcard
,
empIdcard
)
.
eq
(
TEmployeeInfo:
:
getFileStatus
,
CommonConstants
.
ZERO_INT
)
.
eq
(
TEmployeeInfo:
:
getDeleteFlag
,
CommonConstants
.
ZERO_STRING
));
Map
<
String
,
Object
>
map
=
new
HashMap
<>();
Map
<
String
,
Object
>
map
=
new
HashMap
<>();
String
empCode
=
""
;
String
empCode
=
""
;
if
(
Common
.
isNotNull
(
tEmployeeInfo
))
{
if
(
Common
.
isNotNull
(
tEmployeeInfo
))
{
...
@@ -1098,7 +1137,8 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
...
@@ -1098,7 +1137,8 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
String
customerName
=
""
;
String
customerName
=
""
;
if
(
Common
.
isNotNull
(
tSettleDomain
))
{
if
(
Common
.
isNotNull
(
tSettleDomain
))
{
TCustomerInfo
tCustomerInfo
=
tCustomerInfoMapper
.
selectOne
(
Wrappers
.<
TCustomerInfo
>
query
().
lambda
()
TCustomerInfo
tCustomerInfo
=
tCustomerInfoMapper
.
selectOne
(
Wrappers
.<
TCustomerInfo
>
query
().
lambda
()
.
eq
(
TCustomerInfo:
:
getId
,
tSettleDomain
.
getCustomerId
()));
.
eq
(
TCustomerInfo:
:
getId
,
tSettleDomain
.
getCustomerId
())
.
eq
(
TCustomerInfo:
:
getDeleteFlag
,
CommonConstants
.
ZERO_STRING
));
if
(
Common
.
isNotNull
(
tCustomerInfo
))
{
if
(
Common
.
isNotNull
(
tCustomerInfo
))
{
customerName
=
tCustomerInfo
.
getCustomerName
();
customerName
=
tCustomerInfo
.
getCustomerName
();
}
}
...
...
yifu-archives/yifu-archives-biz/src/main/resources/mapper/TElecEmployeeInfoMapper.xml
View file @
2e9ba8dc
...
@@ -71,7 +71,7 @@
...
@@ -71,7 +71,7 @@
AND b.DEPT_NAME like concat('%',#{tElecEmployeeInfo.deptName},'%')
AND b.DEPT_NAME like concat('%',#{tElecEmployeeInfo.deptName},'%')
</if>
</if>
<if
test=
"tElecEmployeeInfo.empNo != null and tElecEmployeeInfo.empNo.trim() != ''"
>
<if
test=
"tElecEmployeeInfo.empNo != null and tElecEmployeeInfo.empNo.trim() != ''"
>
AND b.EMP_NO
like
= #{tElecEmployeeInfo.empNo}
AND b.EMP_NO = #{tElecEmployeeInfo.empNo}
</if>
</if>
<if
test=
"tElecEmployeeInfo.deptNo != null and tElecEmployeeInfo.deptNo.trim() != ''"
>
<if
test=
"tElecEmployeeInfo.deptNo != null and tElecEmployeeInfo.deptNo.trim() != ''"
>
AND b.DEPT_NO like concat('%',#{tElecEmployeeInfo.deptNo},'%')
AND b.DEPT_NO like concat('%',#{tElecEmployeeInfo.deptNo},'%')
...
...
yifu-common/yifu-common-core/src/main/java/com/yifu.cloud.plus.v1/yifu/common/core/exception/ErrorCodes.java
View file @
2e9ba8dc
...
@@ -268,7 +268,8 @@ public interface ErrorCodes {
...
@@ -268,7 +268,8 @@ public interface ErrorCodes {
String
ARCHIVES_IMPORT_EMP_HAVE_PROJECT
=
"archives.import.emp.have.project"
;
String
ARCHIVES_IMPORT_EMP_HAVE_PROJECT
=
"archives.import.emp.have.project"
;
String
ARCHIVES_IMPORT_EMP_EMAIL_CHECK
=
"archives.import.emp.email.check"
;
String
ARCHIVES_IMPORT_EMP_EMAIL_CHECK
=
"archives.import.emp.email.check"
;
String
ARCHIVES_IMPORT_EMP_EMAIL_LENGTH
=
"archives.import.emp.email.length"
;
String
ARCHIVES_IMPORT_EMP_EMAIL_LENGTH
=
"archives.import.emp.email.length"
;
// 减项原因在字典中未找到
String
ARCHIVES_IMPORT_EMP_REDUCE_ERROR
=
"archives.import.emp.reduce.error"
;
/**
/**
* 项目档案状态为已审核,禁止删除
* 项目档案状态为已审核,禁止删除
*/
*/
...
...
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