Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
A
attendance-performance-platform
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
赵啸非
attendance-performance-platform
Commits
410b849e
Commit
410b849e
authored
Aug 24, 2023
by
周亚武
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
钉钉相关接口
parent
d261530c
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
22 additions
and
5 deletions
+22
-5
attendance-performance-manager/src/main/java/com/mortals/xhx/module/attendance/model/AttendanceLeaveRecordEntity.java
.../module/attendance/model/AttendanceLeaveRecordEntity.java
+3
-3
attendance-performance-manager/src/main/java/com/mortals/xhx/module/attendance/web/AttendanceLeaveRecordController.java
...odule/attendance/web/AttendanceLeaveRecordController.java
+19
-2
No files found.
attendance-performance-manager/src/main/java/com/mortals/xhx/module/attendance/model/AttendanceLeaveRecordEntity.java
View file @
410b849e
...
...
@@ -133,15 +133,15 @@ public class AttendanceLeaveRecordEntity extends AttendanceLeaveRecordVo {
public
void
initAttrValue
(){
this
.
leavePersonId
=
0L
;
this
.
leavePerson
=
""
;
this
.
deptId
=
0L
;
this
.
deptId
=
null
;
this
.
deptName
=
""
;
this
.
phoneNumber
=
""
;
this
.
leaveType
=
0
;
this
.
leaveType
=
null
;
this
.
startTime
=
new
Date
();
this
.
endTime
=
new
Date
();
this
.
duration
=
0
;
this
.
reason
=
""
;
this
.
approverId
=
0L
;
this
.
approverId
=
null
;
this
.
approver
=
""
;
this
.
attachment
=
""
;
this
.
attachmentPath
=
""
;
...
...
attendance-performance-manager/src/main/java/com/mortals/xhx/module/attendance/web/AttendanceLeaveRecordController.java
View file @
410b849e
...
...
@@ -6,6 +6,8 @@ import com.mortals.xhx.base.system.user.model.UserQuery;
import
com.mortals.xhx.base.system.user.service.UserService
;
import
com.mortals.xhx.common.code.AppealResultEnum
;
import
com.mortals.xhx.common.code.ProcessStatusEnum
;
import
com.mortals.xhx.common.pdu.user.UserPdu
;
import
com.mortals.xhx.feign.user.IUserFeign
;
import
com.mortals.xhx.module.attendance.model.AttendanceLeaveRecordEntity
;
import
com.mortals.xhx.module.attendance.service.AttendanceLeaveRecordService
;
import
com.mortals.xhx.module.dept.model.DeptQuery
;
...
...
@@ -16,6 +18,9 @@ import org.springframework.beans.factory.annotation.Autowired;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.RestController
;
import
java.util.ArrayList
;
import
java.util.HashMap
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.stream.Collectors
;
...
...
@@ -38,8 +43,10 @@ public class AttendanceLeaveRecordController extends BaseCRUDJsonBodyMappingCont
private
DeptService
deptService
;
@Autowired
private
WorkmanService
workmanService
;
// @Autowired
// private UserService userService;
@Autowired
private
UserService
userService
;
private
IUserFeign
iUserFeign
;
public
AttendanceLeaveRecordController
(){
super
.
setModuleDesc
(
"请假记录信息"
);
...
...
@@ -52,7 +59,17 @@ public class AttendanceLeaveRecordController extends BaseCRUDJsonBodyMappingCont
this
.
addDict
(
model
,
"leaveType"
,
paramService
.
getParamBySecondOrganize
(
"AttendanceLeaveRecord"
,
"leaveType"
));
this
.
addDict
(
model
,
"auditResult"
,
AppealResultEnum
.
getEnumMap
());
this
.
addDict
(
model
,
"processStatus"
,
ProcessStatusEnum
.
getEnumMap
());
this
.
addDict
(
model
,
"createUserId"
,
userService
.
find
(
new
UserQuery
()).
stream
().
collect
(
toMap
(
x
->
x
.
getId
().
toString
(),
y
->
y
.
getRealName
(),
(
o
,
n
)
->
n
)));
// this.addDict(model, "createUserId", userService.find(new UserQuery()).stream().collect(toMap(x -> x.getId().toString(), y -> y.getRealName(), (o, n) -> n)));
List
<
UserPdu
>
userPduList
=
iUserFeign
.
list
(
new
UserPdu
()).
getData
().
getData
();
Map
<
Long
,
String
>
ans
=
new
HashMap
<>();
for
(
UserPdu
str:
userPduList
)
{
if
(
str
!=
null
)
{
//增加非空判断
ans
.
put
(
str
.
getId
(),
str
.
getRealName
());
}
}
this
.
addDict
(
model
,
"createUserId"
,
ans
);
super
.
init
(
model
,
context
);
...
...
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