Commit cab05cb6 authored by chenzhao's avatar chenzhao

修改代码

parent efef5190
......@@ -117,14 +117,14 @@ public class IdxBizPvHealthIndexController extends BaseController {
@TycloudOperation(ApiLevel = UserType.AGENCY,needAuth = false)
@ApiOperation(httpMethod = "GET",value = "预警监测设备级左侧列表", notes = "预警监测设备级左侧列表")
@GetMapping(value = "/queryForLeftTableListByEquip")
public ResponseModel<Page<Map<String,Object>>> queryForLeftTableListByEquip(@RequestParam(required = false) String STATION, @RequestParam(required = false) String SUBARRAY, @RequestParam(required = false) String HEALTHLEVEL, @RequestParam(required = false) Integer current, @RequestParam(required = false) Integer size ) {
public ResponseModel<Page<Map<String,Object>>> queryForLeftTableListByEquip(@RequestParam(required = false) String STATION, @RequestParam(required = false) String SUBARRAY, @RequestParam(required = false) String HEALTHLEVEL, @RequestParam(required = false) String EQUIPMENTNAME, @RequestParam(required = false) Integer current, @RequestParam(required = false) Integer size ) {
Page<Map<String,Object>> page = new Page<Map<String,Object>>();
page.setCurrent(current);
page.setSize(size);
int total = idxBizPvHealthIndexServiceImpl.queryForLeftTableListByEquipCount(STATION, SUBARRAY, HEALTHLEVEL);
int total = idxBizPvHealthIndexServiceImpl.queryForLeftTableListByEquipCount(STATION, SUBARRAY, HEALTHLEVEL,EQUIPMENTNAME);
Long num = Long.valueOf(total);
page.setTotal(num);
page.setRecords(idxBizPvHealthIndexServiceImpl.queryForLeftTableListByEquip(STATION,SUBARRAY,HEALTHLEVEL,(current-1)*size,size));
page.setRecords(idxBizPvHealthIndexServiceImpl.queryForLeftTableListByEquip(STATION,SUBARRAY,HEALTHLEVEL,EQUIPMENTNAME,(current-1)*size,size));
return ResponseHelper.buildResponse(page);
}
......
......@@ -15,8 +15,8 @@ import java.util.Map;
*/
public interface IdxBizPvHealthIndexMapper extends BaseMapper<IdxBizPvHealthIndex> {
List<Map<String,Object>> queryForLeftTableListByEquip(String STATION, String SUBARRAY, String HEALTHLEVEL, Integer current, Integer size);
int queryForLeftTableListByEquipCount(String STATION, String SUBARRAY, String HEALTHLEVEL);
List<Map<String,Object>> queryForLeftTableListByEquip(String STATION, String SUBARRAY, String HEALTHLEVEL, String EQUIPMENTNAME, Integer current, Integer size);
int queryForLeftTableListByEquipCount(String STATION, String SUBARRAY, String HEALTHLEVEL, String EQUIPMENTNAME);
List<Map<String,Object>> queryForLeftTableListByPoint(String STATION, String SUBARRAY, String HEALTHLEVEL, String EQUIPMENTNAME,String POINTNAME,Integer current,Integer size);
......
......@@ -34,8 +34,8 @@ public class IdxBizPvHealthIndexServiceImpl extends BaseService<IdxBizPvHealthIn
}
public List<Map<String,Object>> queryForLeftTableListByEquip(String STATION, String SUBARRAY, String HEALTHLEVEL, Integer current, Integer size) {
return this.getBaseMapper().queryForLeftTableListByEquip(STATION, SUBARRAY, HEALTHLEVEL,current,size);
public List<Map<String,Object>> queryForLeftTableListByEquip(String STATION, String SUBARRAY, String HEALTHLEVEL, String EQUIPMENTNAME, Integer current, Integer size) {
return this.getBaseMapper().queryForLeftTableListByEquip(STATION, SUBARRAY, HEALTHLEVEL,EQUIPMENTNAME,current,size);
}
public List<Map<String,Object>> queryForLeftTableListByPoint(String STATION, String SUBARRAY, String HEALTHLEVEL, String EQUIPMENTNAME,String POINTNAME,Integer current,Integer size) {
......@@ -46,8 +46,8 @@ public class IdxBizPvHealthIndexServiceImpl extends BaseService<IdxBizPvHealthIn
return this.getBaseMapper().queryForLeftTableListByPointCount(STATION, SUBARRAY, HEALTHLEVEL, EQUIPMENTNAME,POINTNAME);
}
public int queryForLeftTableListByEquipCount(String STATION, String SUBARRAY, String HEALTHLEVEL) {
return this.getBaseMapper().queryForLeftTableListByEquipCount(STATION, SUBARRAY, HEALTHLEVEL);
public int queryForLeftTableListByEquipCount(String STATION, String SUBARRAY, String HEALTHLEVEL,String EQUIPMENTNAME) {
return this.getBaseMapper().queryForLeftTableListByEquipCount(STATION, SUBARRAY, HEALTHLEVEL,EQUIPMENTNAME);
}
}
\ No newline at end of file
......@@ -27,7 +27,9 @@
</if>
<if test="STATION != '' and STATION != null">
AND b.STATION = #{STATION}
</if>
<if test="EQUIPMENTNAME != '' and EQUIPMENTNAME != null">
AND b.EQUIPMENT_NAME = #{EQUIPMENT_NAME}
</if>
<if test="HEALTHLEVEL != '' and HEALTHLEVEL != null">
AND b.HEALTH_LEVEL = #{HEALTHLEVEL}
......@@ -55,6 +57,9 @@
<if test="HEALTHLEVEL != '' and HEALTHLEVEL != null">
AND b.HEALTH_LEVEL = #{HEALTHLEVEL}
</if>
<if test="EQUIPMENTNAME != '' and EQUIPMENTNAME != null">
AND b.EQUIPMENT_NAME = #{EQUIPMENT_NAME}
</if>
</select>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment