Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
8
8timerapiv200
Overview
Overview
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
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
8timerv2
8timerapiv200
Commits
e37ec907
Commit
e37ec907
authored
Aug 01, 2020
by
ilal
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
提交
parent
3d9c3db7
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
2 deletions
+4
-2
src/main/java/cn/timer/api/controller/kqgl/atttimer/AttendanceTaskTiming.java
+4
-2
No files found.
src/main/java/cn/timer/api/controller/kqgl/atttimer/AttendanceTaskTiming.java
View file @
e37ec907
...
@@ -120,7 +120,8 @@ public class AttendanceTaskTiming{
...
@@ -120,7 +120,8 @@ public class AttendanceTaskTiming{
// @Scheduled(cron = "0 37 18 * * ?") // 测试:5秒执行一次 0 0 19 * * ?
// @Scheduled(cron = "0 37 18 * * ?") // 测试:5秒执行一次 0 0 19 * * ?
// @Scheduled(cron = "0 */5 * * * ?")
// @Scheduled(cron = "0 */5 * * * ?")
@Scheduled
(
cron
=
"0 0 19 * * ?"
)
// @Scheduled(cron = "0 47 8 * * ?")
@Scheduled
(
cron
=
"0 0 8,12,16,20 * * ?"
)
//每天上午8、12点,下午16点,20点 执行
public
void
AttendanceTask
()
throws
ParseException
{
public
void
AttendanceTask
()
throws
ParseException
{
// boolean implement = false;
// boolean implement = false;
...
@@ -156,7 +157,8 @@ public class AttendanceTaskTiming{
...
@@ -156,7 +157,8 @@ public class AttendanceTaskTiming{
String
str
=
new
SimpleDateFormat
(
"yyyy-MM-dd"
).
format
(
new
Date
()).
toString
();
//
String
str
=
new
SimpleDateFormat
(
"yyyy-MM-dd"
).
format
(
new
Date
()).
toString
();
//
String
ttstr
=
new
SimpleDateFormat
(
"yyyy-MM"
).
format
(
new
Date
()).
toString
();
//
String
ttstr
=
new
SimpleDateFormat
(
"yyyy-MM"
).
format
(
new
Date
()).
toString
();
//
String
yesterday
=
ClockInTool
.
requires_extra_times
(
str
,-
1
,
3
,
1
);
//前一天
// String yesterday = ClockInTool.requires_extra_times(str,-1,3,1);//前一天
String
yesterday
=
str
;
String
[]
rangeArray
=
ClockInTool
.
listToString
(
ClockInTool
.
getDays
(
sdf1
.
format
(
c
.
getTime
()),
yesterday
)).
split
(
";"
);
//目前为止所有日期
String
[]
rangeArray
=
ClockInTool
.
listToString
(
ClockInTool
.
getDays
(
sdf1
.
format
(
c
.
getTime
()),
yesterday
)).
split
(
";"
);
//目前为止所有日期
String
[]
range
=
rangeArray
[
0
].
split
(
","
);
String
[]
range
=
rangeArray
[
0
].
split
(
","
);
...
...
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