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
8f66e2ee
Commit
8f66e2ee
authored
Jan 25, 2024
by
赵啸非
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
添加离职人员同步删除考勤组相关人员
parent
821e0ee9
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
35 additions
and
6 deletions
+35
-6
attendance-performance-manager/src/main/java/com/mortals/xhx/module/staff/service/impl/StaffLeaveServiceImpl.java
.../xhx/module/staff/service/impl/StaffLeaveServiceImpl.java
+30
-1
attendance-performance-manager/src/test/java/com/mortals/httpclient/system.http
...-manager/src/test/java/com/mortals/httpclient/system.http
+5
-5
No files found.
attendance-performance-manager/src/main/java/com/mortals/xhx/module/staff/service/impl/StaffLeaveServiceImpl.java
View file @
8f66e2ee
package
com.mortals.xhx.module.staff.service.impl
;
import
com.mortals.xhx.module.attendance.model.AttendanceGroupStaffEntity
;
import
com.mortals.xhx.module.attendance.model.AttendanceGroupStaffQuery
;
import
com.mortals.xhx.module.attendance.service.AttendanceGroupStaffService
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
com.mortals.framework.service.impl.AbstractCRUDServiceImpl
;
import
com.mortals.framework.exception.AppException
;
...
...
@@ -6,6 +10,10 @@ import com.mortals.framework.model.Context;
import
com.mortals.xhx.module.staff.dao.StaffLeaveDao
;
import
com.mortals.xhx.module.staff.model.StaffLeaveEntity
;
import
com.mortals.xhx.module.staff.service.StaffLeaveService
;
import
org.springframework.util.ObjectUtils
;
import
java.util.List
;
/**
* StaffLeaveService
* 员工离职信息 service实现
...
...
@@ -15,5 +23,26 @@ import com.mortals.xhx.module.staff.service.StaffLeaveService;
*/
@Service
(
"staffLeaveService"
)
public
class
StaffLeaveServiceImpl
extends
AbstractCRUDServiceImpl
<
StaffLeaveDao
,
StaffLeaveEntity
,
Long
>
implements
StaffLeaveService
{
@Autowired
private
AttendanceGroupStaffService
groupStaffService
;
@Override
protected
void
saveAfter
(
StaffLeaveEntity
entity
,
Context
context
)
throws
AppException
{
super
.
saveAfter
(
entity
,
context
);
AttendanceGroupStaffQuery
attendanceGroupStaffQuery
=
new
AttendanceGroupStaffQuery
();
attendanceGroupStaffQuery
.
setStaffId
(
entity
.
getStaffId
());
List
<
AttendanceGroupStaffEntity
>
attendanceGroupStaffEntities
=
groupStaffService
.
find
(
attendanceGroupStaffQuery
,
context
);
if
(!
ObjectUtils
.
isEmpty
(
attendanceGroupStaffEntities
)){
Long
[]
delIds
=
attendanceGroupStaffEntities
.
stream
().
map
(
attendanceGroupStaffEntity
->
attendanceGroupStaffEntity
.
getId
()).
toArray
(
Long
[]::
new
);
if
(!
ObjectUtils
.
isEmpty
(
delIds
)){
groupStaffService
.
remove
(
delIds
,
context
);
}
}
//删除对应考勤组人员
}
}
\ No newline at end of file
attendance-performance-manager/src/test/java/com/mortals/httpclient/system.http
View file @
8f66e2ee
...
...
@@ -38,7 +38,7 @@ Authorization: {{authToken}}
Content-Type: application/json
{
"attendanceDateStart":"202
3-12
-01",
"attendanceDateStart":"202
4-01
-01",
"attendanceDateEnd":"2024-01-24"
}
...
...
@@ -55,14 +55,14 @@ Content-Type: application/json
###海康考勤打卡记录
计算
###海康考勤打卡记录
虚增记录
POST {{baseUrl}}/attendance/record/hik/addAttendanceRecordCustom
Authorization: {{authToken}}
Content-Type: application/json
{
"attendanceDateStart":"202
3-12
-01",
"attendanceDateEnd":"2024-01-2
5
"
"attendanceDateStart":"202
4-01
-01",
"attendanceDateEnd":"2024-01-2
4
"
}
...
...
@@ -72,7 +72,7 @@ Authorization: {{authToken}}
Content-Type: application/json
{
"attendanceDateStart":"202
4-01
-01",
"attendanceDateStart":"202
3-12
-01",
"attendanceDateEnd":"2024-01-25"
}
...
...
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