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
b003423c
Commit
b003423c
authored
Aug 22, 2024
by
yuanshuo
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
新增细则、要点代码补充
parent
69afec74
Changes
15
Hide whitespace changes
Inline
Side-by-side
Showing
15 changed files
with
125 additions
and
10 deletions
+125
-10
ReviewKeyPointMapper.java
.../src/main/java/com/ruoyi/mapper/ReviewKeyPointMapper.java
+6
-0
ReviewSceneChangeTaskService.java
.../java/com/ruoyi/service/ReviewSceneChangeTaskService.java
+13
-0
ReviewStandardService.java
...rc/main/java/com/ruoyi/service/ReviewStandardService.java
+0
-1
ReviewSceneChangeTaskServiceImpl.java
.../ruoyi/service/impl/ReviewSceneChangeTaskServiceImpl.java
+20
-1
StrategyReviewSceneChangeAdd.java
.../com/ruoyi/service/impl/StrategyReviewSceneChangeAdd.java
+13
-0
ReviewSceneChangeTaskController.java
...n/java/com/ruoyi/web/ReviewSceneChangeTaskController.java
+36
-2
ReviewStandardController.java
...src/main/java/com/ruoyi/web/ReviewStandardController.java
+0
-1
ReviewSceneChangeTaskGetInfoRequest.java
...uoyi/web/request/ReviewSceneChangeTaskGetInfoRequest.java
+5
-1
ReviewStandardListByPageRequest.java
...om/ruoyi/web/request/ReviewStandardListByPageRequest.java
+7
-0
ReviewSceneChangeTaskResponse.java
...com/ruoyi/web/response/ReviewSceneChangeTaskResponse.java
+2
-2
ReviewStandardResponse.java
...n/java/com/ruoyi/web/response/ReviewStandardResponse.java
+6
-0
ReviewKeyPointMapper.xml
...review/src/main/resources/mapper/ReviewKeyPointMapper.xml
+8
-0
ReviewSceneChangeTaskMapper.xml
...src/main/resources/mapper/ReviewSceneChangeTaskMapper.xml
+1
-1
ReviewStandardMapper.xml
...review/src/main/resources/mapper/ReviewStandardMapper.xml
+6
-1
SysUserRoleMapper.java
.../main/java/com/ruoyi/system/mapper/SysUserRoleMapper.java
+2
-0
No files found.
quality-review/src/main/java/com/ruoyi/mapper/ReviewKeyPointMapper.java
View file @
b003423c
...
...
@@ -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/service/ReviewSceneChangeTaskService.java
View file @
b003423c
...
...
@@ -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
;
...
...
@@ -102,4 +104,15 @@ public interface ReviewSceneChangeTaskService extends IService<ReviewSceneChange
* @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 @
b003423c
...
...
@@ -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/ReviewSceneChangeTaskServiceImpl.java
View file @
b003423c
...
...
@@ -9,6 +9,7 @@ import com.ruoyi.common.utils.SecurityUtils;
import
com.ruoyi.domain.ReviewSceneChangeTask
;
import
com.ruoyi.domain.ReviewSceneChangeTaskUserRelation
;
import
com.ruoyi.framework.web.domain.server.Sys
;
import
com.ruoyi.mapper.ReviewKeyPointMapper
;
import
com.ruoyi.service.ReviewSceneChangeTaskService
;
import
com.ruoyi.mapper.ReviewSceneChangeTaskMapper
;
import
com.ruoyi.service.ReviewSceneChangeTaskUserRelationService
;
...
...
@@ -20,6 +21,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
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
...
...
@@ -57,6 +60,8 @@ public class ReviewSceneChangeTaskServiceImpl extends ServiceImpl<ReviewSceneCha
@Autowired
private
SysUserRoleMapper
sysUserRoleMapper
;
@Autowired
private
ReviewKeyPointMapper
reviewKeyPointMapper
;
@Override
public
void
create
(
ReviewSceneChangeTask
reviewSceneChangeTask
)
{
...
...
@@ -406,7 +411,6 @@ public class ReviewSceneChangeTaskServiceImpl extends ServiceImpl<ReviewSceneCha
throw
new
ServiceException
(
"审核状态不正确"
,
HttpStatus
.
ERROR
);
}
}
/**
* 创新基地评审任务
* @param taskId
...
...
@@ -450,6 +454,21 @@ public class ReviewSceneChangeTaskServiceImpl extends ServiceImpl<ReviewSceneCha
}
/*
* 发起评审-新增审查场景-获取要点列表
* */
@Override
public
List
<
ReviewKeyPointListResponse
>
getKeyPointList
(
Long
standardId
)
{
return
reviewKeyPointMapper
.
getKeyPointList
(
standardId
);
}
/*
* 发起评审-新增审查场景-获取细则列表
* */
@Override
public
List
<
ReviewDetailsListResponse
>
getDetailsList
(
Long
keyPointId
)
{
return
reviewKeyPointMapper
.
getDetailsList
(
keyPointId
);
}
}
...
...
quality-review/src/main/java/com/ruoyi/service/impl/StrategyReviewSceneChangeAdd.java
View file @
b003423c
...
...
@@ -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/web/ReviewSceneChangeTaskController.java
View file @
b003423c
...
...
@@ -6,12 +6,16 @@ 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
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiOperation
;
import
org.apache.skywalking.apm.toolkit.trace.Tag
;
...
...
@@ -22,6 +26,8 @@ import org.springframework.beans.factory.annotation.Autowired;
import
org.springframework.validation.annotation.Validated
;
import
org.springframework.web.bind.annotation.*
;
import
java.util.List
;
@Api
(
tags
=
"场景变更任务"
)
@RestController
@RequestMapping
(
"/review/scene/change/task"
)
...
...
@@ -100,7 +106,8 @@ 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
.
getBySceneChangeTaskId
(
request
.
getId
()));
Long
id
=
Long
.
parseLong
(
request
.
getId
());
return
R
.
ok
(
reviewSceneChangeTaskService
.
getBySceneChangeTaskId
(
id
));
}
/**
...
...
@@ -138,7 +145,8 @@ public class ReviewSceneChangeTaskController extends BaseController {
@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
)
{
return
R
.
ok
(
reviewSceneChangeTaskService
.
getBySceneChange
(
request
.
getId
()));
Long
id
=
Long
.
parseLong
(
request
.
getId
());
return
R
.
ok
(
reviewSceneChangeTaskService
.
getBySceneChange
(
id
));
}
/**
...
...
@@ -155,4 +163,30 @@ public class ReviewSceneChangeTaskController extends BaseController {
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 @
b003423c
...
...
@@ -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/request/ReviewSceneChangeTaskGetInfoRequest.java
View file @
b003423c
...
...
@@ -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 @
b003423c
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/ReviewSceneChangeTaskResponse.java
View file @
b003423c
...
...
@@ -13,10 +13,10 @@ import java.util.Date;
public
class
ReviewSceneChangeTaskResponse
{
/**
* 主键
* 主键
由于主键太长返回给前端时会造成数据不对问题,这里将id改为String类型。
*/
@ApiModelProperty
(
"主键"
)
private
Lo
ng
id
;
private
Stri
ng
id
;
/**
* 任务编号
...
...
quality-review/src/main/java/com/ruoyi/web/response/ReviewStandardResponse.java
View file @
b003423c
...
...
@@ -35,4 +35,10 @@ public class ReviewStandardResponse {
@ApiModelProperty
(
"测试方法(车型试验专有)"
)
private
String
testMethod
;
@ApiModelProperty
(
"标准名称"
)
private
String
name
;
@ApiModelProperty
(
"标准号"
)
private
String
standardNo
;
}
quality-review/src/main/resources/mapper/ReviewKeyPointMapper.xml
View file @
b003423c
...
...
@@ -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 @
b003423c
...
...
@@ -98,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>
...
...
quality-review/src/main/resources/mapper/ReviewStandardMapper.xml
View file @
b003423c
...
...
@@ -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 @
b003423c
...
...
@@ -3,12 +3,14 @@ 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
{
/**
...
...
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