Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vehicle-quality-review
Project
Project
Details
Activity
Releases
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
王飞
vehicle-quality-review
Commits
580d203c
Commit
580d203c
authored
Dec 27, 2023
by
W_Y
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
查询待办任务列表修改&查询已办任务列表
parent
86f4cc6b
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
58 additions
and
14 deletions
+58
-14
ReviewSceneChangeTaskMapper.java
...in/java/com/ruoyi/mapper/ReviewSceneChangeTaskMapper.java
+10
-3
ReviewSceneChangeTaskService.java
.../java/com/ruoyi/service/ReviewSceneChangeTaskService.java
+9
-3
ReviewSceneChangeTaskServiceImpl.java
.../ruoyi/service/impl/ReviewSceneChangeTaskServiceImpl.java
+14
-4
ReviewSceneChangeTaskController.java
...n/java/com/ruoyi/web/ReviewSceneChangeTaskController.java
+18
-2
ReviewSceneChangeTaskMapper.xml
...src/main/resources/mapper/ReviewSceneChangeTaskMapper.xml
+7
-2
No files found.
quality-review/src/main/java/com/ruoyi/mapper/ReviewSceneChangeTaskMapper.java
View file @
580d203c
...
...
@@ -20,11 +20,18 @@ public interface ReviewSceneChangeTaskMapper extends BaseMapper<ReviewSceneChang
List
<
ReviewSceneChangeTask
>
findLastChangeByTaskId
(
@Param
(
"taskId"
)
Long
taskId
);
/**
* 根据
任务状态和用户ID查询
列表
* @param
taskStatus
* 根据
用户ID查询待办
列表
* @param
userId
* @return
*/
List
<
ReviewSceneChangeTask
>
findListByUserIdAndStatus
(
@Param
(
"userId"
)
Long
userId
,
@Param
(
"taskStatus"
)
String
taskStatus
);
List
<
ReviewSceneChangeTask
>
findPendingListByUserId
(
@Param
(
"userId"
)
Long
userId
);
/**
* 根据用户ID查询已办列表
* @param userId
* @return
*/
List
<
ReviewSceneChangeTask
>
findFinishListByUserId
(
@Param
(
"userId"
)
Long
userId
);
}
...
...
quality-review/src/main/java/com/ruoyi/service/ReviewSceneChangeTaskService.java
View file @
580d203c
...
...
@@ -46,11 +46,17 @@ public interface ReviewSceneChangeTaskService extends IService<ReviewSceneChange
List
<
ReviewSceneChangeTask
>
findLastChangeByTaskId
(
Long
taskId
);
/**
* 根据用户ID
和任务状态查询
列表
* 根据用户ID
查询待办
列表
* @param userId
* @param taskStatus
* @return
*/
List
<
ReviewSceneChangeTask
>
findListByUserIdAndStatus
(
Long
userId
,
String
taskStatus
);
List
<
ReviewSceneChangeTask
>
findPendingListByUserId
(
Long
userId
);
/**
* 根据用户ID查询已办列表
* @param userId
* @return
*/
List
<
ReviewSceneChangeTask
>
findFinishListByUserId
(
Long
userId
);
}
quality-review/src/main/java/com/ruoyi/service/impl/ReviewSceneChangeTaskServiceImpl.java
View file @
580d203c
...
...
@@ -185,14 +185,24 @@ public class ReviewSceneChangeTaskServiceImpl extends ServiceImpl<ReviewSceneCha
}
/**
* 根据用户ID
和任务状态查询
列表
* 根据用户ID
查询待办
列表
* @param userId
* @param taskStatus
* @return
*/
@Override
public
List
<
ReviewSceneChangeTask
>
findListByUserIdAndStatus
(
Long
userId
,
String
taskStatus
)
{
List
<
ReviewSceneChangeTask
>
reviewSceneChangeTask
=
reviewSceneChangeTaskMapper
.
findListByUserIdAndStatus
(
userId
,
taskStatus
);
public
List
<
ReviewSceneChangeTask
>
findPendingListByUserId
(
Long
userId
)
{
List
<
ReviewSceneChangeTask
>
reviewSceneChangeTask
=
reviewSceneChangeTaskMapper
.
findPendingListByUserId
(
userId
);
return
reviewSceneChangeTask
;
}
/**
* 根据用户ID查询已办列表
* @param userId
* @return
*/
@Override
public
List
<
ReviewSceneChangeTask
>
findFinishListByUserId
(
Long
userId
)
{
List
<
ReviewSceneChangeTask
>
reviewSceneChangeTask
=
reviewSceneChangeTaskMapper
.
findFinishListByUserId
(
userId
);
return
reviewSceneChangeTask
;
}
...
...
quality-review/src/main/java/com/ruoyi/web/ReviewSceneChangeTaskController.java
View file @
580d203c
...
...
@@ -39,12 +39,28 @@ public class ReviewSceneChangeTaskController extends BaseController {
return
success
();
}
/**
* 根据用户ID查询待办列表
* @return
*/
@Trace
@
Log
(
title
=
"待办任务列表"
)
@
Tags
({
@Tag
(
key
=
"param"
,
value
=
"arg[0]"
),
@Tag
(
key
=
"result"
,
value
=
"returnedObj"
)}
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/findPending"
)
public
TableDataInfo
findPending
()
{
startPage
();
return
getDataTable
(
reviewSceneChangeTaskService
.
findListByUserIdAndStatus
(
getUserId
(),
ReviewSceneChangeTask
.
STATUS_PENDING
));
return
getDataTable
(
reviewSceneChangeTaskService
.
findPendingListByUserId
(
getUserId
()));
}
/**
* 根据用户ID查询已办列表
* @return
*/
@Trace
@Tags
({
@Tag
(
key
=
"param"
,
value
=
"arg[0]"
),
@Tag
(
key
=
"result"
,
value
=
"returnedObj"
)})
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/findFinish"
)
public
TableDataInfo
findFinish
()
{
startPage
();
return
getDataTable
(
reviewSceneChangeTaskService
.
findFinishListByUserId
(
getUserId
()));
}
}
quality-review/src/main/resources/mapper/ReviewSceneChangeTaskMapper.xml
View file @
580d203c
...
...
@@ -29,10 +29,15 @@
)
</select>
<select
id=
"find
ListByUserIdAndStatus
"
resultType=
"com.ruoyi.domain.ReviewSceneChangeTask"
>
<select
id=
"find
PendingListByUserId
"
resultType=
"com.ruoyi.domain.ReviewSceneChangeTask"
>
SELECT sct.* FROM t_review_scene_change_task sct
LEFT JOIN t_review_scene_change_task_user_relation sctu ON sct.id = sctu.task_id
WHERE sctu.user_id = #{userId} and sct.task_status = #{taskStatus}
WHERE sctu.user_id = #{userId} and sctu.decision IS NULL
</select>
<select
id=
"findFinishListByUserId"
resultType=
"com.ruoyi.domain.ReviewSceneChangeTask"
>
SELECT sct.* FROM t_review_scene_change_task sct
LEFT JOIN t_review_scene_change_task_user_relation sctu ON sct.id = sctu.task_id
WHERE sctu.user_id = #{userId} and sctu.decision IS NOT NULL
</select>
</mapper>
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