Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
R
RuoYi-Vue-master
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
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
融通安全管理系统
RuoYi-Vue-master
Commits
3bdfe6b7
Commit
3bdfe6b7
authored
Jul 08, 2023
by
周昊
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1、修改获取固有风险列表问题
2、详情接口添加字段
parent
99caf090
Changes
9
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
36 additions
and
13 deletions
+36
-13
censoft-rongtong/src/main/java/com/censoft/censoftrongtong/controller/RiskPlanAppController.java
...oft/censoftrongtong/controller/RiskPlanAppController.java
+12
-0
censoft-rongtong/src/main/java/com/censoft/censoftrongtong/domain/dto/RiskPlanAppDetailsDto.java
...oft/censoftrongtong/domain/dto/RiskPlanAppDetailsDto.java
+3
-0
censoft-rongtong/src/main/java/com/censoft/censoftrongtong/domain/dto/RiskPlanAppTaskDetailsDto.java
...censoftrongtong/domain/dto/RiskPlanAppTaskDetailsDto.java
+5
-2
censoft-rongtong/src/main/java/com/censoft/censoftrongtong/mapper/RiskPlanInherentListMapper.java
...ft/censoftrongtong/mapper/RiskPlanInherentListMapper.java
+1
-1
censoft-rongtong/src/main/java/com/censoft/censoftrongtong/service/IRiskPlanInherentListService.java
...censoftrongtong/service/IRiskPlanInherentListService.java
+1
-1
censoft-rongtong/src/main/java/com/censoft/censoftrongtong/service/impl/RiskPlanInherentListServiceImpl.java
...ongtong/service/impl/RiskPlanInherentListServiceImpl.java
+2
-2
censoft-rongtong/src/main/java/com/censoft/censoftrongtong/service/impl/RiskPlanServiceImpl.java
...oft/censoftrongtong/service/impl/RiskPlanServiceImpl.java
+7
-4
censoft-rongtong/src/main/resources/mapper/system/RiskPlanInherentListMapper.xml
...in/resources/mapper/system/RiskPlanInherentListMapper.xml
+2
-1
censoft-rongtong/src/main/resources/mapper/system/RiskPlanMapper.xml
...gtong/src/main/resources/mapper/system/RiskPlanMapper.xml
+3
-2
No files found.
censoft-rongtong/src/main/java/com/censoft/censoftrongtong/controller/RiskPlanAppController.java
View file @
3bdfe6b7
...
...
@@ -312,6 +312,18 @@ public class RiskPlanAppController extends BaseController {
return
R
.
ok
(
riskPlanInherentListService
.
getInherentListByPlanId
(
null
,
buildingId
,
floorId
,
roomId
));
}
/**
* 根据计划id、楼宇id、楼层id、房间id获取固有风险列表
*
* @param planId 计划id
* @real_return {@link R<List<RiskPlanAppInherentListDto>>}
*/
@GetMapping
(
"/inherent/list/{planId}"
)
public
R
<
List
<
RiskPlanAppInherentListDto
>>
getInherentListByPlanId
(
@PathVariable
(
"planId"
)
Long
planId
)
{
RiskPlan
riskPlan
=
riskPlanService
.
selectRiskPlanById
(
planId
);
return
R
.
ok
(
riskPlanInherentListService
.
getInherentListByPlanId
(
riskPlan
.
getProjectId
(),
null
,
null
,
null
));
}
/**
* 添加固有风险
*
...
...
censoft-rongtong/src/main/java/com/censoft/censoftrongtong/domain/dto/RiskPlanAppDetailsDto.java
View file @
3bdfe6b7
...
...
@@ -43,6 +43,9 @@ public class RiskPlanAppDetailsDto {
/** 任务详情 */
private
RiskPlanAppTaskDetailsDto
detailsDto
;
/** 风险清单 */
private
List
<
RiskPlanAppInherentListDto
>
inherentListDtos
;
/** 风险清单 */
private
List
<
RiskPlanAppRiskBuildingListDto
>
riskBuildingListDtos
;
...
...
censoft-rongtong/src/main/java/com/censoft/censoftrongtong/domain/dto/RiskPlanAppTaskDetailsDto.java
View file @
3bdfe6b7
...
...
@@ -17,6 +17,9 @@ public class RiskPlanAppTaskDetailsDto {
/** id */
private
Long
id
;
/** 任务名称 */
private
String
name
;
/** 任务编号 */
private
String
no
;
...
...
@@ -42,10 +45,10 @@ public class RiskPlanAppTaskDetailsDto {
private
String
projectName
;
/** 所属单位id */
private
Long
projectD
eptId
;
private
Long
d
eptId
;
/** 所属单位 */
private
String
projectD
eptName
;
private
String
d
eptName
;
/** 所在城市 */
private
String
city
;
...
...
censoft-rongtong/src/main/java/com/censoft/censoftrongtong/mapper/RiskPlanInherentListMapper.java
View file @
3bdfe6b7
...
...
@@ -64,7 +64,7 @@ public interface RiskPlanInherentListMapper
*/
public
int
deleteRiskPlanInherentListByIds
(
Long
[]
ids
);
List
<
RiskPlanAppInherentListDto
>
getInherentListByPlanId
(
@Param
(
"p
lanId"
)
Long
plan
Id
,
@Param
(
"buildingId"
)
Long
buildingId
,
@Param
(
"floorId"
)
Long
floorId
,
@Param
(
"roomId"
)
Long
roomId
);
List
<
RiskPlanAppInherentListDto
>
getInherentListByPlanId
(
@Param
(
"p
rojectId"
)
Long
project
Id
,
@Param
(
"buildingId"
)
Long
buildingId
,
@Param
(
"floorId"
)
Long
floorId
,
@Param
(
"roomId"
)
Long
roomId
);
RiskPlanAppInherentListDetailsDto
getRiskPlanAppInherentListDetailsDtoByInherentId
(
@Param
(
"inherentId"
)
Long
inherentId
);
...
...
censoft-rongtong/src/main/java/com/censoft/censoftrongtong/service/IRiskPlanInherentListService.java
View file @
3bdfe6b7
...
...
@@ -64,7 +64,7 @@ public interface IRiskPlanInherentListService
*/
public
int
deleteRiskPlanInherentListById
(
Long
id
);
List
<
RiskPlanAppInherentListDto
>
getInherentListByPlanId
(
Long
p
lan
Id
,
Long
buildingId
,
Long
floorId
,
Long
roomId
);
List
<
RiskPlanAppInherentListDto
>
getInherentListByPlanId
(
Long
p
roject
Id
,
Long
buildingId
,
Long
floorId
,
Long
roomId
);
Integer
saveRiskInherentListSaveDto
(
RiskInherentListSaveDto
saveDto
);
...
...
censoft-rongtong/src/main/java/com/censoft/censoftrongtong/service/impl/RiskPlanInherentListServiceImpl.java
View file @
3bdfe6b7
...
...
@@ -241,8 +241,8 @@ public class RiskPlanInherentListServiceImpl implements IRiskPlanInherentListSer
}
@Override
public
List
<
RiskPlanAppInherentListDto
>
getInherentListByPlanId
(
Long
p
lan
Id
,
Long
buildingId
,
Long
floorId
,
Long
roomId
)
{
return
riskPlanInherentListMapper
.
getInherentListByPlanId
(
p
lan
Id
,
buildingId
,
floorId
,
roomId
);
public
List
<
RiskPlanAppInherentListDto
>
getInherentListByPlanId
(
Long
p
roject
Id
,
Long
buildingId
,
Long
floorId
,
Long
roomId
)
{
return
riskPlanInherentListMapper
.
getInherentListByPlanId
(
p
roject
Id
,
buildingId
,
floorId
,
roomId
);
}
@Override
...
...
censoft-rongtong/src/main/java/com/censoft/censoftrongtong/service/impl/RiskPlanServiceImpl.java
View file @
3bdfe6b7
...
...
@@ -13,10 +13,7 @@ import com.censoft.censoftrongtong.domain.dto.RiskPlanAppDetailsDto;
import
com.censoft.censoftrongtong.domain.dto.RiskPlanAppListDto
;
import
com.censoft.censoftrongtong.enums.RiskPlanStatusType
;
import
com.censoft.censoftrongtong.mapper.RiskPlanMapper
;
import
com.censoft.censoftrongtong.service.ILedgerBuildingService
;
import
com.censoft.censoftrongtong.service.IRiskPlanService
;
import
com.censoft.censoftrongtong.service.IRiskPlanTaskService
;
import
com.censoft.censoftrongtong.service.IRiskPlanUserBuildingService
;
import
com.censoft.censoftrongtong.service.*
;
import
com.ruoyi.common.utils.DateUtils
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
...
...
@@ -43,6 +40,9 @@ public class RiskPlanServiceImpl implements IRiskPlanService {
@Resource
private
IRiskPlanUserBuildingService
riskPlanUserBuildingService
;
@Resource
private
IRiskPlanInherentListService
riskPlanInherentListService
;
/**
* 查询风险计划
*
...
...
@@ -187,6 +187,9 @@ public class RiskPlanServiceImpl implements IRiskPlanService {
dto
.
getDetailsDto
().
setBuildingNames
(
ledgerBuilding
.
getName
());
}
//风险清单
dto
.
setInherentListDtos
(
riskPlanInherentListService
.
getInherentListByPlanId
(
null
,
buildingId
,
null
,
null
));
//风险清单
dto
.
setRiskBuildingListDtos
(
riskPlanMapper
.
getRiskBuildingListDtoByPlanId
(
planId
,
buildingId
));
...
...
censoft-rongtong/src/main/resources/mapper/system/RiskPlanInherentListMapper.xml
View file @
3bdfe6b7
...
...
@@ -87,8 +87,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
LEFT JOIN ledger_room lr ON lr.id = rpil.room_id
LEFT JOIN ledger_floor lf ON lf.id = floor_id
LEFT JOIN sys_user su ON su.user_id = rpil.user_id
LEFT JOIN ledger_building lb ON lb.id = lf.building_id
<where>
<if
test=
"p
lanId != null"
>
AND rpil.plan_id = #{plan
Id}
</if>
<if
test=
"p
rojectId != null"
>
AND lb.project_id = #{project
Id}
</if>
<if
test=
"buildingId != null"
>
AND lf.building_id = #{buildingId}
</if>
<if
test=
"floorId != null"
>
AND lf.id = #{floorId}
</if>
<if
test=
"roomId != null"
>
AND lr.id = #{roomId}
</if>
...
...
censoft-rongtong/src/main/resources/mapper/system/RiskPlanMapper.xml
View file @
3bdfe6b7
...
...
@@ -101,6 +101,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
SELECT
rp.id,
rp.`no`,
rp.`name`,
su1.user_id AS createUserId,
su1.nick_name AS createUserName,
sd1.dept_id AS createDeptId,
...
...
@@ -108,8 +109,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
rp.create_time AS createTime,
lp.id AS projectId,
lp.`name` AS projectName,
sd2.dept_id AS
projectD
eptId,
sd2.dept_name AS
projectD
eptName,
sd2.dept_id AS
d
eptId,
sd2.dept_name AS
d
eptName,
lp.city,
rp.building_ids AS buildingIds,
( SELECT GROUP_CONCAT( `name` ) FROM ledger_building WHERE project_id = lp.id ) AS buildingNames,
...
...
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