Commit f7273557 authored by 刘凡's avatar 刘凡

*)事件分布增加事件过滤

parent e0cd4fad
......@@ -3,6 +3,7 @@ package com.yeejoin.amos.boot.module.elevator.api.mapper;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.yeejoin.amos.boot.module.common.api.dto.DPFilterParamDto;
import com.yeejoin.amos.boot.module.elevator.api.dto.AlertCalledQueryDto;
import com.yeejoin.amos.boot.module.elevator.api.dto.AlertCalledRecordDto;
import com.yeejoin.amos.boot.module.elevator.api.dto.AlertPaperInfoDto;
......@@ -52,7 +53,7 @@ public interface AlertCalledMapper extends BaseMapper<AlertCalled> {
*
* @return
*/
List<Map<String, Object>> queryListByLocation(@Param("regionCode") String regionCode);
List<Map<String, Object>> queryListByLocation(@Param("regionCode") String regionCode, @Param("dto") DPFilterParamDto filterParamDto);
/**
* 接警情况统计
*
......
......@@ -152,6 +152,12 @@
AND
ibjuj.USE_PLACE is NOT NULL
AND cdd.NAME is NOT NULL
<if test="dto.beginDate !=null and dto.beginDate !=''">
and date_ge(CAST(tac.call_time as date),#{dto.beginDate})
</if>
<if test="dto.endDate !=null and dto.endDate !=''">
and date_le(CAST(tac.call_time as date),#{dto.endDate})
</if>
GROUP BY
cdd.NAME
ORDER BY ibjuj.USE_PLACE ASC
......
......@@ -133,7 +133,7 @@ public class DPStatisticsServiceImpl {
public JSONObject eventStatByLocation(DPFilterParamDto dpFilterParamDto) throws Exception {
String orgCode = this.getAndSetOrgCode(dpFilterParamDto);
List<Map<String, Object>> maps = alertCalledMapper.queryListByLocation(orgCode);
List<Map<String, Object>> maps = alertCalledMapper.queryListByLocation(orgCode, dpFilterParamDto);
List<Object> xdata = maps.stream().map(item -> item.get("name")).collect(Collectors.toList());
List<Object> ydata = maps.stream().map(item -> item.get("majorAlertCount")).collect(Collectors.toList());
......
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