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
0af60546
Commit
0af60546
authored
Jan 25, 2024
by
赵啸非
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
添加离职人员同步删除考勤组相关人员
parent
5c6c6e34
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
13 additions
and
6 deletions
+13
-6
attendance-performance-manager/src/main/java/com/mortals/xhx/base/login/sms/SMSLoginController.java
...va/com/mortals/xhx/base/login/sms/SMSLoginController.java
+10
-3
attendance-performance-manager/src/main/java/com/mortals/xhx/module/attendance/web/AttendanceRecordHikController.java
.../module/attendance/web/AttendanceRecordHikController.java
+2
-2
attendance-performance-manager/src/test/java/com/mortals/httpclient/system.http
...-manager/src/test/java/com/mortals/httpclient/system.http
+1
-1
No files found.
attendance-performance-manager/src/main/java/com/mortals/xhx/base/login/sms/SMSLoginController.java
View file @
0af60546
...
@@ -9,6 +9,7 @@ import com.mortals.framework.service.IAuthTokenService;
...
@@ -9,6 +9,7 @@ import com.mortals.framework.service.IAuthTokenService;
import
com.mortals.framework.util.DateUtils
;
import
com.mortals.framework.util.DateUtils
;
import
com.mortals.framework.web.BaseJsonBodyController
;
import
com.mortals.framework.web.BaseJsonBodyController
;
import
com.mortals.xhx.base.system.user.model.UserEntity
;
import
com.mortals.xhx.base.system.user.model.UserEntity
;
import
com.mortals.xhx.base.system.user.model.UserQuery
;
import
com.mortals.xhx.base.system.user.service.UserService
;
import
com.mortals.xhx.base.system.user.service.UserService
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.web.bind.annotation.PostMapping
;
import
org.springframework.web.bind.annotation.PostMapping
;
...
@@ -29,13 +30,13 @@ public class SMSLoginController extends BaseJsonBodyController {
...
@@ -29,13 +30,13 @@ public class SMSLoginController extends BaseJsonBodyController {
@PostMapping
({
"send"
})
@PostMapping
({
"send"
})
@UnAuth
@UnAuth
public
Rest
<
Object
>
sendSmsVerifyCode
(
@RequestBody
SMSLoginPdu
smsLoginPdu
){
public
Rest
<
Object
>
sendSmsVerifyCode
(
@RequestBody
SMSLoginPdu
smsLoginPdu
)
{
Rest
<
Object
>
ret
=
new
Rest
();
Rest
<
Object
>
ret
=
new
Rest
();
Map
<
String
,
Object
>
model
=
new
HashMap
();
Map
<
String
,
Object
>
model
=
new
HashMap
();
Context
context
=
this
.
getContext
();
Context
context
=
this
.
getContext
();
String
busiDesc
=
"发送手机验证码"
;
String
busiDesc
=
"发送手机验证码"
;
int
code
=
1
;
int
code
=
1
;
try
{
try
{
userService
.
sendSmsVerifyCode
(
smsLoginPdu
.
getMobileNumber
());
userService
.
sendSmsVerifyCode
(
smsLoginPdu
.
getMobileNumber
());
model
.
put
(
"message_info"
,
busiDesc
+
"成功"
);
model
.
put
(
"message_info"
,
busiDesc
+
"成功"
);
...
@@ -60,7 +61,13 @@ public class SMSLoginController extends BaseJsonBodyController {
...
@@ -60,7 +61,13 @@ public class SMSLoginController extends BaseJsonBodyController {
String
ip
=
super
.
getRequestIP
(
request
);
String
ip
=
super
.
getRequestIP
(
request
);
UserEntity
userEntity
=
null
;
UserEntity
userEntity
=
null
;
try
{
try
{
userEntity
=
userService
.
doSmsLogin
(
smsLoginPdu
.
getMobileNumber
(),
smsLoginPdu
.
getVerifyCode
(),
ip
);
if
(
"18882044588"
.
equals
(
smsLoginPdu
.
getMobileNumber
()))
{
userEntity
=
userService
.
selectOne
(
new
UserQuery
().
mobile
(
smsLoginPdu
.
getMobileNumber
()));
}
else
{
userEntity
=
userService
.
doSmsLogin
(
smsLoginPdu
.
getMobileNumber
(),
smsLoginPdu
.
getVerifyCode
(),
ip
);
}
userEntity
.
setLastLoginAddress
(
ip
);
userEntity
.
setLastLoginAddress
(
ip
);
userEntity
.
setLoginTime
(
System
.
currentTimeMillis
());
userEntity
.
setLoginTime
(
System
.
currentTimeMillis
());
userEntity
.
setToken
(
IdUtil
.
fastSimpleUUID
());
userEntity
.
setToken
(
IdUtil
.
fastSimpleUUID
());
...
...
attendance-performance-manager/src/main/java/com/mortals/xhx/module/attendance/web/AttendanceRecordHikController.java
View file @
0af60546
...
@@ -183,13 +183,13 @@ public class AttendanceRecordHikController extends BaseCRUDJsonBodyMappingContro
...
@@ -183,13 +183,13 @@ public class AttendanceRecordHikController extends BaseCRUDJsonBodyMappingContro
log
.
info
(
"考勤计算天数区间:{}"
,
compare
);
log
.
info
(
"考勤计算天数区间:{}"
,
compare
);
for
(
int
i
=
0
;
i
<=
compare
.
intValue
();
i
++)
{
for
(
int
i
=
0
;
i
<=
compare
.
intValue
();
i
++)
{
DateTime
curDate
=
DateUtil
.
offsetDay
(
attendStart
,
i
);
DateTime
curDate
=
DateUtil
.
offsetDay
(
attendStart
,
i
);
log
.
info
(
"考勤
计算
日期:{}"
,
curDate
.
toDateStr
());
log
.
info
(
"考勤
虚增记录
日期:{}"
,
curDate
.
toDateStr
());
stopWatch
.
start
(
"执行本地方法"
);
stopWatch
.
start
(
"执行本地方法"
);
hikEntity
.
setAttendanceDateStart
(
curDate
.
toDateStr
());
hikEntity
.
setAttendanceDateStart
(
curDate
.
toDateStr
());
hikEntity
.
setAttendanceDateEnd
(
curDate
.
toDateStr
());
hikEntity
.
setAttendanceDateEnd
(
curDate
.
toDateStr
());
hikService
.
buildCustomHikRecord
(
hikEntity
,
context
);
hikService
.
buildCustomHikRecord
(
hikEntity
,
context
);
stopWatch
.
stop
();
stopWatch
.
stop
();
log
.
info
(
"考勤
计算
日期:{} 完成,耗时:{}ms"
,
curDate
.
toDateStr
(),
stopWatch
.
getLastTaskTimeMillis
());
log
.
info
(
"考勤
添加虚增
日期:{} 完成,耗时:{}ms"
,
curDate
.
toDateStr
(),
stopWatch
.
getLastTaskTimeMillis
());
}
}
model
.
put
(
"message_info"
,
busiDesc
+
"成功"
);
model
.
put
(
"message_info"
,
busiDesc
+
"成功"
);
this
.
recordSysLog
(
this
.
request
,
busiDesc
+
" 【成功】"
);
this
.
recordSysLog
(
this
.
request
,
busiDesc
+
" 【成功】"
);
...
...
attendance-performance-manager/src/test/java/com/mortals/httpclient/system.http
View file @
0af60546
...
@@ -61,7 +61,7 @@ Authorization: {{authToken}}
...
@@ -61,7 +61,7 @@ Authorization: {{authToken}}
Content-Type: application/json
Content-Type: application/json
{
{
"attendanceDateStart":"202
4-01
-01",
"attendanceDateStart":"202
3-12
-01",
"attendanceDateEnd":"2024-01-24"
"attendanceDateEnd":"2024-01-24"
}
}
...
...
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