修改数据查询
This commit is contained in:
parent
93d683a9a9
commit
770ac561af
|
|
@ -43,6 +43,8 @@ public class OperatingQualityVo {
|
||||||
@ApiModelProperty(value = "区域名称")
|
@ApiModelProperty(value = "区域名称")
|
||||||
private String createTime;
|
private String createTime;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "单位")
|
||||||
|
private String unit;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -40,9 +40,11 @@ public class TowerAssInspectVo {
|
||||||
@ApiModelProperty("累计变化值")
|
@ApiModelProperty("累计变化值")
|
||||||
private String changeVal;
|
private String changeVal;
|
||||||
|
|
||||||
@ApiModelProperty("检测时间")
|
|
||||||
private String updateTime;
|
private String updateTime;
|
||||||
|
|
||||||
|
@ApiModelProperty("检测时间")
|
||||||
|
private String createTime;
|
||||||
|
|
||||||
@ApiModelProperty("状态")
|
@ApiModelProperty("状态")
|
||||||
private String isWarn;
|
private String isWarn;
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -46,6 +46,7 @@ public class OperatingController extends BaseController {
|
||||||
|
|
||||||
@RequestMapping(value = "/FiniteSpace", method = RequestMethod.POST)
|
@RequestMapping(value = "/FiniteSpace", method = RequestMethod.POST)
|
||||||
@ApiOperation(value = "作业环境-有限空间检测设备查询")
|
@ApiOperation(value = "作业环境-有限空间检测设备查询")
|
||||||
|
@Log(title = "作业环境", menu = "作业环境->有限空间检测设备查询", grade = OperationType.QUERY_BUSINESS, details = "有限空间检测设备查询", type = "业务日志")
|
||||||
public AjaxResult getFiniteSpace(@RequestBody OperatingQualityDto dto) {
|
public AjaxResult getFiniteSpace(@RequestBody OperatingQualityDto dto) {
|
||||||
try {
|
try {
|
||||||
List<OperatingQualityVo> list = service.getFiniteSpace(dto);
|
List<OperatingQualityVo> list = service.getFiniteSpace(dto);
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,8 @@
|
||||||
package com.securitycontrol.screen.controller;
|
package com.securitycontrol.screen.controller;
|
||||||
|
|
||||||
import com.securitycontrol.common.core.web.domain.AjaxResult;
|
import com.securitycontrol.common.core.web.domain.AjaxResult;
|
||||||
|
import com.securitycontrol.common.log.annotation.Log;
|
||||||
|
import com.securitycontrol.common.log.enums.OperationType;
|
||||||
import com.securitycontrol.entity.screen.dto.ScreenParamDto;
|
import com.securitycontrol.entity.screen.dto.ScreenParamDto;
|
||||||
import com.securitycontrol.screen.service.IScIndexService;
|
import com.securitycontrol.screen.service.IScIndexService;
|
||||||
import io.swagger.annotations.ApiOperation;
|
import io.swagger.annotations.ApiOperation;
|
||||||
|
|
@ -25,6 +27,7 @@ public class ScIndexController {
|
||||||
|
|
||||||
@ApiOperation(value = "工程统计")
|
@ApiOperation(value = "工程统计")
|
||||||
@GetMapping("proStatusStatistics")
|
@GetMapping("proStatusStatistics")
|
||||||
|
@Log(title = "省侧施工大屏", menu = "省侧施工大屏->首页", grade = OperationType.QUERY_BUSINESS, details = "省侧施工大屏展示", type = "业务日志")
|
||||||
public AjaxResult proStatusStatistics(ScreenParamDto dto){
|
public AjaxResult proStatusStatistics(ScreenParamDto dto){
|
||||||
return service.proStatusStatistics(dto);
|
return service.proStatusStatistics(dto);
|
||||||
}
|
}
|
||||||
|
|
@ -35,12 +38,16 @@ public class ScIndexController {
|
||||||
return service.riskStatistics(dto);
|
return service.riskStatistics(dto);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ApiOperation(value = "施工质量")
|
@ApiOperation(value = "施工质量")
|
||||||
@GetMapping("constrQuality")
|
@GetMapping("constrQuality")
|
||||||
public AjaxResult constrQuality(ScreenParamDto dto){
|
public AjaxResult constrQuality(ScreenParamDto dto){
|
||||||
return service.constrQuality(dto);
|
return service.constrQuality(dto);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@ApiOperation(value = "告警提醒")
|
@ApiOperation(value = "告警提醒")
|
||||||
@GetMapping("alarmReminder")
|
@GetMapping("alarmReminder")
|
||||||
public AjaxResult alarmReminder(ScreenParamDto dto){
|
public AjaxResult alarmReminder(ScreenParamDto dto){
|
||||||
|
|
@ -80,6 +87,6 @@ public class ScIndexController {
|
||||||
@ApiOperation(value = "杆塔集合查询")
|
@ApiOperation(value = "杆塔集合查询")
|
||||||
@GetMapping("getGtList")
|
@GetMapping("getGtList")
|
||||||
public AjaxResult getGtList(ScreenParamDto dto){
|
public AjaxResult getGtList(ScreenParamDto dto){
|
||||||
return service.efficiencyAnalysis(dto);
|
return service.getGtList(dto);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -107,4 +107,11 @@ public interface IScIndexService {
|
||||||
* @date 2024/3/28 13:39
|
* @date 2024/3/28 13:39
|
||||||
*/
|
*/
|
||||||
AjaxResult efficiencyAnalysis(ScreenParamDto dto);
|
AjaxResult efficiencyAnalysis(ScreenParamDto dto);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 省侧施工大屏 展示
|
||||||
|
* @param dto
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
AjaxResult getGtList(ScreenParamDto dto);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -330,4 +330,10 @@ public class ScIndexServiceImpl implements IScIndexService {
|
||||||
}
|
}
|
||||||
return AjaxResult.success(dataList);
|
return AjaxResult.success(dataList);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public AjaxResult getGtList(ScreenParamDto dto) {
|
||||||
|
|
||||||
|
return null;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -57,7 +57,9 @@
|
||||||
</select>
|
</select>
|
||||||
<select id="getConstructionQualityList"
|
<select id="getConstructionQualityList"
|
||||||
resultType="com.securitycontrol.entity.screen.vo.ConstructionQualityVo">
|
resultType="com.securitycontrol.entity.screen.vo.ConstructionQualityVo">
|
||||||
SELECT tbd.device_name deviceName,tdd.mode_name moduleName,tdv.val,tdv.change_val,ta.area_name areaName,
|
SELECT tbd.device_name deviceName,tdd.mode_name moduleName,
|
||||||
|
concat(tdv.val,'(',tdv.unit,')') val,
|
||||||
|
tdv.change_val changeVal,ta.area_name areaName,
|
||||||
tpb.bd_name ,tdv.create_time createTime,tdv.is_warn isWarn
|
tpb.bd_name ,tdv.create_time createTime,tdv.is_warn isWarn
|
||||||
FROM tb_bd_device tbd
|
FROM tb_bd_device tbd
|
||||||
LEFT JOIN tb_area ta on tbd.area_id=ta.area_id
|
LEFT JOIN tb_area ta on tbd.area_id=ta.area_id
|
||||||
|
|
|
||||||
|
|
@ -4,15 +4,15 @@
|
||||||
|
|
||||||
<!--作业环境-实时监测-->
|
<!--作业环境-实时监测-->
|
||||||
<select id="getRealTimeMonitoring" resultType="com.securitycontrol.entity.screen.vo.OperatingQualityVo">
|
<select id="getRealTimeMonitoring" resultType="com.securitycontrol.entity.screen.vo.OperatingQualityVo">
|
||||||
SELECT
|
SELECT
|
||||||
tdd.data_type as dataType,
|
tdd.mode_name as dataType,
|
||||||
tdv.val as val,
|
tdv.val as val, tdv.unit,
|
||||||
tdv.is_warn as isWarn
|
tdv.is_warn as isWarn
|
||||||
FROM tb_device_detail tdd
|
FROM tb_device_detail tdd
|
||||||
LEFT JOIN tb_device_value tdv ON tdd.id = tdv.attribute_id
|
LEFT JOIN tb_device_value tdv ON tdd.id = tdv.attribute_id
|
||||||
LEFT JOIN tb_bd_device tbd ON tdd.device_id = tbd.device_id
|
LEFT JOIN tb_bd_device tbd ON tdd.device_id = tbd.device_id
|
||||||
LEFT JOIN tb_pro_bd tpb ON tbd.bd_id = tpb.id
|
LEFT JOIN tb_pro_bd tpb ON tbd.bd_id = tpb.id
|
||||||
WHERE tpb.bid_code = #{bidCode}
|
WHERE tpb.bid_code = #{bidCode} and tbd.device_code='1902001'
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<!--作业环境-有限空间监测-->
|
<!--作业环境-有限空间监测-->
|
||||||
|
|
@ -23,24 +23,31 @@
|
||||||
tbd.status AS status
|
tbd.status AS status
|
||||||
FROM
|
FROM
|
||||||
tb_bd_device tbd
|
tb_bd_device tbd
|
||||||
LEFT JOIN
|
LEFT JOIN tb_pro_bd tpb ON tpb.id = tbd.bd_id
|
||||||
tb_pro_bd tpb ON tpb.bid_code = #{bidCode} AND tpb.id = tbd.bd_id
|
WHERE tbd.devic_type = 1909 and tpb.bid_code = #{bidCode}
|
||||||
WHERE
|
|
||||||
tbd.devic_type = 1902 and tbd.device_code = 1902003
|
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<!--作业环境-边坡位移监测设备-->
|
<!--作业环境-边坡位移监测设备-->
|
||||||
<select id="getSlopeDisplacement" resultType="com.securitycontrol.entity.screen.vo.OperatingQualityVo">
|
<select id="getSlopeDisplacement" resultType="com.securitycontrol.entity.screen.vo.OperatingQualityVo">
|
||||||
SELECT
|
SELECT
|
||||||
tbd.device_id AS id,
|
ta.area_name AS areaName,
|
||||||
tbd.device_name AS deviceName,
|
tdd.mode_name modeName,
|
||||||
tbd.status AS status
|
tbd.device_name AS deviceName,
|
||||||
FROM
|
thdv.val AS val,
|
||||||
tb_bd_device tbd
|
thdv.change_val AS changeVal,
|
||||||
LEFT JOIN
|
thdv.create_time AS createTime,
|
||||||
tb_pro_bd tpb ON tpb.bid_code = #{bidCode} AND tpb.id = tbd.bd_id
|
thdv.unit,
|
||||||
WHERE
|
thdv.is_warn AS isWarn
|
||||||
tbd.devic_type = 1902 and tbd.device_code = 1902001
|
FROM tb_bd_device tbd
|
||||||
|
LEFT JOIN tb_device_detail tdd ON tbd.device_id = tdd.device_id
|
||||||
|
LEFT JOIN tb_area ta ON tbd.area_id = ta.area_id
|
||||||
|
LEFT JOIN tb_device_value thdv ON tdd.id = thdv.attribute_id
|
||||||
|
LEFT JOIN tb_pro_bd tpb ON tbd.bd_id = tpb.id
|
||||||
|
WHERE tbd.devic_type = 1908 and tpb.bid_code = #{bidCode}
|
||||||
|
<if test="deviceId!=null and deviceId!=''">
|
||||||
|
and tbd.device_id=#{deviceId}
|
||||||
|
</if>
|
||||||
|
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<!--作业环境-GPS安装检测-->
|
<!--作业环境-GPS安装检测-->
|
||||||
|
|
@ -52,39 +59,40 @@
|
||||||
FROM
|
FROM
|
||||||
tb_bd_device tbd
|
tb_bd_device tbd
|
||||||
LEFT JOIN
|
LEFT JOIN
|
||||||
tb_pro_bd tpb ON tpb.bid_code = #{bidCode} AND tpb.id = tbd.bd_id
|
tb_pro_bd tpb ON tpb.id = tbd.bd_id
|
||||||
WHERE
|
WHERE
|
||||||
tbd.devic_type = 1902 and tbd.device_code = 1902004
|
tbd.devic_type = 1910 and tpb.bid_code = #{bidCode}
|
||||||
|
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<!--作业环境-有限空间检测环境-->
|
<!--作业环境-有限空间检测环境-->
|
||||||
<select id="getFiniteSpaceEnvironment"
|
<select id="getFiniteSpaceEnvironment"
|
||||||
resultType="com.securitycontrol.entity.screen.vo.OperatingQualityVo">
|
resultType="com.securitycontrol.entity.screen.vo.OperatingQualityVo">
|
||||||
SELECT
|
SELECT
|
||||||
tdv.val AS val,
|
concat(tdv.val,'(',tdv.unit,')') val,
|
||||||
tdd.mode_name AS modeName
|
tdv.unit,
|
||||||
|
tdd.mode_name AS modeName
|
||||||
FROM tb_device_detail tdd
|
FROM tb_device_detail tdd
|
||||||
LEFT JOIN tb_device_value tdv ON tdd.id = tdv.attribute_id
|
LEFT JOIN tb_device_value tdv ON tdd.id = tdv.attribute_id
|
||||||
LEFT JOIN tb_bd_device tbd on tdd.device_id = tbd.device_id
|
LEFT JOIN tb_bd_device tbd on tdd.device_id = tbd.device_id
|
||||||
LEFT JOIN tb_pro_bd tpb on tbd.bd_id = tpb.id
|
LEFT JOIN tb_pro_bd tpb on tbd.bd_id = tpb.id
|
||||||
WHERE tpb.bid_code = #{bidCode}
|
WHERE tbd.devic_type =1909
|
||||||
AND tbd.device_id = #{deviceId}
|
and tpb.bid_code = #{bidCode}
|
||||||
GROUP BY tdd.mode_name
|
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<!--作业环境-GPS安装检测设备查询-->
|
<!--作业环境-GPS安装检测设备查询-->
|
||||||
<select id="getGisInstallationEnvironment"
|
<select id="getGisInstallationEnvironment"
|
||||||
resultType="com.securitycontrol.entity.screen.vo.OperatingQualityVo">
|
resultType="com.securitycontrol.entity.screen.vo.OperatingQualityVo">
|
||||||
SELECT
|
SELECT
|
||||||
tdv.val AS val,
|
concat(tdv.val,'(',tdv.unit,')') val,
|
||||||
|
tdv.unit,
|
||||||
tdd.mode_name AS modeName
|
tdd.mode_name AS modeName
|
||||||
FROM tb_device_detail tdd
|
FROM tb_device_detail tdd
|
||||||
LEFT JOIN tb_device_value tdv ON tdd.id = tdv.attribute_id
|
LEFT JOIN tb_device_value tdv ON tdd.id = tdv.attribute_id
|
||||||
LEFT JOIN tb_bd_device tbd on tdd.device_id = tbd.device_id
|
LEFT JOIN tb_bd_device tbd on tdd.device_id = tbd.device_id
|
||||||
LEFT JOIN tb_pro_bd tpb on tbd.bd_id = tpb.id
|
LEFT JOIN tb_pro_bd tpb on tbd.bd_id = tpb.id
|
||||||
WHERE tpb.bid_code = #{bidCode}
|
WHERE tbd.devic_type =1910
|
||||||
AND tbd.device_id = #{deviceId}
|
and tpb.bid_code = #{bidCode}
|
||||||
GROUP BY tdd.mode_name
|
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<!--作业环境-边坡位移监测列表-->
|
<!--作业环境-边坡位移监测列表-->
|
||||||
|
|
@ -103,8 +111,7 @@
|
||||||
LEFT JOIN tb_area ta ON tbd.area_id = ta.area_id
|
LEFT JOIN tb_area ta ON tbd.area_id = ta.area_id
|
||||||
LEFT JOIN tb_his_device_value thdv ON tdd.id = thdv.attribute_id
|
LEFT JOIN tb_his_device_value thdv ON tdd.id = thdv.attribute_id
|
||||||
LEFT JOIN tb_pro_bd tpb ON tbd.bd_id = tpb.id
|
LEFT JOIN tb_pro_bd tpb ON tbd.bd_id = tpb.id
|
||||||
WHERE tpb.bid_code = #{bidCode}
|
WHERE tpb.bid_code = #{bidCode} and tbd.devic_type = 1908
|
||||||
AND tbd.device_code = 1902001
|
|
||||||
<if test="deviceId != null and deviceId != ''">
|
<if test="deviceId != null and deviceId != ''">
|
||||||
AND tbd.device_id LIKE CONCAT('%', #{deviceId}, '%')
|
AND tbd.device_id LIKE CONCAT('%', #{deviceId}, '%')
|
||||||
</if>
|
</if>
|
||||||
|
|
|
||||||
|
|
@ -40,12 +40,14 @@
|
||||||
<select id="getHistoryList" resultType="com.securitycontrol.entity.screen.vo.TowerAssInspectVo">
|
<select id="getHistoryList" resultType="com.securitycontrol.entity.screen.vo.TowerAssInspectVo">
|
||||||
SELECT ta.area_name as areaName,tdd.mode_name as modeName, thdv.val ,
|
SELECT ta.area_name as areaName,tdd.mode_name as modeName, thdv.val ,
|
||||||
thdv.change_val as changeVal,tdd.update_time as updateTime,
|
thdv.change_val as changeVal,tdd.update_time as updateTime,
|
||||||
|
thdv.create_time createTime,
|
||||||
case when thdv.is_warn = '0' then '未告警' else '告警' end isWarn
|
case when thdv.is_warn = '0' then '未告警' else '告警' end isWarn
|
||||||
FROM tb_device_detail tdd
|
FROM tb_device_detail tdd
|
||||||
LEFT JOIN tb_bd_device tbd ON tdd.device_id = tbd.device_id
|
LEFT JOIN tb_bd_device tbd ON tdd.device_id = tbd.device_id
|
||||||
LEFT JOIN tb_area ta ON ta.area_id = tbd.area_id
|
LEFT JOIN tb_area ta ON ta.area_id = tbd.area_id
|
||||||
LEFT JOIN tb_his_device_value thdv ON tdd.id = thdv.attribute_id
|
LEFT JOIN tb_his_device_value thdv ON tdd.id = thdv.attribute_id
|
||||||
WHERE tdd.device_id = #{deviceId} AND tdd.del_flag = '0'
|
WHERE tdd.device_id = #{deviceId} AND tdd.del_flag = '0'
|
||||||
|
AND thdv.val IS NOT NULL
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
</mapper>
|
</mapper>
|
||||||
Loading…
Reference in New Issue