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
082c9882
Commit
082c9882
authored
Jan 16, 2024
by
高滢
Browse files
Options
Browse Files
Download
Plain Diff
sql 修改
parents
f4cf1f1e
42e67f77
Changes
50
Hide whitespace changes
Inline
Side-by-side
Showing
50 changed files
with
1102 additions
and
153 deletions
+1102
-153
CarReviewTask.java
...-review/src/main/java/com/ruoyi/domain/CarReviewTask.java
+7
-6
ReviewStandard.java
...review/src/main/java/com/ruoyi/domain/ReviewStandard.java
+17
-0
Standard.java
quality-review/src/main/java/com/ruoyi/domain/Standard.java
+0
-11
SystemReviewTask.java
...view/src/main/java/com/ruoyi/domain/SystemReviewTask.java
+5
-6
Task.java
quality-review/src/main/java/com/ruoyi/domain/Task.java
+156
-0
TaskUserRelation.java
...view/src/main/java/com/ruoyi/domain/TaskUserRelation.java
+8
-2
TaskMapper.java
...ity-review/src/main/java/com/ruoyi/mapper/TaskMapper.java
+15
-0
TaskUserRelationMapper.java
...rc/main/java/com/ruoyi/mapper/TaskUserRelationMapper.java
+3
-3
CarReviewTaskService.java
...src/main/java/com/ruoyi/service/CarReviewTaskService.java
+6
-0
ReviewSceneChangeTaskService.java
.../java/com/ruoyi/service/ReviewSceneChangeTaskService.java
+7
-0
StrategyCarReviewTask.java
...rc/main/java/com/ruoyi/service/StrategyCarReviewTask.java
+3
-1
StrategySystemReviewTask.java
...main/java/com/ruoyi/service/StrategySystemReviewTask.java
+5
-1
SystemReviewTaskService.java
.../main/java/com/ruoyi/service/SystemReviewTaskService.java
+7
-0
TaskService.java
...y-review/src/main/java/com/ruoyi/service/TaskService.java
+20
-0
TaskUserRelationService.java
.../main/java/com/ruoyi/service/TaskUserRelationService.java
+22
-0
CarReviewTaskServiceImpl.java
...java/com/ruoyi/service/impl/CarReviewTaskServiceImpl.java
+16
-12
ReviewSceneChangeTaskServiceImpl.java
.../ruoyi/service/impl/ReviewSceneChangeTaskServiceImpl.java
+14
-0
StrategyCarReviewTaskFinish.java
...a/com/ruoyi/service/impl/StrategyCarReviewTaskFinish.java
+6
-1
StrategyCarReviewTaskNew.java
...java/com/ruoyi/service/impl/StrategyCarReviewTaskNew.java
+6
-1
StrategyCarReviewTaskNone.java
...ava/com/ruoyi/service/impl/StrategyCarReviewTaskNone.java
+6
-1
StrategyCarReviewTaskPending.java
.../com/ruoyi/service/impl/StrategyCarReviewTaskPending.java
+15
-12
StrategyCarReviewTaskSigned.java
...a/com/ruoyi/service/impl/StrategyCarReviewTaskSigned.java
+89
-0
StrategySystemReviewTaskClose.java
...com/ruoyi/service/impl/StrategySystemReviewTaskClose.java
+6
-1
StrategySystemReviewTaskFinish.java
...om/ruoyi/service/impl/StrategySystemReviewTaskFinish.java
+6
-1
StrategySystemReviewTaskNew.java
...a/com/ruoyi/service/impl/StrategySystemReviewTaskNew.java
+6
-1
StrategySystemReviewTaskPending.java
...m/ruoyi/service/impl/StrategySystemReviewTaskPending.java
+24
-21
StrategySystemReviewTaskSigned.java
...om/ruoyi/service/impl/StrategySystemReviewTaskSigned.java
+95
-0
SystemReviewTaskServiceImpl.java
...a/com/ruoyi/service/impl/SystemReviewTaskServiceImpl.java
+13
-9
TaskServiceImpl.java
...src/main/java/com/ruoyi/service/impl/TaskServiceImpl.java
+156
-0
TaskUserRelationServiceImpl.java
...a/com/ruoyi/service/impl/TaskUserRelationServiceImpl.java
+7
-8
CarReviewTaskController.java
.../src/main/java/com/ruoyi/web/CarReviewTaskController.java
+9
-0
ReviewSceneChangeTaskController.java
...n/java/com/ruoyi/web/ReviewSceneChangeTaskController.java
+17
-24
ReviewTaskUserRelationController.java
.../java/com/ruoyi/web/ReviewTaskUserRelationController.java
+6
-6
SystemReviewTaskController.java
...c/main/java/com/ruoyi/web/SystemReviewTaskController.java
+9
-0
TaskController.java
...ty-review/src/main/java/com/ruoyi/web/TaskController.java
+51
-0
CarReviewTaskConfirmRequest.java
...va/com/ruoyi/web/request/CarReviewTaskConfirmRequest.java
+14
-0
CarReviewTaskCreateRequest.java
...ava/com/ruoyi/web/request/CarReviewTaskCreateRequest.java
+2
-5
ReviewSceneChangeTaskGetInfoRequest.java
...uoyi/web/request/ReviewSceneChangeTaskGetInfoRequest.java
+13
-0
ReviewSceneChangeTaskPassRequest.java
...m/ruoyi/web/request/ReviewSceneChangeTaskPassRequest.java
+3
-0
SystemReviewTaskConfirmRequest.java
...com/ruoyi/web/request/SystemReviewTaskConfirmRequest.java
+14
-0
SystemReviewTaskCreateRequest.java
.../com/ruoyi/web/request/SystemReviewTaskCreateRequest.java
+2
-4
TaskCreateRequest.java
...rc/main/java/com/ruoyi/web/request/TaskCreateRequest.java
+86
-0
TaskListRequest.java
.../src/main/java/com/ruoyi/web/request/TaskListRequest.java
+19
-0
TaskUserRelationMembersRequest.java
...com/ruoyi/web/request/TaskUserRelationMembersRequest.java
+1
-1
CarReviewTaskMapper.xml
...-review/src/main/resources/mapper/CarReviewTaskMapper.xml
+5
-5
ReviewStandardMapper.xml
...review/src/main/resources/mapper/ReviewStandardMapper.xml
+4
-2
StandardMapper.xml
quality-review/src/main/resources/mapper/StandardMapper.xml
+3
-5
SystemReviewTaskMapper.xml
...view/src/main/resources/mapper/SystemReviewTaskMapper.xml
+5
-3
TaskMapper.xml
quality-review/src/main/resources/mapper/TaskMapper.xml
+68
-0
TaskUserRelationMapper.xml
...view/src/main/resources/mapper/TaskUserRelationMapper.xml
+25
-0
No files found.
quality-review/src/main/java/com/ruoyi/domain/CarReviewTask.java
View file @
082c9882
...
...
@@ -23,6 +23,8 @@ import lombok.experimental.Accessors;
@Data
public
class
CarReviewTask
implements
Serializable
{
@TableField
(
exist
=
false
)
public
static
final
String
TASK_STATUS_NEW
=
"NEW"
;
@TableField
(
exist
=
false
)
public
static
final
String
TASK_STATUS_PENDING
=
"PENDING"
;
@TableField
(
exist
=
false
)
...
...
@@ -37,6 +39,8 @@ public class CarReviewTask implements Serializable {
@TableField
(
exist
=
false
)
public
static
final
String
REVIEW_STATUS_PENDING
=
"PENDING"
;
@TableField
(
exist
=
false
)
public
static
final
String
REVIEW_STATUS_SIGNED
=
"SIGNED"
;
@TableField
(
exist
=
false
)
public
static
final
String
REVIEW_STATUS_FINISH
=
"FINISH"
;
...
...
@@ -106,12 +110,6 @@ public class CarReviewTask implements Serializable {
@TableField
(
value
=
"standard"
,
typeHandler
=
StandardJsonTypeHandler
.
class
)
private
List
<
ReviewStandard
>
standard
;
/**
* 占位(开发人员根据具体业务自行增加业务字段)
*/
@ApiModelProperty
(
"占位(开发人员根据具体业务自行增加业务字段)"
)
private
String
bizInfo
;
/**
* 创建时间
*/
...
...
@@ -199,4 +197,7 @@ public class CarReviewTask implements Serializable {
@ApiModelProperty
(
"车型问卷审查结果"
)
private
String
reviewResult
;
@ApiModelProperty
(
"问卷签名图片地址"
)
private
String
reviewImagesUrl
;
}
quality-review/src/main/java/com/ruoyi/domain/ReviewStandard.java
View file @
082c9882
...
...
@@ -82,4 +82,21 @@ public class ReviewStandard {
@ApiModelProperty
(
"文件路径"
)
private
String
file
;
@ApiModelProperty
(
"审核是否通过(0未通过、1通过)"
)
@TableField
(
exist
=
false
)
private
Integer
passed
;
/**
* 符合
*/
@ApiModelProperty
(
"符合"
)
private
String
conformity
;
/**
* 不符合
*/
@ApiModelProperty
(
"不符合"
)
private
String
inconformity
;
}
quality-review/src/main/java/com/ruoyi/domain/Standard.java
View file @
082c9882
...
...
@@ -45,15 +45,4 @@ public class Standard {
@ApiModelProperty
(
"文件路径"
)
private
String
file
;
/**
* 符合
*/
@ApiModelProperty
(
"符合"
)
private
String
conformity
;
/**
* 不符合
*/
@ApiModelProperty
(
"不符合"
)
private
String
inconformity
;
}
quality-review/src/main/java/com/ruoyi/domain/SystemReviewTask.java
View file @
082c9882
...
...
@@ -29,6 +29,8 @@ public class SystemReviewTask {
@TableField
(
exist
=
false
)
public
static
final
String
STATUS_PENDING
=
"PENDING"
;
@TableField
(
exist
=
false
)
public
static
final
String
STATUS_SIGNED
=
"SIGNED"
;
@TableField
(
exist
=
false
)
public
static
final
String
STATUS_FINISH
=
"FINISH"
;
@TableField
(
exist
=
false
)
public
static
final
String
STATUS_CLOSE
=
"CLOSE"
;
...
...
@@ -91,12 +93,6 @@ public class SystemReviewTask {
@TableField
(
value
=
"standard"
,
typeHandler
=
StandardJsonTypeHandler
.
class
)
private
List
<
ReviewStandard
>
standard
;
/**
* 占位(开发人员根据具体业务自行增加业务字段)
*/
@ApiModelProperty
(
"占位(开发人员根据具体业务自行增加业务字段)"
)
private
String
bizInfo
;
/**
* 审核组长id
*/
...
...
@@ -154,4 +150,7 @@ public class SystemReviewTask {
@ApiModelProperty
(
"提交人姓名"
)
private
String
submitByName
;
@ApiModelProperty
(
"签名图片地址"
)
private
String
imagesUrl
;
}
quality-review/src/main/java/com/ruoyi/domain/Task.java
0 → 100644
View file @
082c9882
package
com
.
ruoyi
.
domain
;
import
com.baomidou.mybatisplus.annotation.IdType
;
import
com.baomidou.mybatisplus.annotation.TableField
;
import
com.baomidou.mybatisplus.annotation.TableId
;
import
com.baomidou.mybatisplus.annotation.TableName
;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
com.ruoyi.common.StandardJsonTypeHandler
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
lombok.experimental.Accessors
;
import
java.util.Date
;
import
java.util.List
;
/**
* 任务表
*/
@ApiModel
@TableName
(
value
=
"t_task"
,
autoResultMap
=
true
)
@Accessors
(
chain
=
true
)
@Data
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
)
public
static
final
String
SUB_TASK_GRFIS
=
"grfis"
;
@TableField
(
exist
=
false
)
public
static
final
String
SUB_TASK_TRFIS
=
"trfis"
;
@TableField
(
exist
=
false
)
public
static
final
String
SUB_TASK_SRAIF
=
"sraif"
;
@ApiModelProperty
(
"主键"
)
@TableId
(
type
=
IdType
.
ASSIGN_ID
)
@JsonFormat
(
shape
=
JsonFormat
.
Shape
.
STRING
)
private
Long
id
;
@ApiModelProperty
(
"体系审查任务id"
)
@JsonFormat
(
shape
=
JsonFormat
.
Shape
.
STRING
)
private
Long
systemReviewTaskId
;
@ApiModelProperty
(
"车辆检查任务id"
)
@JsonFormat
(
shape
=
JsonFormat
.
Shape
.
STRING
)
private
Long
carReviewTaskId
;
@ApiModelProperty
(
"任务编号"
)
private
String
taskNo
;
@ApiModelProperty
(
"任务名称"
)
private
String
taskName
;
@ApiModelProperty
(
"任务状态(NEW、PENDING、FINISH)"
)
private
String
taskStatus
;
@ApiModelProperty
(
"产品名称"
)
private
String
productName
;
@ApiModelProperty
(
"产品型号"
)
private
String
productModel
;
@ApiModelProperty
(
"委托单位"
)
private
String
entrustedUnit
;
@ApiModelProperty
(
"委托单位地址"
)
private
String
entrustedUnitAddress
;
@ApiModelProperty
(
"委托单位电话"
)
private
String
entrustedUnitPhone
;
@ApiModelProperty
(
"委托单位邮政编码"
)
private
String
entrustedUnitCode
;
@ApiModelProperty
(
"车辆类型"
)
private
String
carType
;
@ApiModelProperty
(
"车辆识别码"
)
private
String
carIdentificationCode
;
@ApiModelProperty
(
"保密等级"
)
private
String
confidentialityLevel
;
@ApiModelProperty
(
"样品名称"
)
private
String
sampleName
;
@ApiModelProperty
(
"生产企业"
)
private
String
productionEnterprise
;
@ApiModelProperty
(
"送样者"
)
private
String
sampleSender
;
@ApiModelProperty
(
"送样日期"
)
private
Date
sendDate
;
@ApiModelProperty
(
"样品数量"
)
private
String
sampleNumber
;
@ApiModelProperty
(
"生产日期"
)
private
Date
productionDate
;
@ApiModelProperty
(
"商标"
)
private
String
trademark
;
@ApiModelProperty
(
"检验依据"
)
private
String
inspectionBasis
;
@ApiModelProperty
(
"任务发起人姓名"
)
private
String
taskInitiator
;
@ApiModelProperty
(
"任务发起人部门"
)
private
String
taskInitiatorDept
;
@ApiModelProperty
(
"任务开始时间"
)
private
Date
taskBeginTime
;
@ApiModelProperty
(
"任务结束时间"
)
private
Date
taskEndTime
;
@JsonFormat
(
shape
=
JsonFormat
.
Shape
.
STRING
)
@ApiModelProperty
(
"审核组长id"
)
private
Long
leaderId
;
@ApiModelProperty
(
"审核组长姓名"
)
private
String
leader
;
@ApiModelProperty
(
"创建时间"
)
private
Date
createTime
;
@JsonFormat
(
shape
=
JsonFormat
.
Shape
.
STRING
)
@ApiModelProperty
(
"关联标准表id"
)
private
Long
standardId
;
@ApiModelProperty
(
"标准名称"
)
private
String
name
;
@ApiModelProperty
(
"标准号"
)
private
String
standardNo
;
@ApiModelProperty
(
"文件路径"
)
private
String
file
;
}
quality-review/src/main/java/com/ruoyi/domain/
Review
TaskUserRelation.java
→
quality-review/src/main/java/com/ruoyi/domain/TaskUserRelation.java
View file @
082c9882
...
...
@@ -14,10 +14,10 @@ import lombok.experimental.Accessors;
* @TableName t_review_task_user_relation
*/
@ApiModel
@TableName
(
value
=
"t_
review_
task_user_relation"
)
@TableName
(
value
=
"t_task_user_relation"
)
@Accessors
(
chain
=
true
)
@Data
public
class
Review
TaskUserRelation
{
public
class
TaskUserRelation
{
/**
* 任务id
...
...
@@ -46,4 +46,10 @@ public class ReviewTaskUserRelation {
@ApiModelProperty
(
"用户姓名"
)
private
String
name
;
/**
* 部门名称
*/
@ApiModelProperty
(
"部门名称"
)
private
String
deptName
;
}
quality-review/src/main/java/com/ruoyi/mapper/TaskMapper.java
0 → 100644
View file @
082c9882
package
com
.
ruoyi
.
mapper
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
com.ruoyi.domain.Task
;
import
com.ruoyi.web.request.TaskListRequest
;
import
org.apache.ibatis.annotations.Param
;
import
org.springframework.stereotype.Repository
;
import
java.util.List
;
@Repository
public
interface
TaskMapper
extends
BaseMapper
<
Task
>
{
List
<
Task
>
findList
(
TaskListRequest
request
);
}
quality-review/src/main/java/com/ruoyi/mapper/
Review
TaskUserRelationMapper.java
→
quality-review/src/main/java/com/ruoyi/mapper/TaskUserRelationMapper.java
View file @
082c9882
package
com
.
ruoyi
.
mapper
;
import
com.ruoyi.domain.
Review
TaskUserRelation
;
import
com.ruoyi.domain.TaskUserRelation
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
org.apache.ibatis.annotations.Param
;
import
org.springframework.stereotype.Repository
;
...
...
@@ -14,14 +14,14 @@ import java.util.List;
* @Entity com.ruoyi.domain.SystemReviewTaskUserRelation
*/
@Repository
public
interface
ReviewTaskUserRelationMapper
extends
BaseMapper
<
Review
TaskUserRelation
>
{
public
interface
TaskUserRelationMapper
extends
BaseMapper
<
TaskUserRelation
>
{
/**
* 根据任务id查询小组成员
* @param taskId
* @return
*/
List
<
Review
TaskUserRelation
>
selectQTeamMembers
(
@Param
(
"taskId"
)
Long
taskId
);
List
<
TaskUserRelation
>
selectQTeamMembers
(
@Param
(
"taskId"
)
Long
taskId
);
}
...
...
quality-review/src/main/java/com/ruoyi/service/CarReviewTaskService.java
View file @
082c9882
...
...
@@ -41,6 +41,12 @@ public interface CarReviewTaskService extends IService<CarReviewTask> {
*/
void
startReviewTask
(
CarReviewTaskStartRequest
request
);
/**
* 确认一个车辆审查任务中的问卷任务
* @param request
*/
void
confirmReviewTask
(
CarReviewTaskConfirmRequest
request
);
/**
* 提交一个车辆审查任务中的问卷任务
* @param request
...
...
quality-review/src/main/java/com/ruoyi/service/ReviewSceneChangeTaskService.java
View file @
082c9882
...
...
@@ -2,6 +2,7 @@ package com.ruoyi.service;
import
com.ruoyi.domain.ReviewSceneChangeTask
;
import
com.baomidou.mybatisplus.extension.service.IService
;
import
com.ruoyi.web.request.ReviewSceneChangeTaskPassRequest
;
import
com.ruoyi.web.response.ReviewSceneChangeTaskResponse
;
import
java.util.Date
;
...
...
@@ -33,6 +34,12 @@ public interface ReviewSceneChangeTaskService extends IService<ReviewSceneChange
*/
void
reject
(
Long
taskId
,
String
comment
);
/**
* 审核一个任务
* @param request
*/
void
audit
(
ReviewSceneChangeTaskPassRequest
request
);
/**
* 关闭一个任务
* @param taskId
...
...
quality-review/src/main/java/com/ruoyi/service/StrategyCarReviewTask.java
View file @
082c9882
...
...
@@ -9,5 +9,7 @@ public interface StrategyCarReviewTask {
void
doStartReview
(
CarReviewTask
carReviewTask
);
void
doSubmitReview
(
CarReviewTask
carReviewTask
);
void
doConfirmReview
(
CarReviewTask
carReviewTask
);
void
doSubmitReview
(
CarReviewTask
carReviewTask
,
String
imagesUrl
);
}
quality-review/src/main/java/com/ruoyi/service/StrategySystemReviewTask.java
View file @
082c9882
...
...
@@ -7,10 +7,14 @@ public interface StrategySystemReviewTask {
void
doStart
(
SystemReviewTask
systemReviewTask
);
void
doSubmit
(
SystemReviewTask
systemReviewTask
);
void
doConfirm
(
SystemReviewTask
systemReviewTask
);
void
doSubmit
(
SystemReviewTask
systemReviewTask
,
String
imagesUrl
);
void
doClose
(
SystemReviewTask
systemReviewTask
);
SystemReviewTaskViewResponse
doView
(
SystemReviewTask
systemReviewTask
);
}
quality-review/src/main/java/com/ruoyi/service/SystemReviewTaskService.java
View file @
082c9882
...
...
@@ -2,6 +2,7 @@ package com.ruoyi.service;
import
com.ruoyi.domain.SystemReviewTask
;
import
com.baomidou.mybatisplus.extension.service.IService
;
import
com.ruoyi.web.request.SystemReviewTaskConfirmRequest
;
import
com.ruoyi.web.request.SystemReviewTaskCreateRequest
;
import
com.ruoyi.web.request.SystemReviewTaskStartRequest
;
import
com.ruoyi.web.request.SystemReviewTaskSubmitRequest
;
...
...
@@ -47,6 +48,12 @@ public interface SystemReviewTaskService extends IService<SystemReviewTask> {
*/
List
<
SystemReviewTask
>
findListInProcess
();
/**
* 确认审查问卷
* @param request
*/
void
confirm
(
SystemReviewTaskConfirmRequest
request
);
/**
* 提交审查问卷
* @param request
...
...
quality-review/src/main/java/com/ruoyi/service/TaskService.java
0 → 100644
View file @
082c9882
package
com
.
ruoyi
.
service
;
import
com.baomidou.mybatisplus.extension.service.IService
;
import
com.ruoyi.domain.Task
;
import
com.ruoyi.web.request.TaskCreateRequest
;
import
com.ruoyi.web.request.TaskListRequest
;
import
java.util.List
;
public
interface
TaskService
extends
IService
<
Task
>
{
/**
* 查询任务表
* @param request
* @return
*/
List
<
Task
>
findList
(
TaskListRequest
request
);
void
createTask
(
TaskCreateRequest
request
);
}
quality-review/src/main/java/com/ruoyi/service/
Review
TaskUserRelationService.java
→
quality-review/src/main/java/com/ruoyi/service/TaskUserRelationService.java
View file @
082c9882
package
com
.
ruoyi
.
service
;
import
com.ruoyi.domain.
Review
TaskUserRelation
;
import
com.ruoyi.domain.TaskUserRelation
;
import
com.baomidou.mybatisplus.extension.service.IService
;
import
org.apache.ibatis.annotations.Param
;
import
java.util.List
;
/**
* @author wangfei
* @description 针对表【t_
system_review_
task_user_relation(体系审查任务&用户映射关系)】的数据库操作Service
* @description 针对表【t_task_user_relation(体系审查任务&用户映射关系)】的数据库操作Service
* @createDate 2023-12-15 10:41:16
*/
public
interface
ReviewTaskUserRelationService
extends
IService
<
Review
TaskUserRelation
>
{
public
interface
TaskUserRelationService
extends
IService
<
TaskUserRelation
>
{
/**
* 根据任务id查询小组成员
* @param taskId
* @return
*/
List
<
Review
TaskUserRelation
>
selectQTeamMembers
(
Long
taskId
);
List
<
TaskUserRelation
>
selectQTeamMembers
(
Long
taskId
);
}
quality-review/src/main/java/com/ruoyi/service/impl/CarReviewTaskServiceImpl.java
View file @
082c9882
package
com
.
ruoyi
.
service
.
impl
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
com.ruoyi.common.constant.HttpStatus
;
import
com.ruoyi.common.core.domain.entity.SysUser
;
import
com.ruoyi.common.core.domain.model.LoginUser
;
import
com.ruoyi.common.exception.ServiceException
;
import
com.ruoyi.common.utils.SecurityUtils
;
import
com.ruoyi.common.utils.SnowflakeUtil
;
import
com.ruoyi.domain.*
;
import
com.ruoyi.mapper.ReviewDetailsMapper
;
import
com.ruoyi.service.CarReviewTaskService
;
import
com.ruoyi.mapper.CarReviewTaskMapper
;
import
com.ruoyi.service.
Review
TaskUserRelationService
;
import
com.ruoyi.service.TaskUserRelationService
;
import
com.ruoyi.service.StandardService
;
import
com.ruoyi.system.service.ISysUserService
;
import
com.ruoyi.web.request.CarReviewTaskConfirmRequest
;
import
com.ruoyi.web.request.CarReviewTaskCreateRequest
;
import
com.ruoyi.web.request.CarReviewTaskStartRequest
;
import
com.ruoyi.web.request.CarReviewTaskSubmitRequest
;
import
com.ruoyi.web.response.CarReviewTaskViewResponse
;
import
com.ruoyi.web.response.SystemReviewTaskViewResponse
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
org.springframework.transaction.annotation.Transactional
;
...
...
@@ -49,7 +47,7 @@ public class CarReviewTaskServiceImpl extends ServiceImpl<CarReviewTaskMapper, C
private
CarReviewTaskService
carReviewTaskService
;
@Autowired
private
Review
TaskUserRelationService
relationService
;
private
TaskUserRelationService
relationService
;
@Autowired
private
StrategyCarReviewTaskContext
strategyCarReviewTaskContext
;
...
...
@@ -71,9 +69,9 @@ public class CarReviewTaskServiceImpl extends ServiceImpl<CarReviewTaskMapper, C
Standard
standard
=
standardService
.
findListById
(
request
.
getStandardId
());
// 找到审查组长
Review
TaskUserRelation
leader
=
null
;
List
<
Review
TaskUserRelation
>
auditors
=
request
.
getAuditors
();
for
(
Review
TaskUserRelation
auditor
:
auditors
)
{
TaskUserRelation
leader
=
null
;
List
<
TaskUserRelation
>
auditors
=
request
.
getAuditors
();
for
(
TaskUserRelation
auditor
:
auditors
)
{
if
(
auditor
.
getIsLeader
()
==
1
)
{
leader
=
auditor
;
break
;
...
...
@@ -85,8 +83,7 @@ public class CarReviewTaskServiceImpl extends ServiceImpl<CarReviewTaskMapper, C
.
setTaskNo
(
SnowflakeUtil
.
generate
().
toString
())
.
setTaskInitiator
(
initiator
.
getNickName
())
.
setTaskInitiatorDept
(
initiator
.
getDept
().
getDeptName
())
.
setTaskStatus
(
CarReviewTask
.
TASK_STATUS_PENDING
)
.
setBizInfo
(
request
.
getBizInfo
())
.
setTaskStatus
(
CarReviewTask
.
TASK_STATUS_NEW
)
.
setLeaderId
(
leader
.
getUserId
())
.
setLeader
(
leader
.
getName
())
.
setCreateTime
(
new
Date
())
...
...
@@ -111,7 +108,7 @@ public class CarReviewTaskServiceImpl extends ServiceImpl<CarReviewTaskMapper, C
// 构建并保存该任务所关联的审核组信息
for
(
Review
TaskUserRelation
auditor
:
auditors
)
{
for
(
TaskUserRelation
auditor
:
auditors
)
{
auditor
.
setTaskId
(
task
.
getId
());
}
relationService
.
saveBatch
(
auditors
);
...
...
@@ -129,11 +126,18 @@ public class CarReviewTaskServiceImpl extends ServiceImpl<CarReviewTaskMapper, C
strategyCarReviewTaskContext
.
getResource
(
carReviewTask
.
getReviewStatus
()).
doStartReview
(
carReviewTask
);
}
@Override
public
void
confirmReviewTask
(
CarReviewTaskConfirmRequest
request
)
{
CarReviewTask
carReviewTask
=
carReviewTaskService
.
getById
(
request
.
getTaskId
());
strategyCarReviewTaskContext
.
getResource
(
carReviewTask
.
getReviewStatus
()).
doConfirmReview
(
carReviewTask
);
}
@Override
public
void
submitReviewTask
(
CarReviewTaskSubmitRequest
request
)
{
CarReviewTask
carReviewTask
=
carReviewTaskService
.
getById
(
request
.
getTaskId
());
strategyCarReviewTaskContext
.
getResource
(
carReviewTask
.
getReviewStatus
()).
doSubmitReview
(
carReviewTask
);
strategyCarReviewTaskContext
.
getResource
(
carReviewTask
.
getReviewStatus
()).
doSubmitReview
(
carReviewTask
,
request
.
getImagesUrl
()
);
}
@Override
...
...
quality-review/src/main/java/com/ruoyi/service/impl/ReviewSceneChangeTaskServiceImpl.java
View file @
082c9882
...
...
@@ -13,6 +13,7 @@ import com.ruoyi.service.ReviewSceneChangeTaskUserRelationService;
import
com.ruoyi.service.ReviewSceneService
;
import
com.ruoyi.service.ReviewTaskInboxService
;
import
com.ruoyi.system.service.ISysUserService
;
import
com.ruoyi.web.request.ReviewSceneChangeTaskPassRequest
;
import
com.ruoyi.web.response.ReviewSceneChangeTaskResponse
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
...
...
@@ -87,11 +88,24 @@ public class ReviewSceneChangeTaskServiceImpl extends ServiceImpl<ReviewSceneCha
doProcess
(
taskId
,
comment
,
ReviewSceneChangeTask
.
RESULT_PASS
);
}
@Override
public
void
reject
(
Long
taskId
,
String
comment
)
{
doProcess
(
taskId
,
comment
,
ReviewSceneChangeTask
.
RESULT_REJECT
);
}
@Override
public
void
audit
(
ReviewSceneChangeTaskPassRequest
request
)
{
if
(
request
.
getPassed
().
equals
(
"0"
))
{
doProcess
(
request
.
getTaskId
(),
request
.
getComment
(),
ReviewSceneChangeTask
.
RESULT_REJECT
);
}
else
if
(
request
.
getPassed
().
equals
(
"1"
)){
doProcess
(
request
.
getTaskId
(),
request
.
getComment
(),
ReviewSceneChangeTask
.
RESULT_PASS
);
}
else
{
throw
new
ServiceException
(
"审核状态不正确"
,
HttpStatus
.
ERROR
);
}
}
public
void
doProcess
(
Long
taskId
,
String
comment
,
String
decision
)
{
ReviewSceneChangeTask
task
=
getById
(
taskId
);
...
...
quality-review/src/main/java/com/ruoyi/service/impl/StrategyCarReviewTaskFinish.java
View file @
082c9882
...
...
@@ -39,7 +39,12 @@ public class StrategyCarReviewTaskFinish implements StrategyCarReviewTask, Initi
}
@Override
public
void
doSubmitReview
(
CarReviewTask
carReviewTask
)
{
public
void
doConfirmReview
(
CarReviewTask
carReviewTask
)
{
throw
new
ServiceException
(
"不能确认一个结束的任务"
,
HttpStatus
.
ERROR
);
}
@Override
public
void
doSubmitReview
(
CarReviewTask
carReviewTask
,
String
imagesUrl
)
{
throw
new
ServiceException
(
"不能提交一个结束的任务"
,
HttpStatus
.
ERROR
);
}
...
...
quality-review/src/main/java/com/ruoyi/service/impl/StrategyCarReviewTaskNew.java
View file @
082c9882
...
...
@@ -62,7 +62,12 @@ public class StrategyCarReviewTaskNew implements StrategyCarReviewTask, Initiali
}
@Override
public
void
doSubmitReview
(
CarReviewTask
carReviewTask
)
{
public
void
doConfirmReview
(
CarReviewTask
carReviewTask
)
{
throw
new
ServiceException
(
"不能确认一个未开始的任务"
,
HttpStatus
.
ERROR
);
}
@Override
public
void
doSubmitReview
(
CarReviewTask
carReviewTask
,
String
imagesUrl
)
{
throw
new
ServiceException
(
"不能提交一个未开始的任务"
,
HttpStatus
.
ERROR
);
}
...
...
quality-review/src/main/java/com/ruoyi/service/impl/StrategyCarReviewTaskNone.java
View file @
082c9882
...
...
@@ -34,7 +34,12 @@ public class StrategyCarReviewTaskNone implements StrategyCarReviewTask, Initial
}
@Override
public
void
doSubmitReview
(
CarReviewTask
carReviewTask
)
{
public
void
doConfirmReview
(
CarReviewTask
carReviewTask
)
{
throw
new
ServiceException
(
"不能确认一个不存在的任务"
,
HttpStatus
.
ERROR
);
}
@Override
public
void
doSubmitReview
(
CarReviewTask
carReviewTask
,
String
imagesUrl
)
{
throw
new
ServiceException
(
"不能提交一个不存在的任务"
,
HttpStatus
.
ERROR
);
}
...
...
quality-review/src/main/java/com/ruoyi/service/impl/StrategyCarReviewTaskPending.java
View file @
082c9882
...
...
@@ -89,8 +89,7 @@ public class StrategyCarReviewTaskPending implements StrategyCarReviewTask, Init
}
@Override
public
void
doSubmitReview
(
CarReviewTask
carReviewTask
)
{
public
void
doConfirmReview
(
CarReviewTask
carReviewTask
)
{
List
<
ReviewDetails
>
detailsList
=
reviewDetailsMapper
.
findNoResult
(
carReviewTask
.
getId
());
if
(
detailsList
!=
null
)
{
...
...
@@ -106,15 +105,8 @@ public class StrategyCarReviewTaskPending implements StrategyCarReviewTask, Init
setDetailsResult
(
standardTree
,
results
);
carReviewTask
.
setStandard
(
standardTree
);
// 4. 填充review_submit_time
carReviewTask
.
setReviewSubmitTime
(
new
Date
());
// 5. 修改任务状态为 FINISH
carReviewTask
.
setReviewStatus
(
CarReviewTask
.
REVIEW_STATUS_FINISH
);
// 6. 填写当前用户id
// 获取当前登陆人
SysUser
loginUser
=
SecurityUtils
.
getLoginUser
().
getUser
();
carReviewTask
.
setReviewSubmitId
(
loginUser
.
getUserId
());
carReviewTask
.
setReviewSubmitName
(
loginUser
.
getNickName
());
// 4. 修改任务状态为 SIGNED 待签字
carReviewTask
.
setReviewStatus
(
CarReviewTask
.
REVIEW_STATUS_SIGNED
);
// 7. 设置问卷结果
if
(
reviewDetailsResultMapper
.
findNotPass
(
carReviewTask
.
getId
())
>
0
)
{
...
...
@@ -124,6 +116,12 @@ public class StrategyCarReviewTaskPending implements StrategyCarReviewTask, Init
}
carReviewTaskMapper
.
updateById
(
carReviewTask
);
}
}
@Override
public
void
doSubmitReview
(
CarReviewTask
carReviewTask
,
String
imagesUrl
)
{
throw
new
ServiceException
(
"不能提交一个未确认的任务"
,
HttpStatus
.
ERROR
);
}
...
...
@@ -132,13 +130,18 @@ public class StrategyCarReviewTaskPending implements StrategyCarReviewTask, Init
Map
<
Long
,
ReviewDetailsResult
>
resultMap
=
results
.
stream
().
collect
(
Collectors
.
toMap
(
ReviewDetailsResult:
:
getReviewDetailsId
,
Function
.
identity
(),
(
v1
,
v2
)
->
v1
));
for
(
ReviewStandard
standard
:
standards
)
{
standard
.
setPassed
(
0
);
List
<
ReviewKeyPoint
>
keyPointList
=
standard
.
getKeyPointList
();
for
(
ReviewKeyPoint
keypoint
:
keyPointList
)
{
List
<
ReviewDetails
>
reviewDetailsList
=
keypoint
.
getReviewDetailsList
();
for
(
ReviewDetails
details
:
reviewDetailsList
)
{
details
.
setResult
(
resultMap
.
get
(
details
.
getId
()));
ReviewDetailsResult
reviewDetailsResult
=
resultMap
.
get
(
details
.
getId
());
if
(
reviewDetailsResult
.
getPassed
()
!=
0
)
{
standard
.
setPassed
(
reviewDetailsResult
.
getPassed
());
}
details
.
setResult
(
reviewDetailsResult
);
}
}
}
...
...
quality-review/src/main/java/com/ruoyi/service/impl/StrategyCarReviewTaskSigned.java
0 → 100644
View file @
082c9882
package
com
.
ruoyi
.
service
.
impl
;
import
com.ruoyi.common.constant.HttpStatus
;
import
com.ruoyi.common.core.domain.entity.SysUser
;
import
com.ruoyi.common.exception.ServiceException
;
import
com.ruoyi.common.utils.SecurityUtils
;
import
com.ruoyi.domain.*
;
import
com.ruoyi.mapper.CarReviewTaskMapper
;
import
com.ruoyi.mapper.ReviewDetailsMapper
;
import
com.ruoyi.mapper.ReviewDetailsResultMapper
;
import
com.ruoyi.service.ReviewDetailsResultService
;
import
com.ruoyi.service.ReviewSceneChangeTaskService
;
import
com.ruoyi.service.ReviewStandardService
;
import
com.ruoyi.service.StrategyCarReviewTask
;
import
com.ruoyi.web.response.CarReviewTaskViewResponse
;
import
org.springframework.beans.factory.InitializingBean
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.context.ApplicationContext
;
import
org.springframework.stereotype.Service
;
import
org.springframework.transaction.annotation.Transactional
;
import
java.util.Date
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.function.Function
;
import
java.util.stream.Collectors
;
@Transactional
@Service
public
class
StrategyCarReviewTaskSigned
implements
StrategyCarReviewTask
,
InitializingBean
{
@Autowired
private
StrategyCarReviewTaskContext
strategyCarReviewTaskContext
;
@Autowired
private
ApplicationContext
applicationContext
;
@Autowired
private
CarReviewTaskMapper
carReviewTaskMapper
;
// SIGNED状态下
// 1.standard字段使用task中归档的问卷
// 2.不查询场景变更任务
// 3.无需联查问卷答案
@Override
public
CarReviewTaskViewResponse
doView
(
CarReviewTask
carReviewTask
)
{
CarReviewTaskViewResponse
response
=
new
CarReviewTaskViewResponse
();
response
.
setCarReviewTask
(
carReviewTask
);
return
response
;
}
@Override
public
void
doStartReview
(
CarReviewTask
carReviewTask
)
{
throw
new
ServiceException
(
"不能开始一个已确认的任务"
,
HttpStatus
.
ERROR
);
}
@Override
public
void
doConfirmReview
(
CarReviewTask
carReviewTask
)
{
throw
new
ServiceException
(
"不能确认一个已确认的任务"
,
HttpStatus
.
ERROR
);
}
@Override
public
void
doSubmitReview
(
CarReviewTask
carReviewTask
,
String
imagesUrl
)
{
// 1. 填充review_submit_time
carReviewTask
.
setReviewSubmitTime
(
new
Date
());
// 2. 修改任务状态为 FINISH
carReviewTask
.
setReviewStatus
(
CarReviewTask
.
REVIEW_STATUS_FINISH
);
// 3. 填写当前用户id
// 获取当前登陆人
SysUser
loginUser
=
SecurityUtils
.
getLoginUser
().
getUser
();
carReviewTask
.
setReviewSubmitId
(
loginUser
.
getUserId
());
carReviewTask
.
setReviewSubmitName
(
loginUser
.
getNickName
());
// 4. 保存签名图片地址
carReviewTask
.
setReviewImagesUrl
(
imagesUrl
);
carReviewTaskMapper
.
updateById
(
carReviewTask
);
}
@Override
public
void
afterPropertiesSet
()
throws
Exception
{
strategyCarReviewTaskContext
.
putResource
(
CarReviewTask
.
REVIEW_STATUS_SIGNED
,
applicationContext
.
getBean
(
this
.
getClass
()));
}
}
quality-review/src/main/java/com/ruoyi/service/impl/StrategySystemReviewTaskClose.java
View file @
082c9882
...
...
@@ -26,7 +26,7 @@ public class StrategySystemReviewTaskClose implements StrategySystemReviewTask,
}
@Override
public
void
doSubmit
(
SystemReviewTask
systemReviewTask
)
{
public
void
doSubmit
(
SystemReviewTask
systemReviewTask
,
String
imagesUrl
)
{
throw
new
ServiceException
(
"不能提交一个已关闭的任务"
,
HttpStatus
.
ERROR
);
}
...
...
@@ -35,6 +35,11 @@ public class StrategySystemReviewTaskClose implements StrategySystemReviewTask,
throw
new
ServiceException
(
"不能关闭一个已关闭的任务"
,
HttpStatus
.
ERROR
);
}
@Override
public
void
doConfirm
(
SystemReviewTask
systemReviewTask
)
{
throw
new
ServiceException
(
"不能确认一个已关闭的任务"
,
HttpStatus
.
ERROR
);
}
// CLOSE状态下
// 1.standard字段使用task中归档的问卷
// 2.不查询场景变更任务
...
...
quality-review/src/main/java/com/ruoyi/service/impl/StrategySystemReviewTaskFinish.java
View file @
082c9882
...
...
@@ -26,7 +26,7 @@ public class StrategySystemReviewTaskFinish implements StrategySystemReviewTask,
}
@Override
public
void
doSubmit
(
SystemReviewTask
systemReviewTask
)
{
public
void
doSubmit
(
SystemReviewTask
systemReviewTask
,
String
imagesUrl
)
{
throw
new
ServiceException
(
"不能提交一个已完成的任务"
,
HttpStatus
.
ERROR
);
}
...
...
@@ -35,6 +35,11 @@ public class StrategySystemReviewTaskFinish implements StrategySystemReviewTask,
throw
new
ServiceException
(
"不能关闭一个已完成的任务"
,
HttpStatus
.
ERROR
);
}
@Override
public
void
doConfirm
(
SystemReviewTask
systemReviewTask
)
{
throw
new
ServiceException
(
"不能确认一个已完成的任务"
,
HttpStatus
.
ERROR
);
}
// FINISH状态下
// 1.standard字段使用task中归档的问卷
// 2.不查询场景变更任务
...
...
quality-review/src/main/java/com/ruoyi/service/impl/StrategySystemReviewTaskNew.java
View file @
082c9882
...
...
@@ -40,7 +40,7 @@ public class StrategySystemReviewTaskNew implements StrategySystemReviewTask, In
}
@Override
public
void
doSubmit
(
SystemReviewTask
systemReviewTask
)
{
public
void
doSubmit
(
SystemReviewTask
systemReviewTask
,
String
imagesUrl
)
{
throw
new
ServiceException
(
"不能提交一个尚未开始的任务"
,
HttpStatus
.
ERROR
);
}
...
...
@@ -51,6 +51,11 @@ public class StrategySystemReviewTaskNew implements StrategySystemReviewTask, In
systemReviewTaskMapper
.
updateById
(
systemReviewTask
);
}
@Override
public
void
doConfirm
(
SystemReviewTask
systemReviewTask
)
{
throw
new
ServiceException
(
"不能确认一个尚未开始的任务"
,
HttpStatus
.
ERROR
);
}
// NEW状态下
// 1.standard字段查询当前最新问卷
// 2.不查询场景变更任务
...
...
quality-review/src/main/java/com/ruoyi/service/impl/StrategySystemReviewTaskPending.java
View file @
082c9882
...
...
@@ -55,7 +55,19 @@ public class StrategySystemReviewTaskPending implements StrategySystemReviewTask
}
@Override
public
void
doSubmit
(
SystemReviewTask
systemReviewTask
)
{
public
void
doSubmit
(
SystemReviewTask
systemReviewTask
,
String
imagesUrl
)
{
throw
new
ServiceException
(
"不能提交一个未确认的任务"
,
HttpStatus
.
ERROR
);
}
@Override
public
void
doClose
(
SystemReviewTask
systemReviewTask
)
{
systemReviewTask
.
setTaskEndTime
(
new
Date
());
systemReviewTask
.
setTaskStatus
(
SystemReviewTask
.
STATUS_CLOSE
);
systemReviewTaskMapper
.
updateById
(
systemReviewTask
);
}
@Override
public
void
doConfirm
(
SystemReviewTask
systemReviewTask
)
{
// TODO
List
<
ReviewDetails
>
detailsList
=
reviewDetailsMapper
.
findNoResult
(
systemReviewTask
.
getId
());
if
(
detailsList
!=
null
)
{
...
...
@@ -69,19 +81,13 @@ public class StrategySystemReviewTaskPending implements StrategySystemReviewTask
// 3. 将最终问卷归档到 standard 字段
setDetailsResult
(
standardTree
,
results
);
systemReviewTask
.
setStandard
(
standardTree
);
// 4. 填充task_end_time
systemReviewTask
.
setTaskEndTime
(
new
Date
());
// 5. 修改任务状态为 FINISH
systemReviewTask
.
setTaskStatus
(
SystemReviewTask
.
STATUS_FINISH
);
// 6. 填写当前用户id
// 获取当前登陆人
SysUser
loginUser
=
SecurityUtils
.
getLoginUser
().
getUser
();
systemReviewTask
.
setSubmitById
(
loginUser
.
getUserId
());
systemReviewTask
.
setSubmitByName
(
loginUser
.
getNickName
());
// 7. 设置问卷结果
// 4. 修改任务状态为 SIGNED 待签字
systemReviewTask
.
setTaskStatus
(
SystemReviewTask
.
STATUS_SIGNED
);
// 5. 设置问卷结果
if
(
reviewDetailsResultMapper
.
findNotPass
(
systemReviewTask
.
getId
())
>
0
)
{
systemReviewTask
.
setTaskResult
(
"REJECT"
);
}
else
{
...
...
@@ -89,14 +95,6 @@ public class StrategySystemReviewTaskPending implements StrategySystemReviewTask
}
systemReviewTaskMapper
.
updateById
(
systemReviewTask
);
}
}
@Override
public
void
doClose
(
SystemReviewTask
systemReviewTask
)
{
systemReviewTask
.
setTaskEndTime
(
new
Date
());
systemReviewTask
.
setTaskStatus
(
SystemReviewTask
.
STATUS_CLOSE
);
systemReviewTaskMapper
.
updateById
(
systemReviewTask
);
}
// PENDING状态下
...
...
@@ -134,13 +132,18 @@ public class StrategySystemReviewTaskPending implements StrategySystemReviewTask
Map
<
Long
,
ReviewDetailsResult
>
resultMap
=
results
.
stream
().
collect
(
Collectors
.
toMap
(
ReviewDetailsResult:
:
getReviewDetailsId
,
Function
.
identity
(),
(
v1
,
v2
)
->
v1
));
for
(
ReviewStandard
standard
:
standards
)
{
standard
.
setPassed
(
0
);
List
<
ReviewKeyPoint
>
keyPointList
=
standard
.
getKeyPointList
();
for
(
ReviewKeyPoint
keypoint
:
keyPointList
)
{
List
<
ReviewDetails
>
reviewDetailsList
=
keypoint
.
getReviewDetailsList
();
for
(
ReviewDetails
details
:
reviewDetailsList
)
{
details
.
setResult
(
resultMap
.
get
(
details
.
getId
()));
ReviewDetailsResult
reviewDetailsResult
=
resultMap
.
get
(
details
.
getId
());
if
(
reviewDetailsResult
.
getPassed
()
!=
0
)
{
standard
.
setPassed
(
reviewDetailsResult
.
getPassed
());
}
details
.
setResult
(
reviewDetailsResult
);
}
}
}
...
...
quality-review/src/main/java/com/ruoyi/service/impl/StrategySystemReviewTaskSigned.java
0 → 100644
View file @
082c9882
package
com
.
ruoyi
.
service
.
impl
;
import
com.ruoyi.common.constant.HttpStatus
;
import
com.ruoyi.common.core.domain.entity.SysUser
;
import
com.ruoyi.common.exception.ServiceException
;
import
com.ruoyi.common.utils.SecurityUtils
;
import
com.ruoyi.domain.*
;
import
com.ruoyi.mapper.ReviewDetailsMapper
;
import
com.ruoyi.mapper.ReviewDetailsResultMapper
;
import
com.ruoyi.mapper.SystemReviewTaskMapper
;
import
com.ruoyi.service.ReviewDetailsResultService
;
import
com.ruoyi.service.ReviewSceneChangeTaskService
;
import
com.ruoyi.service.ReviewStandardService
;
import
com.ruoyi.service.StrategySystemReviewTask
;
import
com.ruoyi.web.response.SystemReviewTaskViewResponse
;
import
org.springframework.beans.factory.InitializingBean
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.context.ApplicationContext
;
import
org.springframework.stereotype.Service
;
import
org.springframework.transaction.annotation.Transactional
;
import
java.util.Date
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.function.Function
;
import
java.util.stream.Collectors
;
@Transactional
@Service
public
class
StrategySystemReviewTaskSigned
implements
StrategySystemReviewTask
,
InitializingBean
{
@Autowired
private
StrategySystemReviewTaskContext
strategySystemReviewTaskContext
;
@Autowired
private
ApplicationContext
applicationContext
;
@Autowired
private
SystemReviewTaskMapper
systemReviewTaskMapper
;
@Override
public
void
doStart
(
SystemReviewTask
systemReviewTask
)
{
throw
new
ServiceException
(
"不能开始一个已确认的任务"
,
HttpStatus
.
ERROR
);
}
@Override
public
void
doConfirm
(
SystemReviewTask
systemReviewTask
)
{
throw
new
ServiceException
(
"不能确认一个已确认的任务"
,
HttpStatus
.
ERROR
);
}
@Override
public
void
doSubmit
(
SystemReviewTask
systemReviewTask
,
String
imagesUrl
)
{
// 1. 填充task_end_time
systemReviewTask
.
setTaskEndTime
(
new
Date
());
// 2. 修改任务状态为 FINISH
systemReviewTask
.
setTaskStatus
(
SystemReviewTask
.
STATUS_FINISH
);
// 3. 填写当前用户id
// 获取当前登陆人
SysUser
loginUser
=
SecurityUtils
.
getLoginUser
().
getUser
();
systemReviewTask
.
setSubmitById
(
loginUser
.
getUserId
());
systemReviewTask
.
setSubmitByName
(
loginUser
.
getNickName
());
// 4.保存签名图片地址
systemReviewTask
.
setImagesUrl
(
imagesUrl
);
systemReviewTaskMapper
.
updateById
(
systemReviewTask
);
}
@Override
public
void
doClose
(
SystemReviewTask
systemReviewTask
)
{
throw
new
ServiceException
(
"不能关闭一个已确认的任务"
,
HttpStatus
.
ERROR
);
}
// SIGNED状态下
// 1.standard字段使用task中归档的问卷
// 2.不查询场景变更任务
// 3.无需联查问卷答案
@Override
public
SystemReviewTaskViewResponse
doView
(
SystemReviewTask
systemReviewTask
)
{
SystemReviewTaskViewResponse
response
=
new
SystemReviewTaskViewResponse
();
response
.
setSystemReviewTask
(
systemReviewTask
);
return
response
;
}
@Override
public
void
afterPropertiesSet
()
throws
Exception
{
strategySystemReviewTaskContext
.
putResource
(
SystemReviewTask
.
STATUS_SIGNED
,
applicationContext
.
getBean
(
this
.
getClass
()));
}
}
quality-review/src/main/java/com/ruoyi/service/impl/SystemReviewTaskServiceImpl.java
View file @
082c9882
package
com
.
ruoyi
.
service
.
impl
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
com.ruoyi.common.constant.HttpStatus
;
import
com.ruoyi.common.core.domain.entity.SysUser
;
import
com.ruoyi.common.core.domain.model.LoginUser
;
import
com.ruoyi.common.exception.ServiceException
;
import
com.ruoyi.common.utils.SecurityUtils
;
import
com.ruoyi.common.utils.SnowflakeUtil
;
import
com.ruoyi.domain.*
;
...
...
@@ -12,6 +10,7 @@ import com.ruoyi.mapper.ReviewDetailsMapper;
import
com.ruoyi.mapper.SystemReviewTaskMapper
;
import
com.ruoyi.service.*
;
import
com.ruoyi.system.service.ISysUserService
;
import
com.ruoyi.web.request.SystemReviewTaskConfirmRequest
;
import
com.ruoyi.web.request.SystemReviewTaskCreateRequest
;
import
com.ruoyi.web.request.SystemReviewTaskStartRequest
;
import
com.ruoyi.web.request.SystemReviewTaskSubmitRequest
;
...
...
@@ -32,7 +31,7 @@ import java.util.*;
public
class
SystemReviewTaskServiceImpl
extends
ServiceImpl
<
SystemReviewTaskMapper
,
SystemReviewTask
>
implements
SystemReviewTaskService
{
@Autowired
private
Review
TaskUserRelationService
systemReviewTaskUserRelationService
;
private
TaskUserRelationService
systemReviewTaskUserRelationService
;
@Autowired
private
SystemReviewTaskService
systemReviewTaskService
;
...
...
@@ -62,9 +61,9 @@ public class SystemReviewTaskServiceImpl extends ServiceImpl<SystemReviewTaskMap
Standard
standard
=
standardService
.
findListById
(
request
.
getStandardId
());
// 找到审查组长
Review
TaskUserRelation
leader
=
null
;
List
<
Review
TaskUserRelation
>
auditors
=
request
.
getAuditors
();
for
(
Review
TaskUserRelation
auditor
:
auditors
)
{
TaskUserRelation
leader
=
null
;
List
<
TaskUserRelation
>
auditors
=
request
.
getAuditors
();
for
(
TaskUserRelation
auditor
:
auditors
)
{
if
(
auditor
.
getIsLeader
()
==
1
)
{
leader
=
auditor
;
break
;
...
...
@@ -77,7 +76,6 @@ public class SystemReviewTaskServiceImpl extends ServiceImpl<SystemReviewTaskMap
.
setTaskInitiator
(
initiator
.
getNickName
())
.
setTaskInitiatorDept
(
initiator
.
getDept
().
getDeptName
())
.
setTaskStatus
(
SystemReviewTask
.
STATUS_NEW
)
.
setBizInfo
(
request
.
getBizInfo
())
.
setLeaderId
(
leader
.
getUserId
())
.
setLeader
(
leader
.
getName
())
.
setCreateTime
(
new
Date
())
...
...
@@ -90,7 +88,7 @@ public class SystemReviewTaskServiceImpl extends ServiceImpl<SystemReviewTaskMap
// 构建并保存该任务所关联的审核组信息
for
(
Review
TaskUserRelation
auditor
:
auditors
)
{
for
(
TaskUserRelation
auditor
:
auditors
)
{
auditor
.
setTaskId
(
task
.
getId
());
}
systemReviewTaskUserRelationService
.
saveBatch
(
auditors
);
...
...
@@ -118,10 +116,16 @@ public class SystemReviewTaskServiceImpl extends ServiceImpl<SystemReviewTaskMap
return
systemReviewTaskMapper
.
findListInProcess
();
}
@Override
public
void
confirm
(
SystemReviewTaskConfirmRequest
request
)
{
SystemReviewTask
systemReviewTask
=
systemReviewTaskService
.
getById
(
request
.
getTaskId
());
strategySystemReviewTaskContext
.
getResource
(
systemReviewTask
.
getTaskStatus
()).
doConfirm
(
systemReviewTask
);
}
@Override
public
void
submit
(
SystemReviewTaskSubmitRequest
request
)
{
SystemReviewTask
systemReviewTask
=
systemReviewTaskService
.
getById
(
request
.
getTaskId
());
strategySystemReviewTaskContext
.
getResource
(
systemReviewTask
.
getTaskStatus
()).
doSubmit
(
systemReviewTask
);
strategySystemReviewTaskContext
.
getResource
(
systemReviewTask
.
getTaskStatus
()).
doSubmit
(
systemReviewTask
,
request
.
getImagesUrl
()
);
}
}
...
...
quality-review/src/main/java/com/ruoyi/service/impl/TaskServiceImpl.java
0 → 100644
View file @
082c9882
package
com
.
ruoyi
.
service
.
impl
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
com.ruoyi.common.core.domain.entity.SysDictData
;
import
com.ruoyi.common.core.domain.entity.SysUser
;
import
com.ruoyi.common.core.domain.model.LoginUser
;
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.TaskMapper
;
import
com.ruoyi.service.*
;
import
com.ruoyi.system.service.ISysUserService
;
import
com.ruoyi.web.request.TaskCreateRequest
;
import
com.ruoyi.web.request.TaskListRequest
;
import
org.checkerframework.checker.units.qual.A
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
org.springframework.transaction.annotation.Transactional
;
import
java.util.Date
;
import
java.util.List
;
@Transactional
@Service
public
class
TaskServiceImpl
extends
ServiceImpl
<
TaskMapper
,
Task
>
implements
TaskService
{
@Autowired
private
TaskMapper
taskMapper
;
@Autowired
private
ISysUserService
sysUserService
;
@Autowired
private
StandardService
standardService
;
@Autowired
private
TaskUserRelationService
taskUserRelationService
;
@Autowired
private
TaskService
taskService
;
@Autowired
private
SystemReviewTaskService
systemReviewTaskService
;
@Autowired
private
CarReviewTaskService
carReviewTaskService
;
@Override
public
List
<
Task
>
findList
(
TaskListRequest
request
)
{
return
taskMapper
.
findList
(
request
);
}
@Override
public
void
createTask
(
TaskCreateRequest
request
)
{
// 构建任务创建者
LoginUser
loginUser
=
SecurityUtils
.
getLoginUser
();
SysUser
initiator
=
sysUserService
.
selectUserById
(
loginUser
.
getUserId
());
Standard
standard
=
standardService
.
findListById
(
request
.
getStandardId
());
// 找到审查组长
TaskUserRelation
leader
=
null
;
List
<
TaskUserRelation
>
auditors
=
request
.
getAuditors
();
for
(
TaskUserRelation
auditor
:
auditors
)
{
if
(
auditor
.
getIsLeader
()
==
1
)
{
leader
=
auditor
;
break
;
}
}
// 构建并保存任务信息
// 总任务
Task
task
=
new
Task
();
task
.
setTaskInitiator
(
initiator
.
getNickName
());
task
.
setTaskInitiatorDept
(
initiator
.
getDept
().
getDeptName
());
task
.
setTaskStatus
(
Task
.
STATUS_NEW
);
task
.
setLeaderId
(
leader
.
getUserId
());
task
.
setLeader
(
leader
.
getName
());
task
.
setCreateTime
(
new
Date
());
task
.
setName
(
standard
.
getName
());
task
.
setStandardNo
(
standard
.
getStandardNo
());
task
.
setFile
(
standard
.
getFile
());
BeanUtils
.
copyBeanProp
(
task
,
request
);
Long
systemReviewTaskId
=
null
;
Long
carReviewTaskId
=
null
;
if
(
request
.
getTaskList
().
contains
(
Task
.
SUB_TASK_SRAIF
))
{
// 保存体系审查任务
systemReviewTaskId
=
saveSystemReview
(
request
,
initiator
,
standard
,
leader
);
}
if
(
request
.
getTaskList
().
contains
(
Task
.
SUB_TASK_GRFIS
)
||
request
.
getTaskList
().
contains
(
Task
.
SUB_TASK_TRFIS
))
{
// 保存车型审查问卷任务
carReviewTaskId
=
saveCarReview
(
request
,
initiator
,
standard
,
leader
);
}
task
.
setCarReviewTaskId
(
carReviewTaskId
);
task
.
setSystemReviewTaskId
(
systemReviewTaskId
);
taskService
.
save
(
task
);
// 构建并保存该任务所关联的审核组信息
for
(
TaskUserRelation
auditor
:
auditors
)
{
auditor
.
setTaskId
(
task
.
getId
());
}
taskUserRelationService
.
saveBatch
(
auditors
);
}
public
Long
saveSystemReview
(
TaskCreateRequest
request
,
SysUser
initiator
,
Standard
standard
,
TaskUserRelation
leader
)
{
// 构建并保存任务信息
SystemReviewTask
task
=
new
SystemReviewTask
()
.
setTaskNo
(
request
.
getTaskNo
())
.
setTaskInitiator
(
initiator
.
getNickName
())
.
setTaskInitiatorDept
(
initiator
.
getDept
().
getDeptName
())
.
setTaskStatus
(
SystemReviewTask
.
STATUS_NEW
)
.
setLeaderId
(
leader
.
getUserId
())
.
setLeader
(
leader
.
getName
())
.
setCreateTime
(
new
Date
())
.
setStandardId
(
standard
.
getId
())
.
setName
(
standard
.
getName
())
.
setStandardNo
(
standard
.
getStandardNo
())
.
setFile
(
standard
.
getFile
());
systemReviewTaskService
.
save
(
task
);
return
task
.
getId
();
}
public
Long
saveCarReview
(
TaskCreateRequest
request
,
SysUser
initiator
,
Standard
standard
,
TaskUserRelation
leader
)
{
List
<
String
>
taskList
=
request
.
getTaskList
();
// 构建并保存任务信息
CarReviewTask
task
=
new
CarReviewTask
()
.
setTaskNo
(
request
.
getTaskNo
())
.
setTaskInitiator
(
initiator
.
getNickName
())
.
setTaskInitiatorDept
(
initiator
.
getDept
().
getDeptName
())
.
setTaskStatus
(
CarReviewTask
.
TASK_STATUS_NEW
)
.
setLeaderId
(
leader
.
getUserId
())
.
setLeader
(
leader
.
getName
())
.
setCreateTime
(
new
Date
())
.
setTaskBeginTime
(
new
Date
())
.
setStandardId
(
standard
.
getId
())
.
setName
(
standard
.
getName
())
.
setStandardNo
(
standard
.
getStandardNo
())
.
setFile
(
standard
.
getFile
())
.
setReviewStatus
(
taskList
.
contains
(
Task
.
SUB_TASK_GRFIS
)
?
CarReviewTask
.
REVIEW_STATUS_NEW
:
CarReviewTask
.
REVIEW_STATUS_NONE
)
.
setTestStatus
(
taskList
.
contains
(
Task
.
SUB_TASK_TRFIS
)
?
CarReviewTask
.
TEST_STATUS_NEW
:
CarReviewTask
.
TEST_STATUS_NONE
);
carReviewTaskService
.
save
(
task
);
return
task
.
getId
();
}
}
quality-review/src/main/java/com/ruoyi/service/impl/
Review
TaskUserRelationServiceImpl.java
→
quality-review/src/main/java/com/ruoyi/service/impl/TaskUserRelationServiceImpl.java
View file @
082c9882
package
com
.
ruoyi
.
service
.
impl
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
com.ruoyi.domain.ReviewTaskUserRelation
;
import
com.ruoyi.service.ReviewTaskUserRelationService
;
import
com.ruoyi.mapper.ReviewTaskUserRelationMapper
;
import
org.apache.ibatis.annotations.Param
;
import
com.ruoyi.domain.TaskUserRelation
;
import
com.ruoyi.service.TaskUserRelationService
;
import
com.ruoyi.mapper.TaskUserRelationMapper
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
...
...
@@ -16,11 +15,11 @@ import java.util.List;
* @createDate 2023-12-15 10:41:16
*/
@Service
public
class
ReviewTaskUserRelationServiceImpl
extends
ServiceImpl
<
ReviewTaskUserRelationMapper
,
Review
TaskUserRelation
>
implements
Review
TaskUserRelationService
{
public
class
TaskUserRelationServiceImpl
extends
ServiceImpl
<
TaskUserRelationMapper
,
TaskUserRelation
>
implements
TaskUserRelationService
{
@Autowired
Review
TaskUserRelationMapper
reviewTaskUserRelationMapper
;
TaskUserRelationMapper
reviewTaskUserRelationMapper
;
/**
* 根据任务id查询小组成员
...
...
@@ -28,7 +27,7 @@ public class ReviewTaskUserRelationServiceImpl extends ServiceImpl<ReviewTaskUse
* @return
*/
@Override
public
List
<
Review
TaskUserRelation
>
selectQTeamMembers
(
Long
taskId
){
public
List
<
TaskUserRelation
>
selectQTeamMembers
(
Long
taskId
){
return
reviewTaskUserRelationMapper
.
selectQTeamMembers
(
taskId
);
}
...
...
quality-review/src/main/java/com/ruoyi/web/CarReviewTaskController.java
View file @
082c9882
...
...
@@ -58,6 +58,15 @@ public class CarReviewTaskController extends BaseController {
return
R
.
ok
();
}
@ApiOperation
(
"确认车辆问卷审查任务"
)
@Trace
@Tags
({
@Tag
(
key
=
"param"
,
value
=
"arg[0]"
),
@Tag
(
key
=
"result"
,
value
=
"returnedObj"
)})
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/confirmReview"
)
public
R
<
String
>
confirmReview
(
@Validated
@RequestBody
CarReviewTaskConfirmRequest
request
)
{
carReviewTaskService
.
confirmReviewTask
(
request
);
return
R
.
ok
();
}
@ApiOperation
(
"提交车辆问卷审查任务"
)
@Trace
@Tags
({
@Tag
(
key
=
"param"
,
value
=
"arg[0]"
),
@Tag
(
key
=
"result"
,
value
=
"returnedObj"
)})
...
...
quality-review/src/main/java/com/ruoyi/web/ReviewSceneChangeTaskController.java
View file @
082c9882
...
...
@@ -17,12 +17,10 @@ import io.swagger.annotations.ApiOperation;
import
org.apache.skywalking.apm.toolkit.trace.Tag
;
import
org.apache.skywalking.apm.toolkit.trace.Tags
;
import
org.apache.skywalking.apm.toolkit.trace.Trace
;
import
org.apache.xmlbeans.impl.xb.xsdschema.Public
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.validation.annotation.Validated
;
import
org.springframework.web.bind.annotation.RequestBody
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.RequestMethod
;
import
org.springframework.web.bind.annotation.RestController
;
import
org.springframework.web.bind.annotation.*
;
@Api
(
tags
=
"场景变更任务"
)
@RestController
...
...
@@ -46,27 +44,14 @@ public class ReviewSceneChangeTaskController extends BaseController {
return
R
.
ok
();
}
@ApiOperation
(
"审核
通过
任务"
)
@ApiOperation
(
"审核任务"
)
@Trace
@Tags
({
@Tag
(
key
=
"param"
,
value
=
"arg[0]"
),
@Tag
(
key
=
"result"
,
value
=
"returnedObj"
)})
@Log
(
title
=
"审核通过任务"
,
businessType
=
BusinessType
.
UPDATE
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/pass"
)
public
R
<
String
>
pass
(
@Validated
@RequestBody
ReviewSceneChangeTaskPassRequest
request
)
{
reviewSceneChangeTaskService
.
pass
(
request
.
getTaskId
(),
request
.
getComment
());
return
R
.
ok
();
}
@ApiOperation
(
"审核驳回任务"
)
@Trace
@Tags
({
@Tag
(
key
=
"param"
,
value
=
"arg[0]"
),
@Tag
(
key
=
"result"
,
value
=
"returnedObj"
)})
@Log
(
title
=
"审核驳回任务"
,
businessType
=
BusinessType
.
UPDATE
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/reject"
)
public
R
<
String
>
reject
(
@Validated
@RequestBody
ReviewSceneChangeTaskPassRequest
request
)
{
reviewSceneChangeTaskService
.
reject
(
request
.
getTaskId
(),
request
.
getComment
());
@Log
(
title
=
"审核任务"
,
businessType
=
BusinessType
.
UPDATE
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/audit"
)
public
R
<
String
>
audit
(
@Validated
@RequestBody
ReviewSceneChangeTaskPassRequest
request
)
{
reviewSceneChangeTaskService
.
audit
(
request
);
return
R
.
ok
();
}
...
...
@@ -91,7 +76,7 @@ public class ReviewSceneChangeTaskController extends BaseController {
@Trace
@Tags
({
@Tag
(
key
=
"param"
,
value
=
"arg[0]"
),
@Tag
(
key
=
"result"
,
value
=
"returnedObj"
)})
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/findFinish"
)
public
TableDataInfo
<
ReviewSceneChangeTaskResponse
>
findFinish
(
ReviewSceneChangeTaskFindFinishRequest
request
)
{
public
TableDataInfo
<
ReviewSceneChangeTaskResponse
>
findFinish
(
@Validated
@RequestBody
ReviewSceneChangeTaskFindFinishRequest
request
)
{
startPage
(
request
);
return
getDataTable
(
reviewSceneChangeTaskService
.
findFinishListByUserId
(
getUserId
()));
}
...
...
@@ -104,9 +89,17 @@ public class ReviewSceneChangeTaskController extends BaseController {
@Trace
@Tags
({
@Tag
(
key
=
"param"
,
value
=
"arg[0]"
),
@Tag
(
key
=
"result"
,
value
=
"returnedObj"
)})
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/findCreate"
)
public
TableDataInfo
<
ReviewSceneChangeTask
>
findCreate
(
ReviewSceneChangeTaskFindCreateRequest
request
)
{
public
TableDataInfo
<
ReviewSceneChangeTask
>
findCreate
(
@Validated
@RequestBody
ReviewSceneChangeTaskFindCreateRequest
request
)
{
startPage
(
request
);
return
getDataTable
(
reviewSceneChangeTaskService
.
findCreateListByUserId
(
getUserId
()));
}
@ApiOperation
(
"查询任务详情"
)
@Trace
@Tags
({
@Tag
(
key
=
"param"
,
value
=
"arg[0]"
),
@Tag
(
key
=
"result"
,
value
=
"returnedObj"
)})
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/getById"
)
public
R
<
ReviewSceneChangeTask
>
getInfo
(
@Validated
@RequestBody
ReviewSceneChangeTaskGetInfoRequest
request
)
{
return
R
.
ok
(
reviewSceneChangeTaskService
.
getById
(
request
.
getId
()));
}
}
quality-review/src/main/java/com/ruoyi/web/ReviewTaskUserRelationController.java
View file @
082c9882
...
...
@@ -3,9 +3,9 @@ package com.ruoyi.web;
import
com.ruoyi.common.core.controller.BaseController
;
import
com.ruoyi.common.core.domain.R
;
import
com.ruoyi.domain.
Review
TaskUserRelation
;
import
com.ruoyi.service.
Review
TaskUserRelationService
;
import
com.ruoyi.web.request.
Review
TaskUserRelationMembersRequest
;
import
com.ruoyi.domain.TaskUserRelation
;
import
com.ruoyi.service.TaskUserRelationService
;
import
com.ruoyi.web.request.TaskUserRelationMembersRequest
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiOperation
;
import
org.apache.skywalking.apm.toolkit.trace.Tag
;
...
...
@@ -24,7 +24,7 @@ import java.util.List;
public
class
ReviewTaskUserRelationController
extends
BaseController
{
@Autowired
Review
TaskUserRelationService
reviewTaskUserRelationService
;
TaskUserRelationService
reviewTaskUserRelationService
;
/**
...
...
@@ -35,8 +35,8 @@ public class ReviewTaskUserRelationController extends BaseController {
@Trace
@Tags
({
@Tag
(
key
=
"param"
,
value
=
"arg[0]"
),
@Tag
(
key
=
"result"
,
value
=
"returnedObj"
)})
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/members"
)
public
R
<
List
<
ReviewTaskUserRelation
>>
selectQTeamMemberList
(
@Validated
@RequestBody
Review
TaskUserRelationMembersRequest
request
){
List
<
Review
TaskUserRelation
>
list
=
reviewTaskUserRelationService
.
selectQTeamMembers
(
request
.
getTaskId
());
public
R
<
List
<
TaskUserRelation
>>
selectQTeamMemberList
(
@Validated
@RequestBody
TaskUserRelationMembersRequest
request
){
List
<
TaskUserRelation
>
list
=
reviewTaskUserRelationService
.
selectQTeamMembers
(
request
.
getTaskId
());
return
R
.
ok
(
list
);
}
...
...
quality-review/src/main/java/com/ruoyi/web/SystemReviewTaskController.java
View file @
082c9882
...
...
@@ -61,6 +61,15 @@ public class SystemReviewTaskController extends BaseController {
return
R
.
ok
();
}
@ApiOperation
(
"确认体系审查问卷"
)
@Trace
@Tags
({
@Tag
(
key
=
"param"
,
value
=
"arg[0]"
),
@Tag
(
key
=
"result"
,
value
=
"returnedObj"
)})
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/confirm"
)
public
R
<
String
>
confirm
(
@Validated
@RequestBody
SystemReviewTaskConfirmRequest
request
)
{
systemReviewTaskService
.
confirm
(
request
);
return
R
.
ok
();
}
@ApiOperation
(
"提交体系审查任务"
)
@Trace
@Tags
({
@Tag
(
key
=
"param"
,
value
=
"arg[0]"
),
@Tag
(
key
=
"result"
,
value
=
"returnedObj"
)})
...
...
quality-review/src/main/java/com/ruoyi/web/TaskController.java
0 → 100644
View file @
082c9882
package
com
.
ruoyi
.
web
;
import
com.ruoyi.common.annotation.Log
;
import
com.ruoyi.common.core.controller.BaseController
;
import
com.ruoyi.common.core.domain.R
;
import
com.ruoyi.common.core.page.TableDataInfo
;
import
com.ruoyi.common.enums.BusinessType
;
import
com.ruoyi.domain.Task
;
import
com.ruoyi.service.TaskService
;
import
com.ruoyi.web.request.TaskCreateRequest
;
import
com.ruoyi.web.request.TaskListRequest
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiOperation
;
import
org.apache.skywalking.apm.toolkit.trace.Tag
;
import
org.apache.skywalking.apm.toolkit.trace.Tags
;
import
org.apache.skywalking.apm.toolkit.trace.Trace
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.validation.annotation.Validated
;
import
org.springframework.web.bind.annotation.RequestBody
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.RequestMethod
;
import
org.springframework.web.bind.annotation.RestController
;
@Api
(
tags
=
"总任务"
)
@RestController
@RequestMapping
(
"/task"
)
public
class
TaskController
extends
BaseController
{
@Autowired
private
TaskService
taskService
;
@ApiOperation
(
"查询任务列表"
)
@Trace
@Tags
({
@Tag
(
key
=
"param"
,
value
=
"arg[0]"
),
@Tag
(
key
=
"result"
,
value
=
"returnedObj"
)})
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/findList"
)
public
TableDataInfo
<
Task
>
findList
(
@Validated
@RequestBody
TaskListRequest
request
)
{
startPage
(
request
);
return
getDataTable
(
taskService
.
findList
(
request
));
}
@ApiOperation
(
"创建任务"
)
@Trace
@Tags
({
@Tag
(
key
=
"param"
,
value
=
"arg[0]"
),
@Tag
(
key
=
"result"
,
value
=
"returnedObj"
)})
@Log
(
title
=
"总任务"
,
businessType
=
BusinessType
.
INSERT
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/createTask"
)
public
R
<
String
>
createTask
(
@Validated
@RequestBody
TaskCreateRequest
request
)
{
taskService
.
createTask
(
request
);
return
R
.
ok
();
}
}
quality-review/src/main/java/com/ruoyi/web/request/CarReviewTaskConfirmRequest.java
0 → 100644
View file @
082c9882
package
com
.
ruoyi
.
web
.
request
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
@ApiModel
(
value
=
"CarReviewTaskConfirmRequest"
,
description
=
"确认车辆问卷审查任务"
)
@Data
public
class
CarReviewTaskConfirmRequest
{
@ApiModelProperty
(
"任务id"
)
private
Long
taskId
;
}
quality-review/src/main/java/com/ruoyi/web/request/CarReviewTaskCreateRequest.java
View file @
082c9882
package
com
.
ruoyi
.
web
.
request
;
import
com.ruoyi.domain.
Review
TaskUserRelation
;
import
com.ruoyi.domain.TaskUserRelation
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
...
...
@@ -11,11 +11,8 @@ import java.util.List;
@Data
public
class
CarReviewTaskCreateRequest
{
@ApiModelProperty
(
"占位"
)
private
String
bizInfo
;
@ApiModelProperty
(
"小组信息"
)
private
List
<
Review
TaskUserRelation
>
auditors
;
private
List
<
TaskUserRelation
>
auditors
;
/**
* 是否创建车型问卷审查任务
...
...
quality-review/src/main/java/com/ruoyi/web/request/ReviewSceneChangeTaskGetInfoRequest.java
0 → 100644
View file @
082c9882
package
com
.
ruoyi
.
web
.
request
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
@Data
@ApiModel
public
class
ReviewSceneChangeTaskGetInfoRequest
{
@ApiModelProperty
(
"ID"
)
private
Long
id
;
}
quality-review/src/main/java/com/ruoyi/web/request/ReviewSceneChangeTaskPassRequest.java
View file @
082c9882
...
...
@@ -13,4 +13,7 @@ public class ReviewSceneChangeTaskPassRequest {
@ApiModelProperty
(
"评论"
)
private
String
comment
;
@ApiModelProperty
(
"是否通过(0:不通过 1:通过)"
)
private
String
passed
;
}
quality-review/src/main/java/com/ruoyi/web/request/SystemReviewTaskConfirmRequest.java
0 → 100644
View file @
082c9882
package
com
.
ruoyi
.
web
.
request
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
@ApiModel
(
value
=
"SystemReviewTaskConfirmRequest"
,
description
=
"确认体系审查问卷"
)
@Data
public
class
SystemReviewTaskConfirmRequest
{
@ApiModelProperty
(
"任务id"
)
private
Long
taskId
;
}
quality-review/src/main/java/com/ruoyi/web/request/SystemReviewTaskCreateRequest.java
View file @
082c9882
package
com
.
ruoyi
.
web
.
request
;
import
com.ruoyi.domain.
Review
TaskUserRelation
;
import
com.ruoyi.domain.TaskUserRelation
;
import
lombok.Data
;
import
java.util.List
;
...
...
@@ -8,9 +8,7 @@ import java.util.List;
@Data
public
class
SystemReviewTaskCreateRequest
{
private
String
bizInfo
;
private
List
<
ReviewTaskUserRelation
>
auditors
;
private
List
<
TaskUserRelation
>
auditors
;
/**
* 标准id
...
...
quality-review/src/main/java/com/ruoyi/web/request/TaskCreateRequest.java
0 → 100644
View file @
082c9882
package
com
.
ruoyi
.
web
.
request
;
import
com.ruoyi.common.core.domain.entity.SysDictData
;
import
com.ruoyi.domain.TaskUserRelation
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
java.util.Date
;
import
java.util.List
;
@ApiModel
(
value
=
"TaskCreateRequest"
,
description
=
"创建总任务"
)
@Data
public
class
TaskCreateRequest
{
@ApiModelProperty
(
"小组成员"
)
private
List
<
TaskUserRelation
>
auditors
;
@ApiModelProperty
(
"任务编号"
)
private
String
taskNo
;
@ApiModelProperty
(
"任务名称"
)
private
String
taskName
;
@ApiModelProperty
(
"产品名称"
)
private
String
productName
;
@ApiModelProperty
(
"产品型号"
)
private
String
productModel
;
@ApiModelProperty
(
"委托单位"
)
private
String
entrustedUnit
;
@ApiModelProperty
(
"委托单位地址"
)
private
String
entrustedUnitAddress
;
@ApiModelProperty
(
"委托单位电话"
)
private
String
entrustedUnitPhone
;
@ApiModelProperty
(
"委托单位邮政编码"
)
private
String
entrustedUnitCode
;
@ApiModelProperty
(
"车辆类型"
)
private
String
carType
;
@ApiModelProperty
(
"车辆识别码"
)
private
String
carIdentificationCode
;
@ApiModelProperty
(
"保密等级"
)
private
String
confidentialityLevel
;
@ApiModelProperty
(
"样品名称"
)
private
String
sampleName
;
@ApiModelProperty
(
"生产企业"
)
private
String
productionEnterprise
;
@ApiModelProperty
(
"送样者"
)
private
String
sampleSender
;
@ApiModelProperty
(
"送样日期"
)
private
Date
sendDate
;
@ApiModelProperty
(
"样品数量"
)
private
String
sampleNumber
;
@ApiModelProperty
(
"生产日期"
)
private
Date
productionDate
;
@ApiModelProperty
(
"商标"
)
private
String
trademark
;
@ApiModelProperty
(
"检验依据"
)
private
String
inspectionBasis
;
@ApiModelProperty
(
"选择的任务"
)
List
<
String
>
taskList
;
/**
* 标准id
* 根据哪个标准新建的审查任务
*/
@ApiModelProperty
(
"标准id(根据哪个标准新建的任务)"
)
private
Long
standardId
;
}
quality-review/src/main/java/com/ruoyi/web/request/TaskListRequest.java
0 → 100644
View file @
082c9882
package
com
.
ruoyi
.
web
.
request
;
import
com.ruoyi.common.core.page.PageDomain
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
java.util.Date
;
@ApiModel
(
value
=
"TaskListRequest"
,
description
=
"查询总任务"
)
@Data
public
class
TaskListRequest
extends
PageDomain
{
@ApiModelProperty
(
"任务开始时间"
)
private
Date
taskBeginTime
;
@ApiModelProperty
(
"任务状态"
)
private
String
taskStatus
;
}
quality-review/src/main/java/com/ruoyi/web/request/
Review
TaskUserRelationMembersRequest.java
→
quality-review/src/main/java/com/ruoyi/web/request/TaskUserRelationMembersRequest.java
View file @
082c9882
...
...
@@ -5,7 +5,7 @@ import io.swagger.annotations.ApiModelProperty;
import
lombok.Data
;
@Data
public
class
Review
TaskUserRelationMembersRequest
{
public
class
TaskUserRelationMembersRequest
{
@ApiModelProperty
(
"任务id"
)
private
Long
taskId
;
}
quality-review/src/main/resources/mapper/CarReviewTaskMapper.xml
View file @
082c9882
...
...
@@ -14,7 +14,6 @@
<result
property=
"taskBeginTime"
column=
"task_begin_time"
jdbcType=
"TIMESTAMP"
/>
<result
property=
"taskEndTime"
column=
"task_end_time"
jdbcType=
"TIMESTAMP"
/>
<result
property=
"standard"
column=
"standard"
typeHandler=
"com.ruoyi.common.StandardJsonTypeHandler"
/>
<result
property=
"bizInfo"
column=
"biz_info"
jdbcType=
"VARCHAR"
/>
<result
property=
"createTime"
column=
"create_time"
jdbcType=
"TIMESTAMP"
/>
<result
property=
"leaderId"
column=
"leader_id"
jdbcType=
"BIGINT"
/>
<result
property=
"leader"
column=
"leader"
jdbcType=
"VARCHAR"
/>
...
...
@@ -29,27 +28,28 @@
<result
property=
"reviewSubmitId"
column=
"review_submit_id"
jdbcType=
"BIGINT"
/>
<result
property=
"reviewSubmitName"
column=
"review_submit_name"
jdbcType=
"VARCHAR"
/>
<result
property=
"reviewResult"
column=
"review_result"
jdbcType=
"VARCHAR"
/>
<result
property=
"reviewImagesUrl"
column=
"review_images_url"
jdbcType=
"VARCHAR"
/>
</resultMap>
<sql
id=
"Base_Column_List"
>
id,task_no,task_status,
task_initiator,task_initiator_dept,task_result,
task_begin_time,task_end_time,standard,
biz_info,
create_time,leader_id,
create_time,leader_id,
leader,standard_id,name,
standard_no,file,review_status,
test_status,review_start_time,
review_submit_time,
review_submit_id,
review_submit_name,
review_result
review_result
,review_images_url
</sql>
<select
id=
"findListByReviewStatus"
resultType=
"com.ruoyi.domain.CarReviewTask"
>
SELECT id,task_no,task_status,task_initiator,task_initiator_dept,task_result,task_begin_time,task_end_time,standard,
biz_info,create_time,leader_id,leader,standard_id,name,standard_no,file,review_status,test_status,review_start_time,review_submit_time,review_submit_id,review_submit_name,review_result
SELECT id,task_no,task_status,task_initiator,task_initiator_dept,task_result,task_begin_time,task_end_time,standard,
create_time,leader_id,leader,standard_id,name,standard_no,file,review_status,test_status,review_start_time,review_submit_time,review_submit_id,review_submit_name,review_result,review_images_url
FROM t_car_review_task WHERE review_status = #{reviewStatus} AND task_status = 'PENDING'
</select>
<select
id=
"findListByTaskStatus"
resultType=
"com.ruoyi.domain.CarReviewTask"
>
SELECT id,task_no,task_status,task_initiator,task_initiator_dept,task_result,task_begin_time,task_end_time,standard,
biz_info,create_time,leader_id,leader,standard_id,name,standard_no,file,review_status,test_status,review_start_time,review_submit_time,review_submit_id,review_submit_name,review_result
SELECT id,task_no,task_status,task_initiator,task_initiator_dept,task_result,task_begin_time,task_end_time,standard,
create_time,leader_id,leader,standard_id,name,standard_no,file,review_status,test_status,review_start_time,review_submit_time,review_submit_id,review_submit_name,review_result,review_images_url
FROM t_car_review_task WHERE task_status = #{taskStatus}
</select>
</mapper>
quality-review/src/main/resources/mapper/ReviewStandardMapper.xml
View file @
082c9882
...
...
@@ -14,6 +14,8 @@
<result
property=
"name"
column=
"name"
jdbcType=
"VARCHAR"
/>
<result
property=
"standardNo"
column=
"standard_no"
jdbcType=
"VARCHAR"
/>
<result
property=
"file"
column=
"file"
jdbcType=
"VARCHAR"
/>
<result
property=
"conformity"
column=
"conformity"
jdbcType=
"VARCHAR"
/>
<result
property=
"inconformity"
column=
"inconformity"
jdbcType=
"VARCHAR"
/>
<collection
property=
"keyPointList"
ofType=
"com.ruoyi.domain.ReviewKeyPoint"
select=
"com.ruoyi.mapper.ReviewKeyPointMapper.findAllByReviewStandardId"
column=
"id"
>
<result
property=
"id"
column=
"u_id"
jdbcType=
"BIGINT"
/>
...
...
@@ -23,11 +25,11 @@
</resultMap>
<select
id=
"findTree"
resultMap=
"StandardTreeResultMap"
>
SELECT id, chapter, text, standard_id, name, standard_no, file FROM t_review_standard;
SELECT id, chapter, text, standard_id, name, standard_no, file
, conformity, inconformity
FROM t_review_standard;
</select>
<select
id=
"findListByStandardIdAndType"
resultType=
"com.ruoyi.domain.ReviewStandard"
>
SELECT id, type, chapter, text, standard_id, name, standard_no, file FROM t_review_standard WHERE standard_id = #{standardId} AND type = #{type};
SELECT id, type, chapter, text, standard_id, name, standard_no, file
, conformity, inconformity
FROM t_review_standard WHERE standard_id = #{standardId} AND type = #{type};
</select>
...
...
quality-review/src/main/resources/mapper/StandardMapper.xml
View file @
082c9882
...
...
@@ -9,12 +9,10 @@
<result
property=
"name"
column=
"name"
jdbcType=
"VARCHAR"
/>
<result
property=
"standardNo"
column=
"standard_no"
jdbcType=
"VARCHAR"
/>
<result
property=
"file"
column=
"file"
jdbcType=
"VARCHAR"
/>
<result
property=
"conformity"
column=
"conformity"
jdbcType=
"VARCHAR"
/>
<result
property=
"inconformity"
column=
"inconformity"
jdbcType=
"VARCHAR"
/>
</resultMap>
<select
id=
"findList"
parameterType=
"com.ruoyi.
domain.Standard
"
resultMap=
"BaseResultMap"
>
SELECT id, name, standard_no, file
, conformity, inconformity
<select
id=
"findList"
parameterType=
"com.ruoyi.
web.request.StandardListRequest
"
resultMap=
"BaseResultMap"
>
SELECT id, name, standard_no, file
FROM t_standard
<where>
<if
test=
"params.name != null and params.name != ''"
>
...
...
@@ -27,7 +25,7 @@
</select>
<select
id=
"findListById"
resultMap=
"BaseResultMap"
>
SELECT id, name, standard_no, file
, conformity, inconformity
SELECT id, name, standard_no, file
FROM t_standard WHERE id = #{id}
</select>
...
...
quality-review/src/main/resources/mapper/SystemReviewTaskMapper.xml
View file @
082c9882
...
...
@@ -14,24 +14,26 @@
<result
property=
"taskBeginTime"
column=
"task_begin_time"
jdbcType=
"TIMESTAMP"
/>
<result
property=
"taskEndTime"
column=
"task_end_time"
jdbcType=
"TIMESTAMP"
/>
<result
property=
"standard"
column=
"standard"
typeHandler=
"com.ruoyi.common.StandardJsonTypeHandler"
/>
<result
property=
"bizInfo"
column=
"biz_info"
jdbcType=
"VARCHAR"
/>
<result
property=
"createTime"
column=
"create_time"
jdbcType=
"TIMESTAMP"
/>
<result
property=
"leaderId"
column=
"leader_id"
jdbcType=
"BIGINT"
/>
<result
property=
"leader"
column=
"leader"
jdbcType=
"VARCHAR"
/>
<result
property=
"standardId"
column=
"standard_id"
jdbcType=
"BIGINT"
/>
<result
property=
"name"
column=
"name"
jdbcType=
"VARCHAR"
/>
<result
property=
"standardNo"
column=
"standard_no"
jdbcType=
"VARCHAR"
/>
<result
property=
"file"
column=
"file"
jdbcType=
"VARCHAR"
/>
<result
property=
"submitById"
column=
"submit_by_id"
jdbcType=
"BIGINT"
/>
<result
property=
"submitByName"
column=
"submit_by_name"
jdbcType=
"VARCHAR"
/>
<result
property=
"imagesUrl"
column=
"images_url"
jdbcType=
"VARCHAR"
/>
</resultMap>
<select
id=
"findListByStatus"
resultMap=
"BaseResultMap"
>
SELECT id, task_no, task_status, task_initiator, task_initiator_dept, task_result, task_begin_time, task_end_time, standard,
biz_info, create_time, standard_id, name, standard_no, file, submit_by_id, submit_by_name
SELECT id, task_no, task_status, task_initiator, task_initiator_dept, task_result, task_begin_time, task_end_time, standard,
create_time,leader,leader_id, standard_id, name, standard_no, file, submit_by_id, submit_by_name,images_url
FROM t_system_review_task WHERE task_status = #{status}
ORDER BY create_time DESC
</select>
<select
id=
"findListInProcess"
resultMap=
"BaseResultMap"
>
SELECT id, task_no, task_status, task_initiator, task_initiator_dept, task_result, task_begin_time, task_end_time, standard,
biz_info, create_time, standard_id, name, standard_no, file, submit_by_id, submit_by_name
SELECT id, task_no, task_status, task_initiator, task_initiator_dept, task_result, task_begin_time, task_end_time, standard,
create_time,leader,leader_id, standard_id, name, standard_no, file, submit_by_id, submit_by_name,images_url
FROM t_system_review_task WHERE task_status IN ('NEW','PENDING')
ORDER BY create_time DESC
</select>
...
...
quality-review/src/main/resources/mapper/TaskMapper.xml
0 → 100644
View file @
082c9882
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper
namespace=
"com.ruoyi.mapper.TaskMapper"
>
<resultMap
id=
"BaseResultMap"
type=
"com.ruoyi.domain.Task"
>
<id
property=
"id"
column=
"id"
jdbcType=
"BIGINT"
/>
<id
property=
"systemReviewTaskId"
column=
"system_review_task_id"
jdbcType=
"BIGINT"
/>
<id
property=
"carReviewTaskId"
column=
"car_review_task_id"
jdbcType=
"BIGINT"
/>
<result
property=
"taskNo"
column=
"task_no"
jdbcType=
"VARCHAR"
/>
<result
property=
"taskName"
column=
"task_name"
jdbcType=
"VARCHAR"
/>
<result
property=
"taskStatus"
column=
"task_status"
jdbcType=
"VARCHAR"
/>
<result
property=
"productName"
column=
"product_name"
jdbcType=
"VARCHAR"
/>
<result
property=
"productModel"
column=
"product_model"
jdbcType=
"VARCHAR"
/>
<result
property=
"entrustedUnit"
column=
"entrusted_unit"
jdbcType=
"VARCHAR"
/>
<result
property=
"entrustedUnitAddress"
column=
"entrusted_unit_address"
jdbcType=
"VARCHAR"
/>
<result
property=
"entrustedUnitPhone"
column=
"entrusted_unit_phone"
jdbcType=
"VARCHAR"
/>
<result
property=
"entrustedUnitCode"
column=
"entrusted_unit_code"
jdbcType=
"VARCHAR"
/>
<result
property=
"carType"
column=
"car_type"
jdbcType=
"VARCHAR"
/>
<result
property=
"carIdentificationCode"
column=
"car_identification_code"
jdbcType=
"VARCHAR"
/>
<result
property=
"confidentialityLevel"
column=
"confidentiality_level"
jdbcType=
"VARCHAR"
/>
<result
property=
"sampleName"
column=
"sample_name"
jdbcType=
"VARCHAR"
/>
<result
property=
"productionEnterprise"
column=
"production_enterprise"
jdbcType=
"VARCHAR"
/>
<result
property=
"sampleSender"
column=
"sample_sender"
jdbcType=
"VARCHAR"
/>
<result
property=
"sendDate"
column=
"send_date"
jdbcType=
"TIMESTAMP"
/>
<result
property=
"sampleNumber"
column=
"sample_number"
jdbcType=
"VARCHAR"
/>
<result
property=
"productionDate"
column=
"production_date"
jdbcType=
"TIMESTAMP"
/>
<result
property=
"trademark"
column=
"trademark"
jdbcType=
"VARCHAR"
/>
<result
property=
"inspectionBasis"
column=
"inspection_basis"
jdbcType=
"VARCHAR"
/>
<result
property=
"taskInitiator"
column=
"task_initiator"
jdbcType=
"VARCHAR"
/>
<result
property=
"taskInitiatorDept"
column=
"task_initiator_dept"
jdbcType=
"VARCHAR"
/>
<result
property=
"taskBeginTime"
column=
"task_begin_time"
jdbcType=
"TIMESTAMP"
/>
<result
property=
"taskEndTime"
column=
"task_end_time"
jdbcType=
"TIMESTAMP"
/>
<result
property=
"leaderId"
column=
"leader_id"
jdbcType=
"BIGINT"
/>
<result
property=
"leader"
column=
"leader"
jdbcType=
"VARCHAR"
/>
<result
property=
"createTime"
column=
"create_time"
jdbcType=
"TIMESTAMP"
/>
<result
property=
"standardId"
column=
"standard_id"
jdbcType=
"BIGINT"
/>
<result
property=
"name"
column=
"name"
jdbcType=
"VARCHAR"
/>
<result
property=
"standardNo"
column=
"standard_no"
jdbcType=
"VARCHAR"
/>
<result
property=
"file"
column=
"file"
jdbcType=
"VARCHAR"
/>
</resultMap>
<select
id=
"findList"
parameterType=
"com.ruoyi.web.request.TaskListRequest"
resultMap=
"BaseResultMap"
>
SELECT id, system_review_task_id, car_review_task_id,
task_no,task_name,task_status,product_name,product_model,
entrusted_unit,entrusted_unit_address,entrusted_unit_phone,
entrusted_unit_code,car_type,car_identification_code,
confidentiality_level,sample_name,production_enterprise,
sample_sender,send_date,sample_number,production_date,
trademark,inspection_basis,task_initiator,task_initiator_dept,
task_begin_time,task_end_time,create_time,
leader_id,leader,standard_id,name,
standard_no,file
FROM t_task
<where>
<if
test=
"taskBeginTime != null and taskBeginTime != ''"
>
task_begin_time = #{taskBeginTime}
</if>
<if
test=
"taskStatus != null and taskStatus != ''"
>
task_status = #{taskStatus}
</if>
</where>
order by create_time desc
</select>
</mapper>
quality-review/src/main/resources/mapper/
Review
TaskUserRelationMapper.xml
→
quality-review/src/main/resources/mapper/TaskUserRelationMapper.xml
View file @
082c9882
...
...
@@ -2,17 +2,17 @@
<!DOCTYPE mapper
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper
namespace=
"com.ruoyi.mapper.
Review
TaskUserRelationMapper"
>
<mapper
namespace=
"com.ruoyi.mapper.TaskUserRelationMapper"
>
<resultMap
id=
"BaseResultMap"
type=
"com.ruoyi.domain.
Review
TaskUserRelation"
>
<result
property=
"taskId"
column=
"task_id"
jdbcType=
"BIGINT"
/>
<result
property=
"userId"
column=
"user_id"
jdbcType=
"BIGINT"
/>
<result
property=
"isLeader"
column=
"is_leader"
jdbcType=
"TINYINT"
/>
<result
property=
"name"
column=
"name"
jdbcType=
"VARCHAR"
/>
<resultMap
id=
"BaseResultMap"
type=
"com.ruoyi.domain.TaskUserRelation"
>
<result
property=
"taskId"
column=
"task_id"
jdbcType=
"BIGINT"
/>
<result
property=
"userId"
column=
"user_id"
jdbcType=
"BIGINT"
/>
<result
property=
"isLeader"
column=
"is_leader"
jdbcType=
"TINYINT"
/>
<result
property=
"name"
column=
"name"
jdbcType=
"VARCHAR"
/>
</resultMap>
<sql
id=
"Base_Column_List"
>
select task_id,user_id,is_leader,name from t_task_user_relation
select task_id,user_id,is_leader,name from t_task_user_relation
</sql>
<select
id=
"selectQTeamMembers"
parameterType=
"Long"
resultMap=
"BaseResultMap"
>
...
...
@@ -22,4 +22,4 @@
task_id = #{taskId}
</if>
</select>
</mapper>
</mapper>
\ No newline at end of file
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