Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
W
work_service
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
licc
work_service
Commits
cb2c3284
Commit
cb2c3284
authored
Jan 21, 2021
by
cq990612
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
第二次提交
parent
27fd16eb
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
18 additions
and
4 deletions
+18
-4
WorkCollectMapper.xml
...gy-mapper/src/main/resources/mapper/WorkCollectMapper.xml
+4
-0
WorkUser.java
...-model/src/main/java/cn/wisenergy/model/app/WorkUser.java
+0
-2
WorkTimeOrderServiceImpl.java
...a/cn/wisenergy/service/impl/WorkTimeOrderServiceImpl.java
+11
-0
Examin.java
...in/src/main/java/cn/wisenergy/web/config/auto/Examin.java
+3
-2
No files found.
wisenergy-mapper/src/main/resources/mapper/WorkCollectMapper.xml
View file @
cb2c3284
...
@@ -13,6 +13,10 @@
...
@@ -13,6 +13,10 @@
<result
column=
"modify_time"
property=
"modifyTime"
/>
<result
column=
"modify_time"
property=
"modifyTime"
/>
</resultMap>
</resultMap>
<sql
id=
"vals"
>
#{userId},#{workDay},#{totalTime},#{status},now(),now()
</sql>
<!-- 通用查询结果列 -->
<!-- 通用查询结果列 -->
<sql
id=
"Base_Column_List"
>
<sql
id=
"Base_Column_List"
>
id, user_id, work_day, total_time, status, create_time, modify_time
id, user_id, work_day, total_time, status, create_time, modify_time
...
...
wisenergy-model/src/main/java/cn/wisenergy/model/app/WorkUser.java
View file @
cb2c3284
...
@@ -29,8 +29,6 @@ public class WorkUser implements Serializable {
...
@@ -29,8 +29,6 @@ public class WorkUser implements Serializable {
@TableId
(
value
=
"id"
,
type
=
IdType
.
AUTO
)
@TableId
(
value
=
"id"
,
type
=
IdType
.
AUTO
)
private
Integer
id
;
private
Integer
id
;
@ApiModelProperty
(
name
=
"oaUserId"
,
value
=
"oa中的用户编号"
)
@ApiModelProperty
(
name
=
"oaUserId"
,
value
=
"oa中的用户编号"
)
private
String
oaUserId
;
private
String
oaUserId
;
...
...
wisenergy-service/src/main/java/cn/wisenergy/service/impl/WorkTimeOrderServiceImpl.java
View file @
cb2c3284
...
@@ -358,6 +358,12 @@ public class WorkTimeOrderServiceImpl implements WorkTimeOrderService {
...
@@ -358,6 +358,12 @@ public class WorkTimeOrderServiceImpl implements WorkTimeOrderService {
if
(
CollectionUtils
.
isEmpty
(
ids
))
{
if
(
CollectionUtils
.
isEmpty
(
ids
))
{
throw
new
BaseCustomException
(
BASE_RESP_CODE_ENUM
.
INPUT_PARAM_IS_NULL
);
throw
new
BaseCustomException
(
BASE_RESP_CODE_ENUM
.
INPUT_PARAM_IS_NULL
);
}
}
Integer
level
=
workUserService
.
getById
(
reviewerId
).
getLevel
();
if
(
level
==
0
)
{
throw
new
BaseCustomException
(
BASE_RESP_CODE_ENUM
.
THE_USER_NOT_MANAGER_PLASE_MANAGER_LOGIN
);
}
int
i
=
workTimeOrderMapper
.
updateByIds
(
reviewerId
,
ids
);
int
i
=
workTimeOrderMapper
.
updateByIds
(
reviewerId
,
ids
);
if
(
i
==
0
)
{
if
(
i
==
0
)
{
throw
new
BaseCustomException
(
BASE_RESP_CODE_ENUM
.
UPDATE_DATA_FAIL
);
throw
new
BaseCustomException
(
BASE_RESP_CODE_ENUM
.
UPDATE_DATA_FAIL
);
...
@@ -395,6 +401,11 @@ public class WorkTimeOrderServiceImpl implements WorkTimeOrderService {
...
@@ -395,6 +401,11 @@ public class WorkTimeOrderServiceImpl implements WorkTimeOrderService {
if
(
null
==
reviewerId
||
null
==
id
||
StringUtils
.
isEmpty
(
reason
))
{
if
(
null
==
reviewerId
||
null
==
id
||
StringUtils
.
isEmpty
(
reason
))
{
throw
new
BaseCustomException
(
BASE_RESP_CODE_ENUM
.
INPUT_PARAM_IS_NULL
);
throw
new
BaseCustomException
(
BASE_RESP_CODE_ENUM
.
INPUT_PARAM_IS_NULL
);
}
}
Integer
level
=
workUserService
.
getById
(
reviewerId
).
getLevel
();
if
(
level
==
0
)
{
throw
new
BaseCustomException
(
BASE_RESP_CODE_ENUM
.
THE_USER_NOT_MANAGER_PLASE_MANAGER_LOGIN
);
}
int
i
=
workTimeOrderMapper
.
updateStatusById
(
reviewerId
,
id
,
reason
);
int
i
=
workTimeOrderMapper
.
updateStatusById
(
reviewerId
,
id
,
reason
);
if
(
i
==
0
)
{
if
(
i
==
0
)
{
throw
new
BaseCustomException
(
BASE_RESP_CODE_ENUM
.
UPDATE_DATA_FAIL
);
throw
new
BaseCustomException
(
BASE_RESP_CODE_ENUM
.
UPDATE_DATA_FAIL
);
...
...
wisenergy-web-admin/src/main/java/cn/wisenergy/web/config/auto/Examin.java
View file @
cb2c3284
...
@@ -38,12 +38,13 @@ public class Examin {
...
@@ -38,12 +38,13 @@ public class Examin {
private
WorkCollectMapper
workCollectMapper
;
private
WorkCollectMapper
workCollectMapper
;
@Autowired
@Autowired
private
WorkSubmitAdoptMapper
workSbumitAdoptMapper
;
private
WorkSubmitAdoptMapper
workSubmitAdoptMapper
;
@Scheduled
(
cron
=
"0 0 0 * * ?"
)
@Scheduled
(
cron
=
"0 0 0 * * ?"
)
public
void
autoExamin
()
{
public
void
autoExamin
()
{
log
.
info
(
"admin[]config[]auto[]Examin[]autoExamin"
);
log
.
info
(
"admin[]config[]auto[]Examin[]autoExamin"
);
WorkSubmitAdopt
workSbumitAdopt
=
workS
bu
mitAdoptMapper
.
selectById
(
1
);
WorkSubmitAdopt
workSbumitAdopt
=
workS
ub
mitAdoptMapper
.
selectById
(
1
);
Integer
autoAdopt
=
workSbumitAdopt
.
getAutoAdopt
();
Integer
autoAdopt
=
workSbumitAdopt
.
getAutoAdopt
();
Date
yesterdayDate
=
getAutoExaminDay
(
autoAdopt
);
Date
yesterdayDate
=
getAutoExaminDay
(
autoAdopt
);
Date
now
=
DateUtil
.
getToday
();
Date
now
=
DateUtil
.
getToday
();
...
...
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