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
8ce0c93a
Commit
8ce0c93a
authored
Jan 18, 2024
by
W_Y
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
删除任务
parent
5c34a6b9
Changes
5
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
43 additions
and
3 deletions
+43
-3
Task.java
quality-review/src/main/java/com/ruoyi/domain/Task.java
+1
-3
TaskService.java
...y-review/src/main/java/com/ruoyi/service/TaskService.java
+2
-0
TaskServiceImpl.java
...src/main/java/com/ruoyi/service/impl/TaskServiceImpl.java
+17
-0
TaskController.java
...ty-review/src/main/java/com/ruoyi/web/TaskController.java
+10
-0
TaskDeleteRequest.java
...rc/main/java/com/ruoyi/web/request/TaskDeleteRequest.java
+13
-0
No files found.
quality-review/src/main/java/com/ruoyi/domain/Task.java
View file @
8ce0c93a
...
...
@@ -26,8 +26,6 @@ public class Task {
@TableField
(
exist
=
false
)
public
static
final
String
STATUS_NEW
=
"NEW"
;
@TableField
(
exist
=
false
)
public
static
final
String
STATUS_PENDING
=
"PENDING"
;
@TableField
(
exist
=
false
)
public
static
final
String
STATUS_FINISH
=
"FINISH"
;
@TableField
(
exist
=
false
)
...
...
@@ -58,7 +56,7 @@ public class Task {
@ApiModelProperty
(
"任务名称"
)
private
String
taskName
;
@ApiModelProperty
(
"任务状态(NEW、
PENDING、
FINISH)"
)
@ApiModelProperty
(
"任务状态(NEW、FINISH)"
)
private
String
taskStatus
;
@ApiModelProperty
(
"产品名称"
)
...
...
quality-review/src/main/java/com/ruoyi/service/TaskService.java
View file @
8ce0c93a
...
...
@@ -34,4 +34,6 @@ public interface TaskService extends IService<Task> {
List
<
Task
>
findFinish
(
TaskFindFinishRequest
request
);
void
editTask
(
TaskEditRequest
request
);
void
deleteTask
(
TaskDeleteRequest
request
);
}
quality-review/src/main/java/com/ruoyi/service/impl/TaskServiceImpl.java
View file @
8ce0c93a
...
...
@@ -8,6 +8,8 @@ import com.ruoyi.common.utils.SecurityUtils;
import
com.ruoyi.common.utils.SnowflakeUtil
;
import
com.ruoyi.common.utils.bean.BeanUtils
;
import
com.ruoyi.domain.*
;
import
com.ruoyi.mapper.CarReviewTaskMapper
;
import
com.ruoyi.mapper.SystemReviewTaskMapper
;
import
com.ruoyi.mapper.TaskMapper
;
import
com.ruoyi.service.*
;
import
com.ruoyi.system.service.ISysUserService
;
...
...
@@ -46,6 +48,12 @@ public class TaskServiceImpl extends ServiceImpl<TaskMapper, Task> implements Ta
@Autowired
private
CarReviewTaskService
carReviewTaskService
;
@Autowired
private
SystemReviewTaskMapper
systemReviewTaskMapper
;
@Autowired
private
CarReviewTaskMapper
carReviewTaskMapper
;
@Override
public
List
<
Task
>
findList
(
TaskListRequest
request
)
{
return
taskMapper
.
findList
(
request
);
...
...
@@ -146,6 +154,15 @@ public class TaskServiceImpl extends ServiceImpl<TaskMapper, Task> implements Ta
taskUserRelationService
.
updateBatchById
(
auditors
);
}
@Override
public
void
deleteTask
(
TaskDeleteRequest
request
)
{
Task
task
=
taskMapper
.
selectById
(
request
.
getId
());
systemReviewTaskMapper
.
deleteById
(
task
.
getSystemReviewTaskId
());
carReviewTaskMapper
.
deleteById
(
task
.
getCarReviewTaskId
());
taskMapper
.
deleteById
(
request
.
getId
());
}
public
Long
saveSystemReview
(
TaskCreateRequest
request
,
SysUser
initiator
,
Standard
standard
,
TaskUserRelation
leader
)
{
// 构建并保存任务信息
...
...
quality-review/src/main/java/com/ruoyi/web/TaskController.java
View file @
8ce0c93a
...
...
@@ -99,4 +99,14 @@ public class TaskController extends BaseController {
return
R
.
ok
();
}
@ApiOperation
(
"删除任务"
)
@Trace
@Tags
({
@Tag
(
key
=
"param"
,
value
=
"arg[0]"
),
@Tag
(
key
=
"result"
,
value
=
"returnedObj"
)})
@Log
(
title
=
"删除任务"
,
businessType
=
BusinessType
.
DELETE
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/deleteTask"
)
public
R
<
String
>
deleteTask
(
@Validated
@RequestBody
TaskDeleteRequest
request
)
{
taskService
.
deleteTask
(
request
);
return
R
.
ok
();
}
}
quality-review/src/main/java/com/ruoyi/web/request/TaskDeleteRequest.java
0 → 100644
View file @
8ce0c93a
package
com
.
ruoyi
.
web
.
request
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
@ApiModel
(
value
=
"TaskDeleteRequest"
,
description
=
"删除任务"
)
@Data
public
class
TaskDeleteRequest
{
@ApiModelProperty
(
"ID"
)
private
Long
id
;
}
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