From a15a8cfd7b01ce4bba6fe9fd876f6704ca23a12d Mon Sep 17 00:00:00 2001
From: liurunyu <lry9898@163.com>
Date: 星期二, 07 一月 2025 16:40:32 +0800
Subject: [PATCH] 1、取水口用水日统计表中增加金额、次数字段; 2、优化或重写“累计流量超过指定值的取水口”、“累计流量低于指定值的取水口”、“指定时间段内用水量超过指定值的取水口”、“指定时间段内消费金额超过指定值的取水口”几个统计查询; 3、改“指定时间段内用水时长超过指定值的取水口”为“指定时间段内用水次数超过指定值的取水口”

---
 pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/voSt/VoCumulativeFlow.java                               |    8 
 pipIrr-platform/pipIrr-global/src/main/resources/mapper/RmOpenCloseValveHistoryMapper.xml                                |   79 -------
 pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/voSt/VoIntakeAccumulateAmount.java                       |    9 
 pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/daoRm/RmOpenCloseValveHistoryMapper.java                 |   28 --
 pipIrr-platform/pipIrr-mw/pipIrr-mw-rtu/src/main/java/com/dy/rtuMw/server/rtuData/p206V1/TkDealIntakeAmountDay.java      |   52 ++++
 pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/daoRm/RmIntakeAmountDayMapper.java                       |   48 ++++
 pipIrr-platform/pipIrr-global/src/main/resources/mapper/RmIntakeAmountDayMapper.xml                                      |  148 ++++++++++++++
 pipIrr-platform/pipIrr-web/pipIrr-web-statistics/src/main/java/com/dy/pipIrrStatistics/intake/qo/IntakeCountValueQO.java |    2 
 pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/pojoRm/RmIntakeAmountDayLast.java                        |   11 +
 pipIrr-platform/pipIrr-web/pipIrr-web-statistics/src/main/java/com/dy/pipIrrStatistics/intake/IntkeCtrl.java             |   24 ++
 pipIrr-platform/pipIrr-web/pipIrr-web-statistics/src/main/java/com/dy/pipIrrStatistics/intake/IntakeSv.java              |   87 +++++---
 pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/voSt/VoIntake.java                                       |   14 +
 pipIrr-platform/pipIrr-global/src/main/resources/mapper/RmIntakeAmountDayLastMapper.xml                                  |   35 +++
 pipIrr-platform/pipIrr-global/src/main/resources/mapper/RmOnHourReportLastMapper.xml                                     |   19 +
 pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/pojoRm/RmIntakeAmountDay.java                            |   11 +
 15 files changed, 403 insertions(+), 172 deletions(-)

diff --git a/pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/daoRm/RmIntakeAmountDayMapper.java b/pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/daoRm/RmIntakeAmountDayMapper.java
index a725519..709719c 100644
--- a/pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/daoRm/RmIntakeAmountDayMapper.java
+++ b/pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/daoRm/RmIntakeAmountDayMapper.java
@@ -3,10 +3,7 @@
 import com.baomidou.mybatisplus.core.mapper.BaseMapper;
 import com.dy.pipIrrGlobal.pojoRm.RmIntakeAmountDay;
 import com.dy.pipIrrGlobal.voRm.VoIntakeAmountDay;
-import com.dy.pipIrrGlobal.voSt.VoDayIntakeAmount;
-import com.dy.pipIrrGlobal.voSt.VoDayLoss;
-import com.dy.pipIrrGlobal.voSt.VoIntakeAmountStatistics;
-import com.dy.pipIrrGlobal.voSt.VoMonthAmount;
+import com.dy.pipIrrGlobal.voSt.*;
 import org.apache.ibatis.annotations.Mapper;
 import org.apache.ibatis.annotations.Param;
 
@@ -151,4 +148,47 @@
     List<VoDayIntakeAmount> selectIntakeAmountOfDay16_20(Map<?, ?> params);
     List<VoDayIntakeAmount> selectIntakeAmountOfDay21_25(Map<?, ?> params);
     List<VoDayIntakeAmount> selectIntakeAmountOfDay26_31(Map<?, ?> params);
+
+
+    /**
+     * 鎸囧畾鏃堕棿娈电敤姘撮噺瓒呰繃鎸囧畾鍊肩殑鍙栨按鍙f暟閲�
+     * @param params
+     * @return
+     */
+    Long getUseWaterGtValueIntakesCount(Map<String, Object> params);
+
+    /**
+     * 鎸囧畾鏃堕棿娈电敤姘撮噺瓒呰繃鎸囧畾鍊肩殑鍙栨按鍙�
+     * @param params
+     * @return
+     */
+    List<VoIntakeAccumulateAmount> getUseWaterGtValueIntakes(Map<String, Object> params);
+    /**
+     * 鎸囧畾鏃堕棿娈靛唴娑堣垂閲戦瓒呰繃鎸囧畾鍊肩殑鍙栨按鍙g殑鏁伴噺
+     * @param params
+     * @return
+     */
+    Long getExpenseGtValueIntakesCount(Map<String, Object> params);
+
+    /**
+     * 鎸囧畾鏃堕棿娈靛唴娑堣垂閲戦瓒呰繃鎸囧畾鍊肩殑鍙栨按鍙�
+     * @param params
+     * @return
+     */
+    List<VoIntakeAccumulateAmount> getExpenseGtValueIntakes(Map<String, Object> params);
+
+   /**
+     * 鎸囧畾鏃堕棿娈靛唴鍙栨按娆℃暟瓒呰繃鎸囧畾鍊肩殑鍙栨按鍙g殑鏁伴噺
+     * @param params
+     * @return
+     */
+    Long getUseWaterTimesGtValueIntakesCount(Map<String, Object> params);
+
+    /**
+     * 鎸囧畾鏃堕棿娈靛唴鍙栨按娆℃暟瓒呰繃鎸囧畾鍊肩殑鍙栨按鍙�
+     * @param params
+     * @return
+     */
+    List<VoIntakeAccumulateAmount> getUseWaterTimesGtValueIntakes(Map<String, Object> params);
+
 }
\ No newline at end of file
diff --git a/pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/daoRm/RmOpenCloseValveHistoryMapper.java b/pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/daoRm/RmOpenCloseValveHistoryMapper.java
index 01dc0fb..9f867af 100644
--- a/pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/daoRm/RmOpenCloseValveHistoryMapper.java
+++ b/pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/daoRm/RmOpenCloseValveHistoryMapper.java
@@ -238,34 +238,6 @@
     List<VoClient> getSmallWaterDurationClients(Map<String, Object> params);
 
     /**
-     * 鎸囧畾鏃堕棿娈电敤姘撮噺瓒呰繃鎸囧畾鍊肩殑鍙栨按鍙f暟閲�
-     * @param params
-     * @return
-     */
-    Long getUseWaterGtValueIntakesCount(Map<String, Object> params);
-
-    /**
-     * 鎸囧畾鏃堕棿娈电敤姘撮噺瓒呰繃鎸囧畾鍊肩殑鍙栨按鍙�
-     * @param params
-     * @return
-     */
-    List<VoIntakeAccumulateAmount> getUseWaterGtValueIntakes(Map<String, Object> params);
-
-    /**
-     * 鎸囧畾鏃堕棿娈靛唴娑堣垂閲戦瓒呰繃鎸囧畾鍊肩殑鍙栨按鍙g殑鏁伴噺
-     * @param params
-     * @return
-     */
-    Long getExpenseGtValueIntakesCount(Map<String, Object> params);
-
-    /**
-     * 鎸囧畾鏃堕棿娈靛唴娑堣垂閲戦瓒呰繃鎸囧畾鍊肩殑鍙栨按鍙�
-     * @param params
-     * @return
-     */
-    List<VoIntakeAccumulateAmount> getExpenseGtValueIntakes(Map<String, Object> params);
-
-    /**
      * 鎸囧畾鏃堕棿娈靛唴鐢ㄦ按鏃堕暱瓒呰繃鎸囧畾鍊肩殑鍙栨按鍙f暟閲�
      * @param params
      * @return
diff --git a/pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/pojoRm/RmIntakeAmountDay.java b/pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/pojoRm/RmIntakeAmountDay.java
index 7af8936..357870a 100644
--- a/pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/pojoRm/RmIntakeAmountDay.java
+++ b/pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/pojoRm/RmIntakeAmountDay.java
@@ -56,6 +56,17 @@
     public Double amount;
 
     /**
+     * 鏃ュ彇娑堣垂閲戦
+     */
+    @JsonFormat(shape = JsonFormat.Shape.NUMBER_FLOAT, pattern="0.00" )
+    public Double money;
+
+    /**
+     * 鏃ュ彇姘存鏁�
+     */
+    public Integer times;
+
+    /**
      * 绱鏃ユ紡鎹熸按閲�
      */
     @JsonFormat(shape = JsonFormat.Shape.NUMBER_FLOAT, pattern="0.00" )
diff --git a/pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/pojoRm/RmIntakeAmountDayLast.java b/pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/pojoRm/RmIntakeAmountDayLast.java
index cc79b20..7fdaebd 100644
--- a/pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/pojoRm/RmIntakeAmountDayLast.java
+++ b/pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/pojoRm/RmIntakeAmountDayLast.java
@@ -63,6 +63,17 @@
     public Double amount;
 
     /**
+     * 鏃ュ彇娑堣垂閲戦
+     */
+    @JsonFormat(shape = JsonFormat.Shape.NUMBER_FLOAT, pattern="0.00" )
+    public Double money;
+
+    /**
+     * 鏃ュ彇姘存鏁�
+     */
+    public Integer times;
+
+    /**
      * 鏈�鍚庤姘撮噺涓婃姤鏁版嵁鎺ユ敹鏃堕棿(yyyy-mm-dd hh:mm:ss)
      */
     @Schema(description = "鏈�鍚庤姘撮噺涓婃姤鏁版嵁鎺ユ敹鏃堕棿", requiredMode = Schema.RequiredMode.NOT_REQUIRED)
diff --git a/pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/voSt/VoCumulativeFlow.java b/pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/voSt/VoCumulativeFlow.java
index a5ecb39..66728dc 100644
--- a/pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/voSt/VoCumulativeFlow.java
+++ b/pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/voSt/VoCumulativeFlow.java
@@ -1,6 +1,7 @@
 package com.dy.pipIrrGlobal.voSt;
 
 import com.fasterxml.jackson.annotation.JsonFormat;
+import com.fasterxml.jackson.annotation.JsonPropertyOrder;
 import lombok.Data;
 import lombok.EqualsAndHashCode;
 
@@ -14,17 +15,20 @@
  */
 
 @Data
+@JsonPropertyOrder({ "intakeId", "intakeNum", "blockName", "lng", "lat"
+        ,"cumulativeFlow" , "getDate"
+})
 @EqualsAndHashCode(callSuper=false)
 public class VoCumulativeFlow extends VoIntake {
 
     /**
      * 绱娴侀噺
      */
-    private Double cumulativeFlow;
+    public Double cumulativeFlow;
 
     /**
      * 鏁版嵁鑾峰彇鏃ユ湡
      */
     @JsonFormat(pattern = "yyyy-MM-dd")
-    private Date getDate;
+    public Date getDate;
 }
diff --git a/pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/voSt/VoIntake.java b/pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/voSt/VoIntake.java
index dcc8f06..32e46da 100644
--- a/pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/voSt/VoIntake.java
+++ b/pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/voSt/VoIntake.java
@@ -19,16 +19,24 @@
      * 鍙栨按鍙D
      */
     @JSONField(serializeUsing= ObjectWriterImplToString.class)
-    private Long intakeId;
+    public Long intakeId;
 
     /**
      * 鍙栨按鍙g紪鍙�
      */
-    private String intakeNum;
+    public String intakeNum;
 
     /**
      * 鍙栨按鍙f墍灞炵墖鍖�
      */
-    private String blockName;
+    public String blockName;
+    /**
+     * 鍙栨按鍙g粡搴�
+     */
+    public Double lng ;
+    /**
+     * 鍙栨按鍙g含搴�
+     */
+    public Double lat ;
 
 }
diff --git a/pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/voSt/VoIntakeAccumulateAmount.java b/pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/voSt/VoIntakeAccumulateAmount.java
index 16ccffe..229219a 100644
--- a/pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/voSt/VoIntakeAccumulateAmount.java
+++ b/pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/voSt/VoIntakeAccumulateAmount.java
@@ -1,6 +1,7 @@
 package com.dy.pipIrrGlobal.voSt;
 
 import com.fasterxml.jackson.annotation.JsonFormat;
+import com.fasterxml.jackson.annotation.JsonPropertyOrder;
 import lombok.Data;
 import lombok.EqualsAndHashCode;
 
@@ -13,6 +14,9 @@
  *                    娑堣垂閲戦 澶т簬 鎸囧畾鍊�
  */
 @Data
+@JsonPropertyOrder({ "intakeId", "intakeNum", "blockName", "lng", "lat"
+        ,"value", "valueInt"
+})
 @EqualsAndHashCode(callSuper=false)
 public class VoIntakeAccumulateAmount extends VoIntake{
     private static final long serialVersionUID = 202408051046001L;
@@ -22,4 +26,9 @@
      */
     @JsonFormat(shape = JsonFormat.Shape.NUMBER_FLOAT, pattern="0.00" )
     private Double value;
+
+    /**
+     * 鎸囧畾鍊�
+     */
+    private Integer valueInt;
 }
diff --git a/pipIrr-platform/pipIrr-global/src/main/resources/mapper/RmIntakeAmountDayLastMapper.xml b/pipIrr-platform/pipIrr-global/src/main/resources/mapper/RmIntakeAmountDayLastMapper.xml
index 915a04f..459b28d 100644
--- a/pipIrr-platform/pipIrr-global/src/main/resources/mapper/RmIntakeAmountDayLastMapper.xml
+++ b/pipIrr-platform/pipIrr-global/src/main/resources/mapper/RmIntakeAmountDayLastMapper.xml
@@ -9,6 +9,8 @@
     <result column="intake_id" jdbcType="BIGINT" property="intakeId" />
     <result column="dt" jdbcType="DATE" property="dt" />
     <result column="amount" jdbcType="DOUBLE" property="amount" />
+    <result column="money" jdbcType="DOUBLE" property="money" />
+    <result column="times" jdbcType="INTEGER" property="times" />
     <result column="dt_last" jdbcType="TIMESTAMP" property="dtLast" />
     <result column="rtu_addr_last" jdbcType="VARCHAR" property="rtuAddrLast" />
     <result column="controller_id_last" jdbcType="BIGINT" property="controllerIdLast" />
@@ -17,7 +19,7 @@
   </resultMap>
   <sql id="Base_Column_List">
     <!--@mbg.generated-->
-    id, last_history_id, intake_id, dt, amount, dt_last, rtu_addr_last, controller_id_last, total_amount_last,
+    id, last_history_id, intake_id, dt, amount, money, times, dt_last, rtu_addr_last, controller_id_last, total_amount_last,
     rtu_dt_last
   </sql>
   <select id="selectByPrimaryKey" parameterType="java.lang.Long" resultMap="BaseResultMap">
@@ -43,11 +45,12 @@
   <insert id="insert" parameterType="com.dy.pipIrrGlobal.pojoRm.RmIntakeAmountDayLast">
     <!--@mbg.generated-->
     insert into rm_intake_amount_day_last (id, last_history_id, intake_id, dt,
-      amount, dt_last,
+      amount, money, times, dt_last,
       rtu_addr_last, controller_id_last, total_amount_last, 
       rtu_dt_last)
     values (#{id,jdbcType=BIGINT}, #{lastHistoryId,jdbcType=BIGINT}, #{intakeId,jdbcType=BIGINT}, #{dt,jdbcType=DATE},
-      #{amount,jdbcType=DOUBLE}, #{dtLast,jdbcType=TIMESTAMP},
+      #{amount,jdbcType=DOUBLE}, #{money,jdbcType=DOUBLE},#{times,jdbcType=INTEGER},
+      #{dtLast,jdbcType=TIMESTAMP},
       #{rtuAddrLast,jdbcType=VARCHAR}, #{controllerIdLast,jdbcType=BIGINT}, #{totalAmountLast,jdbcType=FLOAT}, 
       #{rtuDtLast,jdbcType=TIMESTAMP})
   </insert>
@@ -69,6 +72,12 @@
       </if>
       <if test="amount != null">
         amount,
+      </if>
+      <if test="money != null">
+        money,
+      </if>
+      <if test="times != null">
+        times,
       </if>
       <if test="dtLast != null">
         dt_last,
@@ -101,6 +110,12 @@
       </if>
       <if test="amount != null">
         #{amount,jdbcType=DOUBLE},
+      </if>
+      <if test="money != null">
+        #{money,jdbcType=DOUBLE},
+      </if>
+      <if test="times != null">
+        #{times,jdbcType=INTEGER},
       </if>
       <if test="dtLast != null">
         #{dtLast,jdbcType=TIMESTAMP},
@@ -135,6 +150,12 @@
       <if test="amount != null">
         amount = #{amount,jdbcType=DOUBLE},
       </if>
+      <if test="money != null">
+        money = #{money,jdbcType=DOUBLE},
+      </if>
+      <if test="times != null">
+        times = #{times,jdbcType=INTEGER},
+      </if>
       <if test="dtLast != null">
         dt_last = #{dtLast,jdbcType=TIMESTAMP},
       </if>
@@ -160,6 +181,8 @@
       intake_id = #{intakeId,jdbcType=BIGINT},
       dt = #{dt,jdbcType=DATE},
       amount = #{amount,jdbcType=DOUBLE},
+      money = #{money,jdbcType=DOUBLE},
+      times = #{times,jdbcType=INTEGER},
       dt_last = #{dtLast,jdbcType=TIMESTAMP},
       rtu_addr_last = #{rtuAddrLast,jdbcType=VARCHAR},
       controller_id_last = #{controllerIdLast,jdbcType=BIGINT},
@@ -174,7 +197,7 @@
     Left join pr_intake pint on pint.id = riadl.intake_id
     <where>
       <if test="intakeId != null and intakeId != '' ">
-        and rash.intake_id = #{intakeId}
+        riadl.intake_id = #{intakeId}
       </if>
       <if test="intakeName != null and intakeName != '' ">
         and pint.name like CONCAT('%',#{intakeName,jdbcType=VARCHAR},'%')
@@ -194,6 +217,8 @@
     pint.name as intakeName,
     riadl.dt as dt,
     riadl.amount as amount,
+    riadl.money as money,
+    riadl.times as times,
     riadl.dt_last as dtLast,
     riadl.rtu_addr_last as rtuAddrLast,
     CAST(riadl.controller_id_last AS char)AS controllerIdLast,
@@ -203,7 +228,7 @@
     Left join pr_intake pint on pint.id = riadl.intake_id
     <where>
       <if test="intakeId != null and intakeId != '' ">
-        and rash.intake_id = #{intakeId}
+        riadl.intake_id = #{intakeId}
       </if>
       <if test="intakeName != null and intakeName != '' ">
         and pint.name like CONCAT('%',#{intakeName,jdbcType=VARCHAR},'%')
diff --git a/pipIrr-platform/pipIrr-global/src/main/resources/mapper/RmIntakeAmountDayMapper.xml b/pipIrr-platform/pipIrr-global/src/main/resources/mapper/RmIntakeAmountDayMapper.xml
index 7ddc8ab..4645d19 100644
--- a/pipIrr-platform/pipIrr-global/src/main/resources/mapper/RmIntakeAmountDayMapper.xml
+++ b/pipIrr-platform/pipIrr-global/src/main/resources/mapper/RmIntakeAmountDayMapper.xml
@@ -8,6 +8,8 @@
         <result column="intake_id" jdbcType="BIGINT" property="intakeId"/>
         <result column="dt" jdbcType="DATE" property="dt"/>
         <result column="amount" jdbcType="DOUBLE" property="amount"/>
+        <result column="money" jdbcType="DOUBLE" property="money" />
+        <result column="times" jdbcType="INTEGER" property="times" />
         <result column="dt_last" jdbcType="TIMESTAMP" property="dtLast"/>
         <result column="rtu_addr_last" jdbcType="VARCHAR" property="rtuAddrLast"/>
         <result column="controller_id_last" jdbcType="BIGINT" property="controllerIdLast"/>
@@ -19,7 +21,7 @@
         id,
         intake_id,
         dt,
-        amount,
+        amount, money, times,
         dt_last,
         rtu_addr_last,
         controller_id_last,
@@ -49,11 +51,11 @@
     <insert id="insert" parameterType="com.dy.pipIrrGlobal.pojoRm.RmIntakeAmountDay">
         <!--@mbg.generated-->
         insert into rm_intake_amount_day (id, intake_id, dt,
-                                          amount, dt_last,
+                                          amount, money, times, dt_last,
                                           rtu_addr_last, controller_id_last, total_amount_last,
                                           rtu_dt_last)
         values (#{id,jdbcType=BIGINT}, #{intakeId,jdbcType=BIGINT}, #{dt,jdbcType=DATE},
-                #{amount,jdbcType=DOUBLE}, #{dtLast,jdbcType=TIMESTAMP},
+                #{amount,jdbcType=DOUBLE}, #{money,jdbcType=DOUBLE}, #{times,jdbcType=INTEGER}, #{dtLast,jdbcType=TIMESTAMP},
                 #{rtuAddrLast,jdbcType=VARCHAR}, #{controllerIdLast,jdbcType=BIGINT}, #{totalAmountLast,jdbcType=FLOAT},
                 #{rtuDtLast,jdbcType=TIMESTAMP})
     </insert>
@@ -72,6 +74,12 @@
             </if>
             <if test="amount != null">
                 amount,
+            </if>
+           <if test="money != null">
+               money,
+            </if>
+           <if test="times != null">
+               times,
             </if>
             <if test="dtLast != null">
                 dt_last,
@@ -101,6 +109,12 @@
             </if>
             <if test="amount != null">
                 #{amount,jdbcType=DOUBLE},
+            </if>
+            <if test="money != null">
+                #{money,jdbcType=DOUBLE},
+            </if>
+            <if test="times != null">
+                #{times,jdbcType=INTEGER},
             </if>
             <if test="dtLast != null">
                 #{dtLast,jdbcType=TIMESTAMP},
@@ -132,6 +146,12 @@
             <if test="amount != null">
                 amount = #{amount,jdbcType=DOUBLE},
             </if>
+            <if test="money != null">
+                money = #{money,jdbcType=DOUBLE},
+            </if>
+            <if test="times != null">
+                times = #{times,jdbcType=INTEGER},
+            </if>
             <if test="dtLast != null">
                 dt_last = #{dtLast,jdbcType=TIMESTAMP},
             </if>
@@ -156,6 +176,8 @@
         set intake_id          = #{intakeId,jdbcType=BIGINT},
             dt                 = #{dt,jdbcType=DATE},
             amount             = #{amount,jdbcType=DOUBLE},
+            money              = #{money,jdbcType=DOUBLE},
+            times              = #{times,jdbcType=INTEGER},
             dt_last            = #{dtLast,jdbcType=TIMESTAMP},
             rtu_addr_last      = #{rtuAddrLast,jdbcType=VARCHAR},
             controller_id_last = #{controllerIdLast,jdbcType=BIGINT},
@@ -189,6 +211,8 @@
                pint.name                             as intakeName,
                riad.dt                               as dt,
                riad.amount                           as amount,
+               riad.money                            as money,
+               riad.times                            as times,
                riad.dt_last                          as dtLast,
                riad.rtu_addr_last                    as rtuAddrLast,
                CAST(riad.controller_id_last AS char) AS controllerIdLast,
@@ -995,5 +1019,121 @@
     ) as tb31 on tb31.intakeId = inta.intakeId
   </select>
 
-
+    <!--鎸囧畾鏃堕棿娈电敤姘撮噺瓒呰繃鎸囧畾鍊肩殑鍙栨按鍙f暟閲�-->
+    <select id="getUseWaterGtValueIntakesCount" resultType="java.lang.Long">
+        select
+        count(*)
+        from (
+        SELECT
+        SUM(riad.amount) AS value
+        FROM
+        pr_intake inta
+        INNER JOIN ba_block blo ON blo.id = inta.blockId
+        INNER JOIN rm_intake_amount_day riad ON riad.intake_id = inta.id
+        WHERE inta.deleted = 0 and riad.dt &gt;= #{timeStart} AND riad.dt &lt;= #{timeStop}
+        GROUP BY inta.id
+        HAVING value &gt; #{value}
+        ) c
+    </select>
+    <!--鎸囧畾鏃堕棿娈电敤姘撮噺瓒呰繃鎸囧畾鍊肩殑鍙栨按鍙�-->
+    <select id="getUseWaterGtValueIntakes" resultType="com.dy.pipIrrGlobal.voSt.VoIntakeAccumulateAmount">
+        SELECT
+        inta.id AS intakeId,
+        inta.NAME AS intakeNum,
+        inta.lng  AS lng,
+        inta.lat  AS lat,
+        blo.NAME AS blockName ,
+        SUM(riad.amount) AS value
+        FROM
+        pr_intake inta
+        INNER JOIN ba_block blo ON blo.id = inta.blockId
+        INNER JOIN rm_intake_amount_day riad ON riad.intake_id = inta.id
+        WHERE inta.deleted = 0 and riad.dt &gt;= #{timeStart} AND riad.dt &lt;= #{timeStop}
+        GROUP BY inta.id
+        HAVING value &gt; #{value}
+        ORDER BY inta.id
+        <trim prefix="limit " >
+            <if test="start != null and count != null">
+                #{start,javaType=Integer,jdbcType=INTEGER}, #{count,javaType=Integer,jdbcType=INTEGER}
+            </if>
+        </trim>
+    </select>
+    <!--鎸囧畾鏃堕棿娈靛唴娑堣垂閲戦瓒呰繃鎸囧畾鍊肩殑鍙栨按鍙g殑鏁伴噺-->
+    <select id="getExpenseGtValueIntakesCount" resultType="java.lang.Long">
+        select
+        count(*)
+        from (
+        SELECT
+        SUM(riad.money) AS value
+        FROM
+        pr_intake inta
+        INNER JOIN ba_block blo ON blo.id = inta.blockId
+        INNER JOIN rm_intake_amount_day riad ON riad.intake_id = inta.id
+        WHERE inta.deleted = 0 and riad.dt &gt;= #{timeStart} AND riad.dt &lt;= #{timeStop}
+        GROUP BY inta.id
+        HAVING value &gt; #{value}
+        ) c
+    </select>
+    <!--鎸囧畾鏃堕棿娈靛唴娑堣垂閲戦瓒呰繃鎸囧畾鍊肩殑鍙栨按鍙�-->
+    <select id="getExpenseGtValueIntakes" resultType="com.dy.pipIrrGlobal.voSt.VoIntakeAccumulateAmount">
+        SELECT
+        inta.id AS intakeId,
+        inta.NAME AS intakeNum,
+        inta.lng  AS lng,
+        inta.lat  AS lat,
+        blo.NAME AS blockName ,
+        SUM(riad.money) AS value
+        FROM
+        pr_intake inta
+        INNER JOIN ba_block blo ON blo.id = inta.blockId
+        INNER JOIN rm_intake_amount_day riad ON riad.intake_id = inta.id
+        WHERE inta.deleted = 0 and riad.dt &gt;= #{timeStart} AND riad.dt &lt;= #{timeStop}
+        GROUP BY inta.id
+        HAVING value &gt; #{value}
+        ORDER BY inta.id
+        <trim prefix="limit " >
+            <if test="start != null and count != null">
+                #{start,javaType=Integer,jdbcType=INTEGER}, #{count,javaType=Integer,jdbcType=INTEGER}
+            </if>
+        </trim>
+    </select>
+    <!--鎸囧畾鏃堕棿娈靛唴鍙栨按娆℃暟瓒呰繃鎸囧畾鍊肩殑鍙栨按鍙g殑鏁伴噺-->
+    <select id="getUseWaterTimesGtValueIntakesCount" resultType="java.lang.Long">
+        select
+        count(*)
+        from (
+        SELECT
+        SUM(riad.times) AS valueInt
+        FROM
+        pr_intake inta
+        INNER JOIN ba_block blo ON blo.id = inta.blockId
+        INNER JOIN rm_intake_amount_day riad ON riad.intake_id = inta.id
+        WHERE inta.deleted = 0 and riad.dt &gt;= #{timeStart} AND riad.dt &lt;= #{timeStop}
+        GROUP BY inta.id
+        HAVING value &gt; #{value}
+        ) c
+    </select>
+    <!--鎸囧畾鏃堕棿娈靛唴鍙栨按娆℃暟瓒呰繃鎸囧畾鍊肩殑鍙栨按鍙�-->
+    <select id="getUseWaterTimesGtValueIntakes" resultType="com.dy.pipIrrGlobal.voSt.VoIntakeAccumulateAmount">
+        SELECT
+        inta.id AS intakeId,
+        inta.NAME AS intakeNum,
+        inta.lng  AS lng,
+        inta.lat  AS lat,
+        blo.NAME AS blockName ,
+        SUM(riad.times) AS valueInt
+        FROM
+        pr_intake inta
+        INNER JOIN ba_block blo ON blo.id = inta.blockId
+        INNER JOIN rm_intake_amount_day riad ON riad.intake_id = inta.id
+        WHERE inta.deleted = 0 and riad.dt &gt;= #{timeStart} AND riad.dt &lt;= #{timeStop}
+        GROUP BY inta.id
+        HAVING value &gt; #{value}
+        ORDER BY inta.id
+        <trim prefix="limit " >
+            <if test="start != null and count != null">
+                #{start,javaType=Integer,jdbcType=INTEGER}, #{count,javaType=Integer,jdbcType=INTEGER}
+            </if>
+        </trim>
+    </select>
 </mapper>
\ No newline at end of file
diff --git a/pipIrr-platform/pipIrr-global/src/main/resources/mapper/RmOnHourReportLastMapper.xml b/pipIrr-platform/pipIrr-global/src/main/resources/mapper/RmOnHourReportLastMapper.xml
index 8559512..7f1859a 100644
--- a/pipIrr-platform/pipIrr-global/src/main/resources/mapper/RmOnHourReportLastMapper.xml
+++ b/pipIrr-platform/pipIrr-global/src/main/resources/mapper/RmOnHourReportLastMapper.xml
@@ -285,11 +285,13 @@
 
     <!--鑾峰彇绱娴侀噺瓒呰繃鎸囧畾鍊肩殑鍙栨按鍙�-->
     <select id="getLargeFlowIntakes" resultType="com.dy.pipIrrGlobal.voSt.VoCumulativeFlow">
-        SELECT inta.id                                  AS intakeId,
-               inta.name                                AS intakeNum,
-               blo.name                                 AS blockName,
-               CAST(hou.total_amount AS DECIMAL(10, 2)) AS cumulativeFlow,
-               hou.dt                                   AS getDate
+        SELECT inta.id            AS intakeId,
+               inta.name          AS intakeNum,
+               inta.lng           AS lng,
+               inta.lat           AS lat,
+               blo.name           AS blockName,
+               hou.total_amount   AS cumulativeFlow,
+               hou.dt             AS getDate
         FROM pr_intake inta
                  INNER JOIN rm_on_hour_report_last hou ON hou.intake_id = inta.id
                  INNER JOIN ba_block blo ON blo.id = inta.blockId
@@ -317,10 +319,11 @@
     <select id="getSmallFlowIntakes" resultType="com.dy.pipIrrGlobal.voSt.VoCumulativeFlow">
         SELECT inta.id   AS intakeId,
                inta.name AS intakeNum,
+               inta.lng  AS lng,
+               inta.lat  AS lat,
                blo.name  AS blockName,
-        <!--    FORMAT(hou.total_amount,2) AS cumulativeFlow,-->
-        CAST(hou.total_amount AS DECIMAL(10, 2)) AS cumulativeFlow,
-        hou.dt                                   AS getDate
+               hou.total_amount AS cumulativeFlow,
+               hou.dt    AS getDate
         FROM pr_intake inta
                  INNER JOIN rm_on_hour_report_last hou ON hou.intake_id = inta.id
                  INNER JOIN ba_block blo ON blo.id = inta.blockId
diff --git a/pipIrr-platform/pipIrr-global/src/main/resources/mapper/RmOpenCloseValveHistoryMapper.xml b/pipIrr-platform/pipIrr-global/src/main/resources/mapper/RmOpenCloseValveHistoryMapper.xml
index 946ed18..8156a0d 100644
--- a/pipIrr-platform/pipIrr-global/src/main/resources/mapper/RmOpenCloseValveHistoryMapper.xml
+++ b/pipIrr-platform/pipIrr-global/src/main/resources/mapper/RmOpenCloseValveHistoryMapper.xml
@@ -1037,84 +1037,7 @@
             </if>
         </trim>
     </select>
-    <!--鎸囧畾鏃堕棿娈电敤姘撮噺瓒呰繃鎸囧畾鍊肩殑鍙栨按鍙f暟閲�-->
-    <select id="getUseWaterGtValueIntakesCount" resultType="java.lang.Long">
-        select
-            count(*)
-        from
-            (        SELECT
-        inta.id AS intakeId,
-        inta.NAME AS intakeNum,
-        blo.NAME AS blockName ,
-        IFNULL(SUM(rocvh.cl_this_amount),0) AS value
-        FROM
-        pr_intake inta
-        INNER JOIN ba_block blo ON blo.id = inta.blockId
-        LEFT JOIN rm_open_close_valve_history rocvh ON rocvh.intake_id = inta.id
-        WHERE rocvh.op_dt &gt;= #{timeStart} AND rocvh.cl_dt &lt;= #{timeStop} AND inta.deleted = 0
-        GROUP BY inta.id
-        HAVING IFNULL(SUM(rocvh.cl_this_amount),0) &gt; #{value}) c
-    </select>
-    <!--鎸囧畾鏃堕棿娈电敤姘撮噺瓒呰繃鎸囧畾鍊肩殑鍙栨按鍙�-->
-    <select id="getUseWaterGtValueIntakes" resultType="com.dy.pipIrrGlobal.voSt.VoIntakeAccumulateAmount">
-        SELECT
-            inta.id AS intakeId,
-            inta.NAME AS intakeNum,
-            blo.NAME AS blockName ,
-        IFNULL(SUM(rocvh.cl_this_amount),0) AS value
-        FROM
-            pr_intake inta
-            INNER JOIN ba_block blo ON blo.id = inta.blockId
-            LEFT JOIN rm_open_close_valve_history rocvh ON rocvh.intake_id = inta.id
-        WHERE rocvh.op_dt &gt;= #{timeStart} AND rocvh.cl_dt &lt;= #{timeStop} AND inta.deleted = 0
-        GROUP BY inta.id
-        HAVING IFNULL(SUM(rocvh.cl_this_amount),0) &gt; #{value}
-        ORDER BY inta.id
-        <trim prefix="limit " >
-            <if test="start != null and count != null">
-                #{start,javaType=Integer,jdbcType=INTEGER}, #{count,javaType=Integer,jdbcType=INTEGER}
-            </if>
-        </trim>
-    </select>
-    <!--鎸囧畾鏃堕棿娈靛唴娑堣垂閲戦瓒呰繃鎸囧畾鍊肩殑鍙栨按鍙g殑鏁伴噺-->
-    <select id="getExpenseGtValueIntakesCount" resultType="java.lang.Long">
-        select
-        count(*)
-        from
-        (        SELECT
-        inta.id AS intakeId,
-        inta.NAME AS intakeNum,
-        blo.NAME AS blockName ,
-        IFNULL(SUM(rocvh.cl_this_money),0) AS value
-        FROM
-        pr_intake inta
-        INNER JOIN ba_block blo ON blo.id = inta.blockId
-        LEFT JOIN rm_open_close_valve_history rocvh ON rocvh.intake_id = inta.id
-        WHERE rocvh.op_dt &gt;= #{timeStart} AND rocvh.cl_dt &lt;= #{timeStop} AND inta.deleted = 0
-        GROUP BY inta.id
-        HAVING IFNULL(SUM(rocvh.cl_this_money),0) &gt; #{value}) c
-    </select>
-    <!--鎸囧畾鏃堕棿娈靛唴娑堣垂閲戦瓒呰繃鎸囧畾鍊肩殑鍙栨按鍙�-->
-    <select id="getExpenseGtValueIntakes" resultType="com.dy.pipIrrGlobal.voSt.VoIntakeAccumulateAmount">
-        SELECT
-        inta.id AS intakeId,
-        inta.NAME AS intakeNum,
-        blo.NAME AS blockName ,
-        IFNULL(SUM(rocvh.cl_this_money),0) AS value
-        FROM
-        pr_intake inta
-        INNER JOIN ba_block blo ON blo.id = inta.blockId
-        LEFT JOIN rm_open_close_valve_history rocvh ON rocvh.intake_id = inta.id
-        WHERE rocvh.op_dt &gt;= #{timeStart} AND rocvh.cl_dt &lt;= #{timeStop} AND inta.deleted = 0
-        GROUP BY inta.id
-        HAVING IFNULL(SUM(rocvh.cl_this_money),0) &gt; #{value}
-        ORDER BY inta.id
-        <trim prefix="limit " >
-            <if test="start != null and count != null">
-                #{start,javaType=Integer,jdbcType=INTEGER}, #{count,javaType=Integer,jdbcType=INTEGER}
-            </if>
-        </trim>
-    </select>
+
     <!--鎸囧畾鏃堕棿娈靛唴鐢ㄦ按鏃堕暱瓒呰繃鎸囧畾鍊肩殑鍙栨按鍙f暟閲�-->
     <select id="getUseWaterDurationGtValueIntakesCount" resultType="java.lang.Long">
         select
diff --git a/pipIrr-platform/pipIrr-mw/pipIrr-mw-rtu/src/main/java/com/dy/rtuMw/server/rtuData/p206V1/TkDealIntakeAmountDay.java b/pipIrr-platform/pipIrr-mw/pipIrr-mw-rtu/src/main/java/com/dy/rtuMw/server/rtuData/p206V1/TkDealIntakeAmountDay.java
index 4fd16a1..78b09bc 100644
--- a/pipIrr-platform/pipIrr-mw/pipIrr-mw-rtu/src/main/java/com/dy/rtuMw/server/rtuData/p206V1/TkDealIntakeAmountDay.java
+++ b/pipIrr-platform/pipIrr-mw/pipIrr-mw-rtu/src/main/java/com/dy/rtuMw/server/rtuData/p206V1/TkDealIntakeAmountDay.java
@@ -153,7 +153,15 @@
         po.dt = DateTime.dateFrom_yyyy_MM_dd1(dV1.dt);
         po.dtLast = DateTime.dateFrom_yyyy_MM_dd_HH_mm_ss(dV1.dt);
         po.rtuDtLast = DateTime.dateFrom_yyyy_MM_dd_HH_mm_ss(cdData.rtuDt);
-        po.amount = 0.0D ;
+        if(cdData.isCloseValve != null && cdData.isCloseValve){
+            po.amount = cdData.amount ;
+            po.money = cdData.money ;
+            po.times = 1 ;
+        }else{
+            po.amount = 0.0D ;
+            po.money = 0.0D ;
+            po.times = 0 ;
+        }
         po.rtuAddrLast = rtuAddr;
         return po ;
     }
@@ -177,8 +185,12 @@
         po.rtuDtLast = DateTime.dateFrom_yyyy_MM_dd_HH_mm_ss(cdData.rtuDt);
         if(lastPo != null){
             po.amount = lastPo.amount ;
+            po.money = lastPo.money ;
+            po.times = lastPo.times ;
         }else{
             po.amount = 0.0D ;
+            po.money = 0.0D ;
+            po.times = 0 ;
         }
         po.totalAmountLast = cdData.totalAmount ;
         return po ;
@@ -206,7 +218,7 @@
 
 
     /**
-     * 鐢熸垚鏂扮殑鎺у埗鍣ㄦ紡鎹熸棩缁熻鏈�鏂拌褰�
+     * 鍙栨按鍙f洿鎹簡鎺у埗鍣ㄥ湪锛屾鏃跺彧鏇存柊閮ㄥ垎灞炴��
      * @param controller
      * @param rtuAddr
      * @param dV1
@@ -262,6 +274,22 @@
                 //鏈缃噺鍊间笉鍙橈紝涓嬫鍐嶄笂鎶ユ椂锛屽氨鑳芥甯歌绠椾簡銆�
                 //lastPo.amount = lastPo.amount ; //鏃ョ疮璁″彇姘撮噺涓嶅彉
             }
+            if(cdData.isCloseValve != null && cdData.isCloseValve.booleanValue()){
+                //鏄粠鍏抽榾鎶ヤ腑寰楀埌鐨勬暟鎹�
+                if(lastPo.money == null){
+                    lastPo.money = cdData.money ;
+                }else{
+                    lastPo.money += cdData.money ;
+                }
+                if(lastPo.times == null){
+                    lastPo.times = 1 ;
+                }else{
+                    lastPo.times += 1 ;
+                }
+            }else{
+                lastPo.money = 0.0D ;
+                lastPo.times = 1 ;
+            }
             lastPo.totalAmountLast = cdData.totalAmount ;
         }
 
@@ -304,12 +332,20 @@
             lastPo.totalAmountLast = cdData.totalAmount ;
         }
 
+        if(cdData.isCloseValve != null && cdData.isCloseValve.booleanValue()){
+            //鏄粠鍏抽榾鎶ヤ腑寰楀埌鐨勬暟鎹�
+            lastPo.money = cdData.money ;
+            lastPo.times = 1 ;
+        }else{
+            lastPo.money = 0.0D ;
+            lastPo.times = 0 ;
+        }
 
         return lastPo ;
     }
 
     /**
-     * 鐢熸垚鏂扮殑鎺у埗鍣ㄦ紡鎹熸棩缁熻鏈�鏂拌褰�
+     * 鍙栨按鍙f洿鎹簡鎺у埗鍣ㄥ湪锛屾鏃跺彧鏇存柊閮ㄥ垎灞炴��
      * @param controller
      * @param rtuAddr
      * @param dV1
@@ -326,6 +362,8 @@
         po.rtuDtLast = lastPo.rtuDtLast;
 
         po.amount = lastPo.amount ;
+        po.money = lastPo.money ;
+        po.times = lastPo.times ;
         po.totalAmountLast = lastPo.totalAmountLast ;
 
         return po ;
@@ -349,6 +387,8 @@
         po.rtuDtLast = lastPo.rtuDtLast;
 
         po.amount = lastPo.amount ;//姝ゆ椂lastPo.amount宸茬粡澧炲姞涓婁簡澧為噺
+        po.money = lastPo.money ;//姝ゆ椂lastPo.money宸茬粡澧炲姞涓婁簡澧為噺
+        po.times = lastPo.times ;//姝ゆ椂lastPo.times宸茬粡澧炲姞涓婁簡澧為噺
         po.totalAmountLast = lastPo.totalAmountLast ;
 
         return po ;
@@ -357,6 +397,9 @@
 
     public class UpDataVo{
         public Double totalAmount; //绱娴侀噺锛�5瀛楄妭BCD鐮侊紝鍙栧�艰寖鍥�0~9999999999锛屽崟浣嶄负m3銆�
+        public Double amount; //鍐滄埛鐢ㄦ按閲�
+        public Double money ;//鍐滄埛娑堣垂閲戦
+        public Boolean isCloseValve ;//鏄惁鏄叧闃�涓婃姤
         public String rtuDt ;//鎺у埗鍣ㄦ椂閽�
 
         public void valueFrom(DataCdC0Vo voC0, DataCd84Vo vo84, DataCd83OpenVo vo83Op, DataCd83CloseVo vo83Cl){
@@ -371,6 +414,9 @@
                 this.rtuDt = vo83Op.rtuDt ;
             }else if(vo83Cl != null){
                 this.totalAmount = vo83Cl.totalAmount ;
+                this.amount = vo83Cl.thisAmount ;
+                this.money = vo83Cl.thisMoney ;
+                this.isCloseValve = true ;
                 this.rtuDt = vo83Cl.rtuDt ;
             }
         }
diff --git a/pipIrr-platform/pipIrr-web/pipIrr-web-statistics/src/main/java/com/dy/pipIrrStatistics/intake/IntakeSv.java b/pipIrr-platform/pipIrr-web/pipIrr-web-statistics/src/main/java/com/dy/pipIrrStatistics/intake/IntakeSv.java
index 98a7e5f..613d661 100644
--- a/pipIrr-platform/pipIrr-web/pipIrr-web-statistics/src/main/java/com/dy/pipIrrStatistics/intake/IntakeSv.java
+++ b/pipIrr-platform/pipIrr-web/pipIrr-web-statistics/src/main/java/com/dy/pipIrrStatistics/intake/IntakeSv.java
@@ -1,5 +1,6 @@
 package com.dy.pipIrrStatistics.intake;
 
+import com.dy.common.util.DateTime;
 import com.dy.common.webUtil.QueryResultVo;
 import com.dy.pipIrrGlobal.daoRm.*;
 import com.dy.pipIrrGlobal.voSt.*;
@@ -94,7 +95,7 @@
         return rsVo ;
     }
 
-    /**
+    /** ok 1
      * 鑾峰彇绱娴侀噺瓒呰繃鎸囧畾鍊肩殑鍙栨按鍙�
      * @param qo
      * @return
@@ -116,7 +117,7 @@
         return rsVo ;
     }
 
-    /**
+    /** ok 2
      * 鑾峰彇绱娴侀噺浣庝簬鎸囧畾鍊肩殑鍙栨按鍙�
      * @param qo
      * @return
@@ -476,7 +477,7 @@
         return rsVo ;
     }
 
-    /**
+    /** ok 3
      * 鎸囧畾鏃堕棿娈靛唴鐢ㄦ按閲忚秴杩囨寚瀹氬�肩殑鍙栨按鍙�
      * @param qo
      * @return
@@ -484,37 +485,31 @@
     public QueryResultVo<List<VoIntakeAccumulateAmount>> getUseWaterGtValueIntakes(IntakeAmountValueQO qo) {
         String timeStart = qo.getTimeStart();
         String timeStop = qo.getTimeStop();
-        if(timeStart != null && timeStart != "") {
-            timeStart = timeStart + " 00:00:00";
-        } else {
-            timeStart = LocalDate.now() + " 00:00:00";
+        if(timeStart == null || timeStart.trim().equals("")) {
+            timeStart = DateTime.yyyy_MM_dd() ;
+            qo.setTimeStart(timeStart);
         }
-        qo.setTimeStart(timeStart);
-
-        if(timeStop != null && timeStop != "") {
-            timeStop = timeStop + " 23:59:59";
-        }else {
-            timeStop = LocalDate.now() + " 23:59:59";
+        if(timeStop == null || timeStop.trim().equals("")) {
+            timeStop = DateTime.yyyy_MM_dd() ;
+            qo.setTimeStop(timeStop);
         }
-        qo.setTimeStop(timeStop);
-
         if (qo.getValue() == null){
             qo.setValue(0.0);
         }
 
         Map<String, Object> params = (Map<String, Object>) PojoUtils.generalize(qo);
-        Long itemTotal = rmOpenCloseValveHistoryMapper.getUseWaterGtValueIntakesCount(params);
+        Long itemTotal = rmIntakeAmountDayMapper.getUseWaterGtValueIntakesCount(params);
 
         QueryResultVo<List<VoIntakeAccumulateAmount>> rsVo = new QueryResultVo<>() ;
         rsVo.pageSize = qo.pageSize ;
         rsVo.pageCurr = qo.pageCurr ;
 
         rsVo.calculateAndSet(itemTotal, params);
-        rsVo.obj = rmOpenCloseValveHistoryMapper.getUseWaterGtValueIntakes(params);
+        rsVo.obj = rmIntakeAmountDayMapper.getUseWaterGtValueIntakes(params);
         return rsVo ;
     }
 
-    /**
+    /** ok 4
      * 鎸囧畾鏃堕棿娈靛唴娑堣垂閲戦瓒呰繃鎸囧畾鍊肩殑鍙栨按鍙�
      * @param qo
      * @return
@@ -522,36 +517,64 @@
     public QueryResultVo<List<VoIntakeAccumulateAmount>> getExpenseGtValueIntakes(IntakeAmountValueQO qo) {
         String timeStart = qo.getTimeStart();
         String timeStop = qo.getTimeStop();
-        if(timeStart != null && timeStart != "") {
-            timeStart = timeStart + " 00:00:00";
-        } else {
-            timeStart = LocalDate.now() + " 00:00:00";
+        if(timeStart == null || timeStart.trim().equals("")) {
+            timeStart = DateTime.yyyy_MM_dd() ;
+            qo.setTimeStart(timeStart);
         }
-        qo.setTimeStart(timeStart);
-
-        if(timeStop != null && timeStop != "") {
-            timeStop = timeStop + " 23:59:59";
-        }else {
-            timeStop = LocalDate.now() + " 23:59:59";
+        if(timeStop == null || timeStop.trim().equals("")) {
+            timeStop = DateTime.yyyy_MM_dd() ;
+            qo.setTimeStop(timeStop);
         }
-        qo.setTimeStop(timeStop);
-
         if (qo.getValue() == null){
             qo.setValue(0.0);
         }
 
         Map<String, Object> params = (Map<String, Object>) PojoUtils.generalize(qo);
-        Long itemTotal = rmOpenCloseValveHistoryMapper.getExpenseGtValueIntakesCount(params);
+        Long itemTotal = rmIntakeAmountDayMapper.getExpenseGtValueIntakesCount(params);
 
         QueryResultVo<List<VoIntakeAccumulateAmount>> rsVo = new QueryResultVo<>() ;
         rsVo.pageSize = qo.pageSize ;
         rsVo.pageCurr = qo.pageCurr ;
 
         rsVo.calculateAndSet(itemTotal, params);
-        rsVo.obj = rmOpenCloseValveHistoryMapper.getExpenseGtValueIntakes(params);
+        rsVo.obj = rmIntakeAmountDayMapper.getExpenseGtValueIntakes(params);
         return rsVo ;
     }
 
+    /** ok 4
+     * 鎸囧畾鏃堕棿娈靛唴娑堣垂閲戦瓒呰繃鎸囧畾鍊肩殑鍙栨按鍙�
+     * @param qo
+     * @return
+     */
+    public QueryResultVo<List<VoIntakeAccumulateAmount>> getUseWaterTimesGtValueIntakes(IntakeCountValueQO qo) {
+        String timeStart = qo.getTimeStart();
+        String timeStop = qo.getTimeStop();
+        if(timeStart == null || timeStart.trim().equals("")) {
+            timeStart = DateTime.yyyy_MM_dd() ;
+            qo.setTimeStart(timeStart);
+        }
+        if(timeStop == null || timeStop.trim().equals("")) {
+            timeStop = DateTime.yyyy_MM_dd() ;
+            qo.setTimeStop(timeStop);
+        }
+        if (qo.getValue() == null){
+            qo.setValue(0);
+        }
+
+        Map<String, Object> params = (Map<String, Object>) PojoUtils.generalize(qo);
+        Long itemTotal = rmIntakeAmountDayMapper.getUseWaterTimesGtValueIntakesCount(params);
+
+        QueryResultVo<List<VoIntakeAccumulateAmount>> rsVo = new QueryResultVo<>() ;
+        rsVo.pageSize = qo.pageSize ;
+        rsVo.pageCurr = qo.pageCurr ;
+
+        rsVo.calculateAndSet(itemTotal, params);
+        rsVo.obj = rmIntakeAmountDayMapper.getUseWaterTimesGtValueIntakes(params);
+        return rsVo ;
+    }
+
+
+
     /**
      * 鎸囧畾鏃堕棿娈靛唴鐢ㄦ按鏃堕暱瓒呰繃鎸囧畾鍊肩殑鍙栨按鍙�
      * @param qo
diff --git a/pipIrr-platform/pipIrr-web/pipIrr-web-statistics/src/main/java/com/dy/pipIrrStatistics/intake/IntkeCtrl.java b/pipIrr-platform/pipIrr-web/pipIrr-web-statistics/src/main/java/com/dy/pipIrrStatistics/intake/IntkeCtrl.java
index b87d9f7..5409a0a 100644
--- a/pipIrr-platform/pipIrr-web/pipIrr-web-statistics/src/main/java/com/dy/pipIrrStatistics/intake/IntkeCtrl.java
+++ b/pipIrr-platform/pipIrr-web/pipIrr-web-statistics/src/main/java/com/dy/pipIrrStatistics/intake/IntkeCtrl.java
@@ -55,7 +55,7 @@
         }
     }
 
-    /**
+    /** ok 1
      * 鑾峰彇绱娴侀噺瓒呰繃鎸囧畾鍊肩殑鍙栨按鍙�
      * @param qo
      * @return
@@ -74,7 +74,7 @@
         }
     }
 
-    /**
+    /** ok 2
      * 鑾峰彇绱娴侀噺浣庝簬鎸囧畾鍊肩殑鍙栨按鍙�
      * @param qo
      * @return
@@ -238,7 +238,7 @@
         }
     }
 
-    /**
+    /** ok 3
      * 鎸囧畾鏃堕棿娈靛唴鐢ㄦ按閲忚秴杩囨寚瀹氬�肩殑鍙栨按鍙�
      * @param
      * @return
@@ -255,7 +255,7 @@
         }
     }
 
-    /**
+    /** ok 4
      * 鎸囧畾鏃堕棿娈靛唴娑堣垂閲戦瓒呰繃鎸囧畾鍊肩殑鍙栨按鍙�
      * @param
      * @return
@@ -272,6 +272,22 @@
         }
     }
 
+    /**
+     * 鎸囧畾鏃堕棿娈靛唴鐢ㄦ按娆℃暟瓒呰繃鎸囧畾鍊肩殑鍙栨按鍙�
+     * @param
+     * @return
+     */
+    @GetMapping(path = "/getUseWaterTimesGtValueIntakes")
+    @SsoAop()
+    public BaseResponse<QueryResultVo<List<VoIntakeAccumulateAmount>>> getUseWaterTimesGtValueIntakes(IntakeCountValueQO qo) {
+        try {
+            QueryResultVo<List<VoIntakeAccumulateAmount>> res = intakeSv.getUseWaterTimesGtValueIntakes(qo);
+            return BaseResponseUtils.buildSuccess(res);
+        } catch (Exception e) {
+            log.error("鑾峰彇璁板綍寮傚父", e);
+            return BaseResponseUtils.buildException(e.getMessage()) ;
+        }
+    }
 
     /**
      * 鎸囧畾鏃堕棿娈靛唴鐢ㄦ按鏃堕暱瓒呰繃鎸囧畾鍊肩殑鍙栨按鍙�
diff --git a/pipIrr-platform/pipIrr-web/pipIrr-web-statistics/src/main/java/com/dy/pipIrrStatistics/intake/qo/IntakeCountValueQO.java b/pipIrr-platform/pipIrr-web/pipIrr-web-statistics/src/main/java/com/dy/pipIrrStatistics/intake/qo/IntakeCountValueQO.java
index 246c018..54a20f0 100644
--- a/pipIrr-platform/pipIrr-web/pipIrr-web-statistics/src/main/java/com/dy/pipIrrStatistics/intake/qo/IntakeCountValueQO.java
+++ b/pipIrr-platform/pipIrr-web/pipIrr-web-statistics/src/main/java/com/dy/pipIrrStatistics/intake/qo/IntakeCountValueQO.java
@@ -19,5 +19,5 @@
      * 鍊�
      */
     @NotBlank(message = "鍊间笉鑳戒负绌�")
-    private int value;
+    private Integer value;
 }

--
Gitblit v1.8.0