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
553ab27f
Commit
553ab27f
authored
Aug 29, 2024
by
wdy
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'dev' into 'master'
dev - master 46 See merge request
!430
parents
b0d468f2
bd0b6c4f
Changes
35
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
35 changed files
with
693 additions
and
68 deletions
+693
-68
ReviewSceneChangeTask.java
...src/main/java/com/ruoyi/domain/ReviewSceneChangeTask.java
+13
-0
ReviewSceneChangeTaskUserRelation.java
...a/com/ruoyi/domain/ReviewSceneChangeTaskUserRelation.java
+3
-0
ReviewKeyPointMapper.java
.../src/main/java/com/ruoyi/mapper/ReviewKeyPointMapper.java
+6
-0
ReviewSceneChangeTaskMapper.java
...in/java/com/ruoyi/mapper/ReviewSceneChangeTaskMapper.java
+19
-0
ReviewSceneChangeTaskService.java
.../java/com/ruoyi/service/ReviewSceneChangeTaskService.java
+38
-0
ReviewStandardService.java
...rc/main/java/com/ruoyi/service/ReviewStandardService.java
+0
-1
CarReviewTaskServiceImpl.java
...java/com/ruoyi/service/impl/CarReviewTaskServiceImpl.java
+0
-4
MatrixServiceImpl.java
...c/main/java/com/ruoyi/service/impl/MatrixServiceImpl.java
+6
-2
PdfTemplateManagementServiceImpl.java
.../ruoyi/service/impl/PdfTemplateManagementServiceImpl.java
+0
-1
ReviewSceneChangeTaskServiceImpl.java
.../ruoyi/service/impl/ReviewSceneChangeTaskServiceImpl.java
+264
-8
ReviewStandardServiceImpl.java
...ava/com/ruoyi/service/impl/ReviewStandardServiceImpl.java
+9
-3
StrategyReviewSceneChangeAdd.java
.../com/ruoyi/service/impl/StrategyReviewSceneChangeAdd.java
+13
-0
SystemReviewTaskServiceImpl.java
...a/com/ruoyi/service/impl/SystemReviewTaskServiceImpl.java
+1
-1
TaskServiceImpl.java
...src/main/java/com/ruoyi/service/impl/TaskServiceImpl.java
+1
-2
TestUseCaseServiceImpl.java
...n/java/com/ruoyi/service/impl/TestUseCaseServiceImpl.java
+9
-3
ReviewSceneChangeTaskController.java
...n/java/com/ruoyi/web/ReviewSceneChangeTaskController.java
+95
-7
ReviewStandardController.java
...src/main/java/com/ruoyi/web/ReviewStandardController.java
+0
-1
SystemReviewTaskController.java
...c/main/java/com/ruoyi/web/SystemReviewTaskController.java
+0
-1
TaskController.java
...ty-review/src/main/java/com/ruoyi/web/TaskController.java
+0
-3
ReviewDetailsListRequest.java
.../java/com/ruoyi/web/request/ReviewDetailsListRequest.java
+13
-0
ReviewKeyPointListRequest.java
...java/com/ruoyi/web/request/ReviewKeyPointListRequest.java
+13
-0
ReviewSceneChangeTaskCreateRequest.java
...ruoyi/web/request/ReviewSceneChangeTaskCreateRequest.java
+11
-5
ReviewSceneChangeTaskGetInfoRequest.java
...uoyi/web/request/ReviewSceneChangeTaskGetInfoRequest.java
+5
-1
ReviewStandardListByPageRequest.java
...om/ruoyi/web/request/ReviewStandardListByPageRequest.java
+7
-0
ReviewDetailsListResponse.java
...ava/com/ruoyi/web/response/ReviewDetailsListResponse.java
+19
-0
ReviewKeyPointListResponse.java
...va/com/ruoyi/web/response/ReviewKeyPointListResponse.java
+19
-0
ReviewSceneChangeTaskResponse.java
...com/ruoyi/web/response/ReviewSceneChangeTaskResponse.java
+10
-2
ReviewStandardResponse.java
...n/java/com/ruoyi/web/response/ReviewStandardResponse.java
+6
-0
ReviewerListResponse.java
...ain/java/com/ruoyi/web/response/ReviewerListResponse.java
+13
-0
ReviewKeyPointMapper.xml
...review/src/main/resources/mapper/ReviewKeyPointMapper.xml
+8
-0
ReviewSceneChangeTaskMapper.xml
...src/main/resources/mapper/ReviewSceneChangeTaskMapper.xml
+52
-3
ReviewSceneChangeTaskUserRelationMapper.xml
...ources/mapper/ReviewSceneChangeTaskUserRelationMapper.xml
+6
-2
ReviewStandardMapper.xml
...review/src/main/resources/mapper/ReviewStandardMapper.xml
+6
-1
SysUserRoleMapper.java
.../main/java/com/ruoyi/system/mapper/SysUserRoleMapper.java
+14
-7
SysUserRoleMapper.xml
...em/src/main/resources/mapper/system/SysUserRoleMapper.xml
+14
-10
No files found.
quality-review/src/main/java/com/ruoyi/domain/ReviewSceneChangeTask.java
View file @
553ab27f
...
...
@@ -60,6 +60,12 @@ public class ReviewSceneChangeTask {
@TableField
(
exist
=
false
)
public
static
final
Long
REVIEW_ROLE_ID
=
103L
;
/**
* 创新基地参与审核的角色
*/
@TableField
(
exist
=
false
)
public
static
final
Long
INNOVATION_BASE_ID
=
113L
;
/**
* 主键
*/
...
...
@@ -215,4 +221,11 @@ public class ReviewSceneChangeTask {
@ApiModelProperty
(
value
=
"审查场景id"
,
notes
=
"1.若为修改、删除任务时,此id在创建任务时赋值; 2.若为新增任务时,此id在审批通过并保存新场景后赋值 "
)
private
Long
reviewSceneId
;
@ApiModelProperty
(
"评审人员"
)
@TableField
(
exist
=
false
)
private
String
reviewer
;
@ApiModelProperty
(
"创新基地结果"
)
private
String
innovationBaseResult
;
}
quality-review/src/main/java/com/ruoyi/domain/ReviewSceneChangeTaskUserRelation.java
View file @
553ab27f
...
...
@@ -80,4 +80,7 @@ public class ReviewSceneChangeTaskUserRelation {
@ApiModelProperty
(
"部门名称"
)
private
String
dept
;
@ApiModelProperty
(
"角色id"
)
private
Long
roleId
;
}
quality-review/src/main/java/com/ruoyi/mapper/ReviewKeyPointMapper.java
View file @
553ab27f
...
...
@@ -5,6 +5,8 @@ import com.ruoyi.domain.ReviewDetails;
import
com.ruoyi.domain.ReviewKeyPoint
;
import
com.ruoyi.domain.ReviewStandard
;
import
com.ruoyi.web.request.ReviewFindListRequest
;
import
com.ruoyi.web.response.ReviewDetailsListResponse
;
import
com.ruoyi.web.response.ReviewKeyPointListResponse
;
import
org.apache.ibatis.annotations.Param
;
import
org.springframework.stereotype.Repository
;
...
...
@@ -20,4 +22,8 @@ public interface ReviewKeyPointMapper extends BaseMapper<ReviewKeyPoint> {
// 根据细则列表查询要点列表
List
<
ReviewKeyPoint
>
findByDetailsList
(
@Param
(
"detailsList"
)
List
<
ReviewDetails
>
detailsList
);
List
<
ReviewKeyPointListResponse
>
getKeyPointList
(
@Param
(
"standardId"
)
Long
standardId
);
List
<
ReviewDetailsListResponse
>
getDetailsList
(
@Param
(
"keyPointId"
)
Long
keyPointId
);
}
quality-review/src/main/java/com/ruoyi/mapper/ReviewSceneChangeTaskMapper.java
View file @
553ab27f
...
...
@@ -6,6 +6,7 @@ import com.ruoyi.web.request.ReviewSceneChangeTaskFindCreateRequest;
import
com.ruoyi.web.request.ReviewSceneChangeTaskFindFinishRequest
;
import
com.ruoyi.web.request.ReviewSceneChangeTaskFindPendingRequest
;
import
com.ruoyi.web.response.ReviewSceneChangeTaskResponse
;
import
com.ruoyi.web.response.ReviewerListResponse
;
import
org.springframework.stereotype.Repository
;
import
org.apache.ibatis.annotations.Param
;
...
...
@@ -44,6 +45,24 @@ public interface ReviewSceneChangeTaskMapper extends BaseMapper<ReviewSceneChang
*/
List
<
ReviewSceneChangeTask
>
findCreateListByUserId
(
@Param
(
"userId"
)
Long
userId
,
@Param
(
"request"
)
ReviewSceneChangeTaskFindCreateRequest
request
);
/*
* 根据id查询任务详细信息
* */
ReviewSceneChangeTask
findSceneChangeTaskById
(
@Param
(
"id"
)
Long
id
);
/**
* 创新基地查询待办列表
* @return
*/
List
<
ReviewSceneChangeTaskResponse
>
findPendingList
(
@Param
(
"userId"
)
Long
userId
,
@Param
(
"request"
)
ReviewSceneChangeTaskFindPendingRequest
request
);
/**
* 创新基地查询已办列表
* @return
*/
List
<
ReviewSceneChangeTaskResponse
>
findFinishList
(
@Param
(
"userId"
)
Long
userId
,
@Param
(
"request"
)
ReviewSceneChangeTaskFindFinishRequest
request
);
List
<
ReviewerListResponse
>
selectReviewerListByTaskId
(
@Param
(
"id"
)
Long
id
);
}
...
...
quality-review/src/main/java/com/ruoyi/service/ReviewSceneChangeTaskService.java
View file @
553ab27f
...
...
@@ -6,6 +6,8 @@ import com.ruoyi.web.request.ReviewSceneChangeTaskFindCreateRequest;
import
com.ruoyi.web.request.ReviewSceneChangeTaskFindFinishRequest
;
import
com.ruoyi.web.request.ReviewSceneChangeTaskFindPendingRequest
;
import
com.ruoyi.web.request.ReviewSceneChangeTaskPassRequest
;
import
com.ruoyi.web.response.ReviewDetailsListResponse
;
import
com.ruoyi.web.response.ReviewKeyPointListResponse
;
import
com.ruoyi.web.response.ReviewSceneChangeTaskResponse
;
import
java.util.Date
;
...
...
@@ -77,4 +79,40 @@ public interface ReviewSceneChangeTaskService extends IService<ReviewSceneChange
*/
List
<
ReviewSceneChangeTask
>
findCreateListByUserId
(
Long
userId
,
ReviewSceneChangeTaskFindCreateRequest
request
);
ReviewSceneChangeTask
getBySceneChangeTaskId
(
Long
id
);
/**
* 创新基地查询待办列表
* @return
*/
List
<
ReviewSceneChangeTaskResponse
>
findPendingList
(
Long
userId
,
ReviewSceneChangeTaskFindPendingRequest
request
);
/**
* 创新基地查询已办列表
* @return
*/
List
<
ReviewSceneChangeTaskResponse
>
findFinishList
(
Long
userId
,
ReviewSceneChangeTaskFindFinishRequest
request
);
/**
* 创新基地查询任务详情
* @return
*/
ReviewSceneChangeTask
getBySceneChange
(
Long
id
);
/**
* 创新基地审核任务
* @return
*/
void
innovationBaseAudit
(
ReviewSceneChangeTaskPassRequest
request
);
/*
* 发起评审-新增审查场景-获取要点列表
* */
List
<
ReviewKeyPointListResponse
>
getKeyPointList
(
Long
standardId
);
/*
* 发起评审-新增审查场景-获取细则列表
* */
List
<
ReviewDetailsListResponse
>
getDetailsList
(
Long
keyPointId
);
}
quality-review/src/main/java/com/ruoyi/service/ReviewStandardService.java
View file @
553ab27f
...
...
@@ -38,7 +38,6 @@ public interface ReviewStandardService extends IService<ReviewStandard> {
* @return
*/
ReviewStandardInspectionContentResponse
selectInspectionContent
(
Long
id
);
/**
* 根据标准主键ID查询车型试验的检验内容
* @param id
...
...
quality-review/src/main/java/com/ruoyi/service/impl/CarReviewTaskServiceImpl.java
View file @
553ab27f
...
...
@@ -97,7 +97,6 @@ public class CarReviewTaskServiceImpl extends ServiceImpl<CarReviewTaskMapper, C
carReviewTaskService
.
save
(
task
);
// 构建并保存该任务所关联的审核组信息
for
(
TaskUserRelation
auditor
:
auditors
)
{
auditor
.
setTaskId
(
task
.
getId
());
...
...
@@ -124,14 +123,12 @@ public class CarReviewTaskServiceImpl extends ServiceImpl<CarReviewTaskMapper, C
@Override
public
void
confirmReviewTask
(
CarReviewTaskConfirmRequest
request
)
{
CarReviewTask
carReviewTask
=
carReviewTaskService
.
getById
(
request
.
getTaskId
());
strategyCarReviewTaskContext
.
getResource
(
carReviewTask
.
getTaskStatus
()).
doConfirmReview
(
carReviewTask
);
}
@Override
public
void
submitReviewTask
(
CarReviewTaskSubmitRequest
request
)
{
CarReviewTask
carReviewTask
=
carReviewTaskService
.
getById
(
request
.
getTaskId
());
strategyCarReviewTaskContext
.
getResource
(
carReviewTask
.
getTaskStatus
()).
doSubmitReview
(
carReviewTask
,
request
.
getImagesUrl
(),
request
.
getTestScenarioList
());
}
...
...
@@ -140,7 +137,6 @@ public class CarReviewTaskServiceImpl extends ServiceImpl<CarReviewTaskMapper, C
public
List
<
CarReviewTask
>
findListByStatus
(
String
status
)
{
return
carReviewTaskMapper
.
findListByTaskStatus
(
status
);
}
}
...
...
quality-review/src/main/java/com/ruoyi/service/impl/MatrixServiceImpl.java
View file @
553ab27f
...
...
@@ -5,13 +5,15 @@ import com.alibaba.fastjson2.JSONObject;
import
com.ruoyi.domain.TestScenario
;
import
com.ruoyi.domain.TestType
;
import
com.ruoyi.domain.TestUseCase
;
import
com.ruoyi.domain.vo.*
;
import
com.ruoyi.domain.vo.MatrixColumnVO
;
import
com.ruoyi.domain.vo.ScenarioVO
;
import
com.ruoyi.domain.vo.TestTypeVO
;
import
com.ruoyi.domain.vo.UseCaseVO
;
import
com.ruoyi.service.ITestScenarioService
;
import
com.ruoyi.service.ITestTypeService
;
import
com.ruoyi.service.MatrixService
;
import
com.ruoyi.service.TestUseCaseService
;
import
com.ruoyi.web.response.MatrixResponse
;
import
lombok.Data
;
import
okhttp3.*
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
...
...
@@ -95,6 +97,7 @@ public class MatrixServiceImpl implements MatrixService {
.
method
(
"POST"
,
body
)
.
addHeader
(
"Content-Type"
,
"application/json"
)
// TODO 连接
.
addHeader
(
"Authorization"
,
"Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjAsInRva2VuaWQiOjYxLCJ0eXBlIjoiYXBpIiwidXNlcm5hbWUiOiJhZG1pbiJ9.48Ggjx-FtOcecf73vAHn0XglwgLXZlfXxhXiLDHWWQE"
)
// .addHeader("Host", "10.12.48.80:8089")
// .addHeader("Origin", "http://10.12.48.80:8089")
// .addHeader("Referer", "http://10.12.48.80:8089/api/graphql/playground")
...
...
@@ -159,6 +162,7 @@ public class MatrixServiceImpl implements MatrixService {
.
method
(
"POST"
,
body
)
.
addHeader
(
"Content-Type"
,
"application/json"
)
// TODO 连接
.
addHeader
(
"Authorization"
,
"Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjAsInRva2VuaWQiOjYxLCJ0eXBlIjoiYXBpIiwidXNlcm5hbWUiOiJhZG1pbiJ9.48Ggjx-FtOcecf73vAHn0XglwgLXZlfXxhXiLDHWWQE"
)
// .addHeader("Host", "10.12.48.80:8089")
// .addHeader("Origin", "http://10.12.48.80:8089")
// .addHeader("Referer", "http://10.12.48.80:8089/api/graphql/playground")
...
...
quality-review/src/main/java/com/ruoyi/service/impl/PdfTemplateManagementServiceImpl.java
View file @
553ab27f
...
...
@@ -135,7 +135,6 @@ public class PdfTemplateManagementServiceImpl implements PdfTemplateManagementSe
ps
.
close
();
bos
.
close
();
reader
.
close
();
// 把第一个模板填入数据后生成一个oss
String
templateName
=
uploadMinio
(
bos
,
"整车信息安全检验临时模板"
);
// 创建一个空PDF, 融合两个PDF
...
...
quality-review/src/main/java/com/ruoyi/service/impl/ReviewSceneChangeTaskServiceImpl.java
View file @
553ab27f
This diff is collapsed.
Click to expand it.
quality-review/src/main/java/com/ruoyi/service/impl/ReviewStandardServiceImpl.java
View file @
553ab27f
...
...
@@ -9,9 +9,14 @@ import com.ruoyi.common.utils.SnowflakeUtil;
import
com.ruoyi.domain.*
;
import
com.ruoyi.domain.vo.InspectionContentVO
;
import
com.ruoyi.domain.vo.OptionalUseCasesVO
;
import
com.ruoyi.domain.vo.UseCaseUrlVO
;
import
com.ruoyi.mapper.*
;
import
com.ruoyi.service.*
;
import
com.ruoyi.mapper.ReviewDetailsMapper
;
import
com.ruoyi.mapper.ReviewKeyPointMapper
;
import
com.ruoyi.mapper.ReviewStandardMapper
;
import
com.ruoyi.mapper.TestUseCaseMapper
;
import
com.ruoyi.service.ReviewDetailsService
;
import
com.ruoyi.service.ReviewKeyPointService
;
import
com.ruoyi.service.ReviewSceneService
;
import
com.ruoyi.service.ReviewStandardService
;
import
com.ruoyi.web.request.ReviewFindListRequest
;
import
com.ruoyi.web.request.ReviewStandardListByPageRequest
;
import
com.ruoyi.web.request.ReviewStandardListRequest
;
...
...
@@ -211,6 +216,7 @@ public class ReviewStandardServiceImpl extends ServiceImpl<ReviewStandardMapper,
.
method
(
"POST"
,
body
)
.
addHeader
(
"Content-Type"
,
"application/json"
)
// TODO 连接
.
addHeader
(
"Authorization"
,
"Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjAsInRva2VuaWQiOjYxLCJ0eXBlIjoiYXBpIiwidXNlcm5hbWUiOiJhZG1pbiJ9.48Ggjx-FtOcecf73vAHn0XglwgLXZlfXxhXiLDHWWQE"
)
// .addHeader("Host", "10.12.48.80:8089")
// .addHeader("Origin", "http://10.12.48.80:8089")
// .addHeader("Referer", "http://10.12.48.80:8089/api/graphql/playground")
...
...
quality-review/src/main/java/com/ruoyi/service/impl/StrategyReviewSceneChangeAdd.java
View file @
553ab27f
...
...
@@ -68,11 +68,20 @@ public class StrategyReviewSceneChangeAdd implements StrategyReviewSceneChange,
.
setReviewStandardId
(
reviewSceneChangeTask
.
getStandardId
());
reviewKeyPointMapper
.
insert
(
reviewKeyPoint
);
//为新增细则变更任务的细则关联id字段赋值
reviewSceneChangeTask
.
setKeypointId
(
reviewKeyPoint
.
getId
());
reviewSceneChangeTaskService
.
updateById
(
reviewSceneChangeTask
);
// 细则
ReviewDetails
reviewDetails
=
new
ReviewDetails
()
.
setText
(
reviewSceneChangeTask
.
getDetails
())
.
setReviewKeypointId
(
reviewKeyPoint
.
getId
());
reviewDetailsMapper
.
insert
(
reviewDetails
);
//为新增细则变更任务的细则关联id字段赋值
reviewSceneChangeTask
.
setDetailsId
(
reviewDetails
.
getId
());
reviewSceneChangeTaskService
.
updateById
(
reviewSceneChangeTask
);
}
// 保存新增的细则
...
...
@@ -82,6 +91,10 @@ public class StrategyReviewSceneChangeAdd implements StrategyReviewSceneChange,
.
setText
(
reviewSceneChangeTask
.
getDetails
())
.
setReviewKeypointId
(
reviewSceneChangeTask
.
getKeypointId
());
reviewDetailsMapper
.
insert
(
reviewDetails
);
//为新增细则变更任务的细则关联id字段赋值
reviewSceneChangeTask
.
setDetailsId
(
reviewDetails
.
getId
());
reviewSceneChangeTaskService
.
updateById
(
reviewSceneChangeTask
);
}
...
...
quality-review/src/main/java/com/ruoyi/service/impl/SystemReviewTaskServiceImpl.java
View file @
553ab27f
...
...
@@ -108,7 +108,7 @@ public class SystemReviewTaskServiceImpl extends ServiceImpl<SystemReviewTaskMap
@Override
public
void
start
(
Long
id
)
{
SystemReviewTask
systemReviewTask
=
systemReviewTaskService
.
getById
(
id
);
strategySystemReviewTaskContext
.
getResource
(
systemReviewTask
.
getTaskStatus
()).
doStart
(
systemReviewTask
);
strategySystemReviewTaskContext
.
getResource
(
systemReviewTask
.
getTaskStatus
()).
doStart
(
systemReviewTask
);
}
@Override
...
...
quality-review/src/main/java/com/ruoyi/service/impl/TaskServiceImpl.java
View file @
553ab27f
...
...
@@ -153,6 +153,7 @@ public class TaskServiceImpl extends ServiceImpl<TaskMapper, Task>implements Tas
// 构建任务创建者
LoginUser
loginUser
=
SecurityUtils
.
getLoginUser
();
//根据Id查询当前用户是否拥有暂存任务
TaskGetInfoResponse
temporaryStorageTask
=
taskService
.
getByUserId
(
loginUser
.
getUserId
());
if
(
temporaryStorageTask
!=
null
)
{
taskMapper
.
deleteById
(
temporaryStorageTask
.
getId
());
...
...
@@ -408,7 +409,6 @@ public class TaskServiceImpl extends ServiceImpl<TaskMapper, Task>implements Tas
if
(
fileList
!=
null
&&
fileList
.
size
()
!=
0
)
{
taskFileRelationService
.
removeBatchByIds
(
fileList
);
}
taskMapper
.
deleteById
(
request
.
getId
());
}
...
...
@@ -458,7 +458,6 @@ public class TaskServiceImpl extends ServiceImpl<TaskMapper, Task>implements Tas
}
}
}
return
responses
;
}
...
...
quality-review/src/main/java/com/ruoyi/service/impl/TestUseCaseServiceImpl.java
View file @
553ab27f
...
...
@@ -4,15 +4,17 @@ import cn.hutool.http.HttpUtil;
import
com.alibaba.fastjson2.JSONObject
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
com.ruoyi.domain.TestUseCase
;
import
com.ruoyi.domain.vo.*
;
import
com.ruoyi.service.TestUseCaseService
;
import
com.ruoyi.domain.vo.CaseResultVO
;
import
com.ruoyi.domain.vo.CountVO
;
import
com.ruoyi.domain.vo.TestUsecaseVO
;
import
com.ruoyi.domain.vo.UseCaseUrlVO
;
import
com.ruoyi.mapper.TestUseCaseMapper
;
import
com.ruoyi.service.TestUseCaseService
;
import
com.ruoyi.web.request.TestUseCaseByScenarioRequest
;
import
com.ruoyi.web.request.TestUseCaseIdListRequest
;
import
com.ruoyi.web.request.TestUserCaseRequest
;
import
com.ruoyi.web.response.TestUserCaseListResponse
;
import
com.ruoyi.web.response.UseCaseResponse
;
import
lombok.Data
;
import
okhttp3.*
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
...
...
@@ -115,6 +117,7 @@ public class TestUseCaseServiceImpl extends ServiceImpl<TestUseCaseMapper, TestU
.
method
(
"POST"
,
body
)
.
addHeader
(
"Content-Type"
,
"application/json"
)
// TODO 连接
.
addHeader
(
"Authorization"
,
"Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjAsInRva2VuaWQiOjYxLCJ0eXBlIjoiYXBpIiwidXNlcm5hbWUiOiJhZG1pbiJ9.48Ggjx-FtOcecf73vAHn0XglwgLXZlfXxhXiLDHWWQE"
)
// .addHeader("Host", "10.12.48.80:8089")
// .addHeader("Origin", "http://10.12.48.80:8089")
// .addHeader("Referer", "http://10.12.48.80:8089/api/graphql/playground")
...
...
@@ -163,6 +166,7 @@ public class TestUseCaseServiceImpl extends ServiceImpl<TestUseCaseMapper, TestU
.
method
(
"POST"
,
body
)
.
addHeader
(
"Content-Type"
,
"application/json"
)
// TODO 连接
.
addHeader
(
"Authorization"
,
"Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjAsInRva2VuaWQiOjYxLCJ0eXBlIjoiYXBpIiwidXNlcm5hbWUiOiJhZG1pbiJ9.48Ggjx-FtOcecf73vAHn0XglwgLXZlfXxhXiLDHWWQE"
)
// .addHeader("Host", "10.12.48.80:8089")
// .addHeader("Origin", "http://10.12.48.80:8089")
// .addHeader("Referer", "http://10.12.48.80:8089/api/graphql/playground")
...
...
@@ -205,6 +209,7 @@ public class TestUseCaseServiceImpl extends ServiceImpl<TestUseCaseMapper, TestU
.
method
(
"POST"
,
body
)
.
addHeader
(
"Content-Type"
,
"application/json"
)
// TODO 连接
.
addHeader
(
"Authorization"
,
"Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjAsInRva2VuaWQiOjYxLCJ0eXBlIjoiYXBpIiwidXNlcm5hbWUiOiJhZG1pbiJ9.48Ggjx-FtOcecf73vAHn0XglwgLXZlfXxhXiLDHWWQE"
)
// .addHeader("Host", "10.12.48.80:8089")
// .addHeader("Origin", "http://10.12.48.80:8089")
// .addHeader("Referer", "http://10.12.48.80:8089/api/graphql/playground")
...
...
@@ -248,6 +253,7 @@ public class TestUseCaseServiceImpl extends ServiceImpl<TestUseCaseMapper, TestU
.
method
(
"POST"
,
body
)
.
addHeader
(
"Content-Type"
,
"application/json"
)
// TODO 连接
.
addHeader
(
"Authorization"
,
"Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjAsInRva2VuaWQiOjYxLCJ0eXBlIjoiYXBpIiwidXNlcm5hbWUiOiJhZG1pbiJ9.48Ggjx-FtOcecf73vAHn0XglwgLXZlfXxhXiLDHWWQE"
)
// .addHeader("Host", "10.12.48.80:8089")
// .addHeader("Origin", "http://10.12.48.80:8089")
// .addHeader("Referer", "http://10.12.48.80:8089/api/graphql/playground")
...
...
quality-review/src/main/java/com/ruoyi/web/ReviewSceneChangeTaskController.java
View file @
553ab27f
...
...
@@ -6,21 +6,30 @@ import com.ruoyi.common.core.domain.R;
import
com.ruoyi.common.core.page.TableDataInfo
;
import
com.ruoyi.common.enums.BusinessType
;
import
com.ruoyi.common.utils.bean.BeanUtils
;
import
com.ruoyi.domain.ReviewKeyPoint
;
import
com.ruoyi.domain.ReviewSceneChangeTask
;
import
com.ruoyi.service.ReviewSceneChangeTaskService
;
import
com.ruoyi.web.request.ReviewSceneChangeTaskCreateRequest
;
import
com.ruoyi.web.request.ReviewSceneChangeTaskPassRequest
;
import
com.ruoyi.web.response.ReviewDetailsListResponse
;
import
com.ruoyi.web.response.ReviewKeyPointListResponse
;
import
com.ruoyi.web.response.ReviewSceneChangeTaskResponse
;
import
com.ruoyi.web.request.*
;
import
com.ruoyi.web.response.ReviewStandardListResponse
;
import
com.ruoyi.web.response.ReviewSceneChangeTaskResponse
;
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.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.*
;
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
java.util.List
;
@Api
(
tags
=
"场景变更任务"
)
@RestController
...
...
@@ -39,8 +48,7 @@ public class ReviewSceneChangeTaskController extends BaseController {
ReviewSceneChangeTask
reviewSceneChangeTask
=
new
ReviewSceneChangeTask
();
BeanUtils
.
copyBeanProp
(
reviewSceneChangeTask
,
request
);
reviewSceneChangeTask
.
setOperationSort
(
request
.
getOperation
()+
"_"
+
request
.
getSort
());
/*reviewSceneChangeTask.setOperationSort(request.getOperation()+"_"+request.getSort());*/
reviewSceneChangeTaskService
.
create
(
reviewSceneChangeTask
);
return
R
.
ok
();
...
...
@@ -52,7 +60,6 @@ public class ReviewSceneChangeTaskController extends BaseController {
@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
();
}
...
...
@@ -87,7 +94,8 @@ public class ReviewSceneChangeTaskController extends BaseController {
* 查询当前用户发布的任务
* @return
*/
@ApiOperation
(
"查询当前用户发布的任务"
)
/*@ApiOperation("查询当前用户发布的任务")*/
@ApiOperation
(
"用户-评审管理-我发起的评审"
)
@Trace
@Tags
({
@Tag
(
key
=
"param"
,
value
=
"arg[0]"
),
@Tag
(
key
=
"result"
,
value
=
"returnedObj"
)})
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/findCreate"
)
...
...
@@ -101,7 +109,87 @@ public class ReviewSceneChangeTaskController extends BaseController {
@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
()));
Long
id
=
Long
.
parseLong
(
request
.
getId
());
return
R
.
ok
(
reviewSceneChangeTaskService
.
getBySceneChangeTaskId
(
id
));
}
/**
* 创新基地查询待办列表
* @return
*/
@ApiOperation
(
"创新基地查询待办列表"
)
@Trace
@Tags
({
@Tag
(
key
=
"param"
,
value
=
"arg[0]"
),
@Tag
(
key
=
"result"
,
value
=
"returnedObj"
)})
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/innovationBaseFindPending"
)
public
TableDataInfo
<
ReviewSceneChangeTaskResponse
>
innovationBaseFindPending
(
@Validated
@RequestBody
ReviewSceneChangeTaskFindPendingRequest
request
)
{
startPage
(
request
);
return
getDataTable
(
reviewSceneChangeTaskService
.
findPendingList
(
getUserId
(),
request
));
}
/**
* 创新基地查询已办列表
* @return
*/
@ApiOperation
(
"创新基地查询已办列表"
)
@Trace
@Tags
({
@Tag
(
key
=
"param"
,
value
=
"arg[0]"
),
@Tag
(
key
=
"result"
,
value
=
"returnedObj"
)})
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/innovationBaseFindFinish"
)
public
TableDataInfo
<
ReviewSceneChangeTaskResponse
>
innovationBaseFindFinish
(
@Validated
@RequestBody
ReviewSceneChangeTaskFindFinishRequest
request
)
{
startPage
(
request
);
return
getDataTable
(
reviewSceneChangeTaskService
.
findFinishList
(
getUserId
(),
request
));
}
/**
* 创新基地查询任务详情
* @return
*/
@ApiOperation
(
"查询任务详情"
)
@Trace
@Tags
({
@Tag
(
key
=
"param"
,
value
=
"arg[0]"
),
@Tag
(
key
=
"result"
,
value
=
"returnedObj"
)})
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/innovationBaseGetById"
)
public
R
<
ReviewSceneChangeTask
>
innovationBaseGetById
(
@Validated
@RequestBody
ReviewSceneChangeTaskGetInfoRequest
request
)
{
Long
id
=
Long
.
parseLong
(
request
.
getId
());
return
R
.
ok
(
reviewSceneChangeTaskService
.
getBySceneChange
(
id
));
}
/**
* 创新基地审核任务
* @return
*/
@ApiOperation
(
"审核任务"
)
@Trace
@Tags
({
@Tag
(
key
=
"param"
,
value
=
"arg[0]"
),
@Tag
(
key
=
"result"
,
value
=
"returnedObj"
)})
@Log
(
title
=
"审核任务"
,
businessType
=
BusinessType
.
UPDATE
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/innovationBaseAudit"
)
public
R
<
String
>
innovationBaseAudit
(
@Validated
@RequestBody
ReviewSceneChangeTaskPassRequest
request
)
{
reviewSceneChangeTaskService
.
innovationBaseAudit
(
request
);
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
=
"/getKeyPointList"
)
public
R
<
List
<
ReviewKeyPointListResponse
>>
getKeyPointList
(
@Validated
@RequestBody
ReviewKeyPointListRequest
request
){
List
<
ReviewKeyPointListResponse
>
list
=
reviewSceneChangeTaskService
.
getKeyPointList
(
request
.
getStandardId
());
return
R
.
ok
(
list
);
}
/*
* 发起评审-新增审查场景-获取细则列表
* */
@ApiOperation
(
"发起评审-新增审查场景-获取细则列表"
)
@Trace
@Tags
({
@Tag
(
key
=
"param"
,
value
=
"arg[0]"
),
@Tag
(
key
=
"result"
,
value
=
"returnedObj"
)})
@Log
(
title
=
"发起评审-新增审查场景-获取细则列表"
,
businessType
=
BusinessType
.
UPDATE
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/getDetailsList"
)
public
R
<
List
<
ReviewDetailsListResponse
>>
getKeyPointList
(
@Validated
@RequestBody
ReviewDetailsListRequest
request
){
List
<
ReviewDetailsListResponse
>
list
=
reviewSceneChangeTaskService
.
getDetailsList
(
request
.
getKeyPointId
());
return
R
.
ok
(
list
);
}
}
quality-review/src/main/java/com/ruoyi/web/ReviewStandardController.java
View file @
553ab27f
...
...
@@ -45,7 +45,6 @@ public class ReviewStandardController extends BaseController {
List
<
ReviewStandardResponse
>
list
=
reviewStandardService
.
listByPage
(
request
);
return
getDataTable
(
list
);
}
/**
* 根据标准主键ID查询树状结构
* @param request
...
...
quality-review/src/main/java/com/ruoyi/web/SystemReviewTaskController.java
View file @
553ab27f
...
...
@@ -102,7 +102,6 @@ public class SystemReviewTaskController extends BaseController {
@Tags
({
@Tag
(
key
=
"param"
,
value
=
"arg[0]"
),
@Tag
(
key
=
"result"
,
value
=
"returnedObj"
)})
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/exportPDF"
)
public
R
<
SystemReviewTaskExportPDFResponse
>
exportPDF
()
{
return
null
;
}
}
quality-review/src/main/java/com/ruoyi/web/TaskController.java
View file @
553ab27f
...
...
@@ -78,7 +78,6 @@ public class TaskController extends BaseController {
@Tags
({
@Tag
(
key
=
"param"
,
value
=
"arg[0]"
),
@Tag
(
key
=
"result"
,
value
=
"returnedObj"
)})
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/getTemporaryStorage"
)
public
R
<
TaskGetInfoResponse
>
getTemporaryStorage
()
{
TaskGetInfoResponse
response
=
taskService
.
getByUserId
(
getUserId
());
return
R
.
ok
(
response
);
}
...
...
@@ -108,7 +107,6 @@ public class TaskController extends BaseController {
@Tags
({
@Tag
(
key
=
"param"
,
value
=
"arg[0]"
),
@Tag
(
key
=
"result"
,
value
=
"returnedObj"
)})
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/findCreate"
)
public
TableDataInfo
<
TaskFindResponse
>
findCreate
(
@Validated
@RequestBody
TaskFindRequest
request
)
{
startPage
(
request
);
return
getDataTable
(
taskService
.
findCreate
(
request
,
getUserId
()));
}
...
...
@@ -186,7 +184,6 @@ public class TaskController extends BaseController {
@Tags
({
@Tag
(
key
=
"param"
,
value
=
"arg[0]"
),
@Tag
(
key
=
"result"
,
value
=
"returnedObj"
)})
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/dataStatistics"
)
public
R
<
DataStatisticsResponse
>
dataStatistics
(
@Validated
@RequestBody
TaskGetInfoRequest
request
)
{
DataStatisticsResponse
response
=
taskService
.
dataStatistics
(
request
);
return
R
.
ok
(
response
);
}
...
...
quality-review/src/main/java/com/ruoyi/web/request/ReviewDetailsListRequest.java
0 → 100644
View file @
553ab27f
package
com
.
ruoyi
.
web
.
request
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
@ApiModel
(
value
=
"ReviewKeyPointListRequest"
,
description
=
"查询细则列表参数"
)
@Data
public
class
ReviewDetailsListRequest
{
@ApiModelProperty
(
"标准要求id"
)
private
Long
keyPointId
;
}
quality-review/src/main/java/com/ruoyi/web/request/ReviewKeyPointListRequest.java
0 → 100644
View file @
553ab27f
package
com
.
ruoyi
.
web
.
request
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
@ApiModel
(
value
=
"ReviewKeyPointListRequest"
,
description
=
"查询要点列表参数"
)
@Data
public
class
ReviewKeyPointListRequest
{
@ApiModelProperty
(
"标准要求id"
)
private
Long
standardId
;
}
quality-review/src/main/java/com/ruoyi/web/request/ReviewSceneChangeTaskCreateRequest.java
View file @
553ab27f
...
...
@@ -65,11 +65,17 @@ public class ReviewSceneChangeTaskCreateRequest {
/**
* 操作(ADD DELETE UPDATE)
*/
@ApiModelProperty
(
value
=
"操作"
,
notes
=
"[ADD DELETE UPDATE]"
)
private
String
operation
;
@ApiModelProperty
(
value
=
"分类"
,
notes
=
"[KEYPOINT DETAILS SCENE]"
)
private
String
sort
;
// @ApiModelProperty(value = "操作" , notes = "[ADD DELETE UPDATE]")
// private String operation;
//
// @ApiModelProperty(value = "分类" , notes = "[KEYPOINT DETAILS SCENE]")
// private String sort;
/*
* 评审类型
* */
@ApiModelProperty
(
"评审类型"
)
private
String
operationSort
;
/**
* 当 operation 为 ADD 时该字段为空
...
...
quality-review/src/main/java/com/ruoyi/web/request/ReviewSceneChangeTaskGetInfoRequest.java
View file @
553ab27f
...
...
@@ -8,6 +8,10 @@ import lombok.Data;
@ApiModel
public
class
ReviewSceneChangeTaskGetInfoRequest
{
/*
* 由于Long类型的id太长,前端接受数据时会产生差错,这里将Long改为String确保id正常传递
* */
@ApiModelProperty
(
"ID"
)
private
Long
id
;
private
String
id
;
}
quality-review/src/main/java/com/ruoyi/web/request/ReviewStandardListByPageRequest.java
View file @
553ab27f
package
com
.
ruoyi
.
web
.
request
;
import
com.ruoyi.common.core.page.PageDomain
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
...
...
@@ -44,4 +45,10 @@ public class ReviewStandardListByPageRequest extends PageDomain {
@ApiModelProperty
(
"测试方法"
)
private
String
testMethod
;
@ApiModelProperty
(
"标准名称"
)
private
String
name
;
@ApiModelProperty
(
"标准号"
)
private
String
standardNo
;
}
quality-review/src/main/java/com/ruoyi/web/response/ReviewDetailsListResponse.java
0 → 100644
View file @
553ab27f
package
com
.
ruoyi
.
web
.
response
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
@ApiModel
(
value
=
"ReviewKeyPointListResponse"
,
description
=
"查询细则列表返回结果"
)
@Data
public
class
ReviewDetailsListResponse
{
@ApiModelProperty
(
"主键-要点id"
)
private
Long
id
;
@ApiModelProperty
(
"要点文本内容"
)
private
String
text
;
@ApiModelProperty
(
"标准id"
)
private
Long
reviewKeypointId
;
}
quality-review/src/main/java/com/ruoyi/web/response/ReviewKeyPointListResponse.java
0 → 100644
View file @
553ab27f
package
com
.
ruoyi
.
web
.
response
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
@ApiModel
(
value
=
"ReviewKeyPointListResponse"
,
description
=
"查询要点列表返回结果"
)
@Data
public
class
ReviewKeyPointListResponse
{
@ApiModelProperty
(
"主键-要点id"
)
private
Long
id
;
@ApiModelProperty
(
"要点文本内容"
)
private
String
text
;
@ApiModelProperty
(
"标准id"
)
private
Long
reviewStandardId
;
}
quality-review/src/main/java/com/ruoyi/web/response/ReviewSceneChangeTaskResponse.java
View file @
553ab27f
package
com
.
ruoyi
.
web
.
response
;
import
com.baomidou.mybatisplus.annotation.TableField
;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
...
...
@@ -12,10 +13,10 @@ import java.util.Date;
public
class
ReviewSceneChangeTaskResponse
{
/**
* 主键
* 主键
由于主键太长返回给前端时会造成数据不对问题,这里将id改为String类型。
*/
@ApiModelProperty
(
"主键"
)
private
Lo
ng
id
;
private
Stri
ng
id
;
/**
* 任务编号
...
...
@@ -161,4 +162,11 @@ public class ReviewSceneChangeTaskResponse {
*/
@ApiModelProperty
(
"本人审核意见(PASS、REJECT)"
)
private
String
decision
;
@ApiModelProperty
(
"评审人员"
)
@TableField
(
exist
=
false
)
private
String
reviewer
;
@ApiModelProperty
(
"创新基地结果"
)
private
String
innovationBaseResult
;
}
quality-review/src/main/java/com/ruoyi/web/response/ReviewStandardResponse.java
View file @
553ab27f
...
...
@@ -35,4 +35,10 @@ public class ReviewStandardResponse {
@ApiModelProperty
(
"测试方法(车型试验专有)"
)
private
String
testMethod
;
@ApiModelProperty
(
"标准名称"
)
private
String
name
;
@ApiModelProperty
(
"标准号"
)
private
String
standardNo
;
}
quality-review/src/main/java/com/ruoyi/web/response/ReviewerListResponse.java
0 → 100644
View file @
553ab27f
package
com
.
ruoyi
.
web
.
response
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
@ApiModel
(
value
=
"ReviewerListResponse"
,
description
=
"评审人员集合"
)
@Data
public
class
ReviewerListResponse
{
@ApiModelProperty
(
"评审员名称"
)
private
String
reviewer
;
}
quality-review/src/main/resources/mapper/ReviewKeyPointMapper.xml
View file @
553ab27f
...
...
@@ -26,5 +26,13 @@
#{detail.reviewKeypointId}
</foreach>
</select>
<select
id=
"getKeyPointList"
resultType=
"com.ruoyi.web.response.ReviewKeyPointListResponse"
>
select id, text from t_review_keypoint
where review_standard_id = #{standardId}
</select>
<select
id=
"getDetailsList"
resultType=
"com.ruoyi.web.response.ReviewDetailsListResponse"
>
select id, text from t_review_details
where review_keypoint_id = #{keyPointId}
</select>
</mapper>
quality-review/src/main/resources/mapper/ReviewSceneChangeTaskMapper.xml
View file @
553ab27f
...
...
@@ -24,6 +24,7 @@
<result
property=
"taskEndTime"
column=
"task_end_time"
jdbcType=
"TIMESTAMP"
/>
<result
property=
"inspectStandardId"
column=
"inspect_standard_id"
jdbcType=
"BIGINT"
/>
<result
property=
"inspectStandardNo"
column=
"inspect_standard_no"
jdbcType=
"VARCHAR"
/>
<result
property=
"innovationBaseResult"
column=
"innovation_base_result"
jdbcType=
"VARCHAR"
/>
</resultMap>
<resultMap
id=
"ResponseResultMap"
type=
"com.ruoyi.web.response.ReviewSceneChangeTaskResponse"
>
...
...
@@ -47,6 +48,7 @@
<result
property=
"decision"
column=
"decision"
jdbcType=
"VARCHAR"
/>
<result
property=
"inspectStandardId"
column=
"inspect_standard_id"
jdbcType=
"BIGINT"
/>
<result
property=
"inspectStandardNo"
column=
"inspect_standard_no"
jdbcType=
"VARCHAR"
/>
<result
property=
"innovationBaseResult"
column=
"innovation_base_result"
jdbcType=
"VARCHAR"
/>
</resultMap>
<select
id=
"findLastChangeByTaskId"
resultType=
"com.ruoyi.domain.ReviewSceneChangeTask"
>
...
...
@@ -59,7 +61,8 @@
<select
id=
"findPendingListByUserId"
resultType=
"com.ruoyi.web.response.ReviewSceneChangeTaskResponse"
>
SELECT sct.*, sctu.decision 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 NULL
WHERE sctu.user_id = #{userId} and sctu.decision IS NULL and sctu.role_id = 103
/*and sct.innovation_base_result = 'PASS'*/
<if
test=
"request.operationSort != null and request.operationSort != ''"
>
and sct.operation_sort = #{request.operationSort}
</if>
...
...
@@ -77,7 +80,8 @@
<select
id=
"findFinishListByUserId"
resultType=
"com.ruoyi.web.response.ReviewSceneChangeTaskResponse"
>
SELECT sct.*, sctu.decision 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
WHERE sctu.user_id = #{userId} and sctu.decision IS NOT NULL and sctu.role_id = 103
/*and sct.innovation_base_result = 'PASS'*/
<if
test=
"request.operationSort != null and request.operationSort != ''"
>
and sct.operation_sort = #{request.operationSort}
</if>
...
...
@@ -94,7 +98,7 @@
<select
id=
"findCreateListByUserId"
resultType=
"com.ruoyi.domain.ReviewSceneChangeTask"
>
SELECT * FROM t_review_scene_change_task
WHERE task_initiator_id = #{userId}
WHERE task_initiator_id = #{userId}
/*and innovation_base_result = 'PASS'*/
<if
test=
"request.operationSort != null and request.operationSort != ''"
>
and operation_sort = #{request.operationSort}
</if>
...
...
@@ -112,4 +116,49 @@
</if>
</select>
<select
id=
"findSceneChangeTaskById"
resultType=
"com.ruoyi.domain.ReviewSceneChangeTask"
>
select * from t_review_scene_change_task where id = #{id}
</select>
<select
id=
"findPendingList"
resultType=
"com.ruoyi.web.response.ReviewSceneChangeTaskResponse"
>
SELECT sct.*, sctu.decision 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 NULL
<if
test=
"request.operationSort != null and request.operationSort != ''"
>
and sct.operation_sort = #{request.operationSort}
</if>
<if
test=
"request.type != null and request.type != ''"
>
and sct.type = #{request.type}
</if>
<if
test=
"request.keyword != null and request.keyword != ''"
>
and (sct.old_text like concat('%',#{request.keyword},'%') || sct.new_text like concat('%',#{request.keyword},'%'))
</if>
<if
test=
"request.inspectStandardId != null and request.inspectStandardId != ''"
>
and inspect_standard_id = #{request.inspectStandardId}
</if>
</select>
<select
id=
"findFinishList"
resultType=
"com.ruoyi.web.response.ReviewSceneChangeTaskResponse"
>
SELECT sct.*, sctu.decision 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
<if
test=
"request.operationSort != null and request.operationSort != ''"
>
and sct.operation_sort = #{request.operationSort}
</if>
<if
test=
"request.type != null and request.type != ''"
>
and sct.type = #{request.type}
</if>
<if
test=
"request.keyword != null and request.keyword != ''"
>
and (sct.old_text like concat('%',#{request.keyword},'%') || sct.new_text like concat('%',#{request.keyword},'%'))
</if>
<if
test=
"request.inspectStandardId != null and request.inspectStandardId != ''"
>
and inspect_standard_id = #{request.inspectStandardId}
</if>
</select>
<select
id=
"selectReviewerListByTaskId"
resultType=
"com.ruoyi.web.response.ReviewerListResponse"
>
select name as reviewer
from t_review_scene_change_task_user_relation
where task_id = #{id}
</select>
</mapper>
quality-review/src/main/resources/mapper/ReviewSceneChangeTaskUserRelationMapper.xml
View file @
553ab27f
...
...
@@ -7,10 +7,13 @@
<resultMap
id=
"BaseResultMap"
type=
"com.ruoyi.domain.ReviewSceneChangeTaskUserRelation"
>
<id
property=
"id"
column=
"id"
jdbcType=
"BIGINT"
/>
<result
property=
"taskId"
column=
"task_id"
jdbcType=
"BIGINT"
/>
<result
property=
"roleId"
column=
"role_id"
jdbcType=
"BIGINT"
/>
<result
property=
"userId"
column=
"user_id"
jdbcType=
"BIGINT"
/>
<result
property=
"name"
column=
"name"
jdbcType=
"VARCHAR"
/>
<result
property=
"dept"
column=
"dept"
jdbcType=
"VARCHAR"
/>
<result
property=
"decision"
column=
"decision"
jdbcType=
"VARCHAR"
/>
<result
property=
"comment"
column=
"comment"
jdbcType=
"VARCHAR"
/>
<result
property=
"decisionTime"
column=
"decision_time"
jdbcType=
"TIMESTAMP"
/>
<result
property=
"name"
column=
"name"
jdbcType=
"VARCHAR"
/>
</resultMap>
<sql
id=
"Base_Column_List"
>
...
...
@@ -18,6 +21,7 @@
decision_time,name
</sql>
<select
id=
"findListByTaskId"
resultType=
"com.ruoyi.domain.ReviewSceneChangeTaskUserRelation"
>
SELECT id, task_id, user_id, decision, decision_time, name FROM t_review_scene_change_task_user_relation WHERE task_id = #{taskId}
SELECT id, task_id, user_id, decision, decision_time, name, role_id, comment, dept FROM t_review_scene_change_task_user_relation
WHERE task_id = #{taskId}
</select>
</mapper>
quality-review/src/main/resources/mapper/ReviewStandardMapper.xml
View file @
553ab27f
...
...
@@ -44,7 +44,9 @@
id,
chapter,
text,
test_method AS testMethod
test_method AS testMethod,
name,
standard_no AS standardNo
from
t_review_standard
<where>
...
...
@@ -53,6 +55,8 @@
<if
test=
"chapter != null and chapter != ''"
>
and chapter like concat('%', #{chapter}, '%')
</if>
<if
test=
"text != null and text != ''"
>
and text like concat('%', #{text}, '%')
</if>
<if
test=
"testMethod != null and testMethod != ''"
>
and test_method like concat('%', #{testMethod}, '%')
</if>
<if
test=
"name != null and text != ''"
>
and name like concat('%',#{name}, '%')
</if>
<if
test=
"standardNo != null and standardNo != ''"
>
and standard_no like concat('%',#{standardNo},'%')
</if>
</where>
ORDER BY
chapter
...
...
@@ -95,4 +99,5 @@
</select>
</mapper>
ruoyi-system/src/main/java/com/ruoyi/system/mapper/SysUserRoleMapper.java
View file @
553ab27f
...
...
@@ -3,17 +3,19 @@ package com.ruoyi.system.mapper;
import
java.util.List
;
import
org.apache.ibatis.annotations.Param
;
import
com.ruoyi.system.domain.SysUserRole
;
import
org.springframework.stereotype.Repository
;
/**
* 用户与角色关联表 数据层
*
*
* @author ruoyi
*/
@Repository
public
interface
SysUserRoleMapper
{
/**
* 通过用户ID删除用户和角色关联
*
*
* @param userId 用户ID
* @return 结果
*/
...
...
@@ -21,7 +23,7 @@ public interface SysUserRoleMapper
/**
* 批量删除用户和角色关联
*
*
* @param ids 需要删除的数据ID
* @return 结果
*/
...
...
@@ -29,7 +31,7 @@ public interface SysUserRoleMapper
/**
* 通过角色ID查询角色使用数量
*
*
* @param roleId 角色ID
* @return 结果
*/
...
...
@@ -37,7 +39,7 @@ public interface SysUserRoleMapper
/**
* 批量新增用户角色信息
*
*
* @param userRoleList 用户角色列表
* @return 结果
*/
...
...
@@ -45,7 +47,7 @@ public interface SysUserRoleMapper
/**
* 删除用户和角色关联信息
*
*
* @param userRole 用户和角色关联信息
* @return 结果
*/
...
...
@@ -53,10 +55,15 @@ public interface SysUserRoleMapper
/**
* 批量取消授权用户角色
*
*
* @param roleId 角色ID
* @param userIds 需要删除的用户数据ID
* @return 结果
*/
public
int
deleteUserRoleInfos
(
@Param
(
"roleId"
)
Long
roleId
,
@Param
(
"userIds"
)
Long
[]
userIds
);
/*
*根据roleId查询审核员Id
* */
List
<
Long
>
selectReviewerIdByRoleId
(
Long
roleId
);
}
ruoyi-system/src/main/resources/mapper/system/SysUserRoleMapper.xml
View file @
553ab27f
...
...
@@ -12,33 +12,37 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<delete
id=
"deleteUserRoleByUserId"
parameterType=
"Long"
>
delete from sys_user_role where user_id=#{userId}
</delete>
<select
id=
"countUserRoleByRoleId"
resultType=
"Integer"
>
select count(1) from sys_user_role where role_id=#{roleId}
select count(1) from sys_user_role where role_id=#{roleId}
</select>
<select
id=
"selectReviewerIdByRoleId"
resultType=
"java.lang.Long"
>
select user_id from sys_user_role where role_id = #{roleId}
</select>
<delete
id=
"deleteUserRole"
parameterType=
"Long"
>
<delete
id=
"deleteUserRole"
parameterType=
"Long"
>
delete from sys_user_role where user_id in
<foreach
collection=
"array"
item=
"userId"
open=
"("
separator=
","
close=
")"
>
#{userId}
</foreach>
</foreach>
</delete>
<insert
id=
"batchUserRole"
>
insert into sys_user_role(user_id, role_id) values
<foreach
item=
"item"
index=
"index"
collection=
"list"
separator=
","
>
(#{item.userId},#{item.roleId})
</foreach>
</insert>
<delete
id=
"deleteUserRoleInfo"
parameterType=
"SysUserRole"
>
delete from sys_user_role where user_id=#{userId} and role_id=#{roleId}
</delete>
<delete
id=
"deleteUserRoleInfos"
>
delete from sys_user_role where role_id=#{roleId} and user_id in
<foreach
collection=
"userIds"
item=
"userId"
open=
"("
separator=
","
close=
")"
>
#{userId}
</foreach>
</foreach>
</delete>
</mapper>
\ No newline at end of file
</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