1.Traffic Statistic页面和Protocol Statistic页面添加direction查询条件

2.原始邮件日志查询所有动作时添加多个service查询条件
This commit is contained in:
shangguanyanfei
2019-01-21 14:49:55 +08:00
parent 8b972c6126
commit 53c8f2279b
9 changed files with 44 additions and 33 deletions

View File

@@ -19,8 +19,8 @@ public interface NtcTotalReportDao {
List<Map> getTotalReportList(@Param("reportTime") Date reportTime);
List<Map> getNetFlowPortInfoNew(@Param("statTime") Date statTime);
List<TrafficTransStatistic> getBandwidthTrans(@Param("entranceId") Integer entranceId,@Param("beginDate") String beginDate,@Param("endDate") String endDate,@Param("addrType") String addrType,@Param("transType") Integer transType);
List<TrafficTransStatistic> getBandwidthTransIPVx(@Param("beginDate") String beginDate,@Param("endDate") String endDate);
List<TrafficTransStatistic> getBandwidthTransProtocol(@Param("beginDate") String beginDate,@Param("endDate") String endDate);
List<TrafficTransStatistic> getBandwidthTransIPVx(@Param("beginDate") String beginDate,@Param("endDate") String endDate,@Param("searchDirection") Integer searchDirection);
List<TrafficTransStatistic> getBandwidthTransProtocol(@Param("beginDate") String beginDate,@Param("endDate") String endDate,@Param("searchDirection") Integer searchDirection);
String getAddrType();
String getTransType();
String getEntranceId();

View File

@@ -73,11 +73,13 @@
WHERE
<![CDATA[ stat_time >= #{beginDate} and stat_time < #{endDate} ]]>
and addr_type in (4,6)
and direction =#{searchDirection}
group by addr_type,stat_time ,entrance_id order by stat_time
</select>
<select id="getBandwidthTransProtocol" resultMap="BandwidthResultMap">
select addr_type,trans_type,entrance_id,IFNULL((SUM(c2s_byte_len+s2c_byte_len)*8)/300/1024/1024/1024,0) gbps,IFNULL(SUM(c2s_pkt_num+s2c_pkt_num)/300,0) pps,IFNULL(SUM(link_num),0) linkNum, stat_time from traffic_trans_statistic
WHERE <![CDATA[stat_time >= #{beginDate} and stat_time < #{endDate} ]]>
and direction =#{searchDirection}
and trans_type in (6,17) group by trans_type,stat_time ,entrance_id order by stat_time
</select>

View File

@@ -13,6 +13,6 @@ public interface TrafficProtocolStatisticDao {
TrafficProtocolStatistic getMaxStatTime();
List<Map> protocolChart(@Param("statTime")Date statTime);
List<Map> getProtocolList(@Param("beginTime")String beginTime,@Param("endTime")String endTime,@Param("protoType")Integer[] protoType,@Param("entranceId")Integer entranceId);
List<Map> getProtocolList(@Param("beginTime")String beginTime,@Param("endTime")String endTime,@Param("protoType")Integer[] protoType,@Param("entranceId")Integer entranceId,@Param("searchDirection")Integer searchDirection);
}

View File

@@ -37,7 +37,10 @@
</foreach>
</if>
<if test="entranceId !=null">
and entrance_id=#{entranceId}
and entrance_id = #{entranceId}
</if>
<if test="searchDirection !=null">
and direction = #{searchDirection}
</if>
GROUP BY proto_type ) p
LEFT JOIN ui_code_protocol_type_dic c ON p.proto_type=c.view_code ORDER BY p.GByte DESC