Administrator
2024-08-07 f0266c2993a9587cab4c9480089e3e83d8820198
Merge branch 'master' of http://8.140.179.55:20000/r/pipIrr-SV

 Conflicts:
 pipIrr-platform/pipIrr-global/src/main/resources/application-global.yml
15个文件已修改
470 ■■■■ 已修改文件
pipIrr-platform/pipIrr-common/src/main/java/com/dy/common/mw/protocol/p206V1_0_0/CommonV1_0_1.java 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
pipIrr-platform/pipIrr-common/src/main/java/com/dy/common/mw/protocol/p206V1_0_0/parse/Cd_99_Down.java 12 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
pipIrr-platform/pipIrr-common/src/main/java/com/dy/common/mw/protocol/p206V1_0_0/parse/Cd_A0_Down.java 14 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
pipIrr-platform/pipIrr-common/src/main/java/com/dy/common/mw/protocol/p206V1_0_0/parse/Cd_A1_Down.java 12 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
pipIrr-platform/pipIrr-common/src/main/java/com/dy/common/mw/protocol/p206V1_0_0/parse/Cd_A2_Down.java 14 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/daoRm/RmOnHourReportHistoryMapper.java 8 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/daoRm/RmOpenCloseValveHistoryMapper.java 43 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/voSt/VoIntakeAccumulateAmount.java 4 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/voSt/VoIntakeOpenCount.java 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
pipIrr-platform/pipIrr-global/src/main/resources/application-global.yml 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
pipIrr-platform/pipIrr-global/src/main/resources/mapper/RmOnHourReportHistoryMapper.xml 8 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
pipIrr-platform/pipIrr-global/src/main/resources/mapper/RmOpenCloseValveHistoryMapper.xml 117 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
pipIrr-platform/pipIrr-web/pipIrr-mwTest-web/src/main/java/com/dy/pipIrrMwTestWeb/p206V1_0_0/CommandP206V1_0_0Ctrl.java 10 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
pipIrr-platform/pipIrr-web/pipIrr-web-statistics/src/main/java/com/dy/pipIrrStatistics/intake/IntakeSv.java 120 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
pipIrr-platform/pipIrr-web/pipIrr-web-statistics/src/main/java/com/dy/pipIrrStatistics/intake/IntkeCtrl.java 96 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
pipIrr-platform/pipIrr-common/src/main/java/com/dy/common/mw/protocol/p206V1_0_0/CommonV1_0_1.java
@@ -170,7 +170,7 @@
     * 2:刷卡关阀;
     * 3:中心站开阀;
     * 4:中心站关阀;
     * 5:欠费关阀;
     * 5:余额不足关阀;
     * 6:流量计故障关阀;
     * 7:紧急关闭;
     * 8:用户远程开阀;
@@ -190,7 +190,7 @@
            case 2 -> "刷卡关阀";
            case 3 -> "中心站开阀";
            case 4 -> "中心站关阀";
            case 5 -> "欠费关阀";
            case 5 -> "余额不足关阀";
            case 6 -> "流量计故障关阀";
            case 7 -> "紧急关阀";
            case 8 -> "用户远程开阀";
pipIrr-platform/pipIrr-common/src/main/java/com/dy/common/mw/protocol/p206V1_0_0/parse/Cd_99_Down.java
@@ -84,14 +84,14 @@
        if(cvo.icCardNo == null){
            throw new Exception("虚拟IC卡编号不能为空") ;
        }
        if(cvo.moneyRemain == null){
            throw new Exception("剩余金额不能为空") ;
        if(cvo.moneyRemain == null || cvo.moneyRemain == 0.0){
            throw new Exception("剩余金额不能为空或为0") ;
        }
        if(cvo.waterPrice == null){
            throw new Exception("水价不能为空") ;
        if(cvo.waterPrice == null || cvo.waterPrice == 0.0){
            throw new Exception("水价不能为空或为0") ;
        }
        if(cvo.minutes == null){
            throw new Exception("用水时长不能为空") ;
        if(cvo.minutes == null || cvo.minutes == 0.0){
            throw new Exception("用水时长不能为空或为0") ;
        }
       if(cvo.minutes < 0 || cvo.minutes > 9999){
            throw new Exception("用水时长取值范围是0~9999分钟") ;
pipIrr-platform/pipIrr-common/src/main/java/com/dy/common/mw/protocol/p206V1_0_0/parse/Cd_A0_Down.java
@@ -84,14 +84,14 @@
        if(cvo.icCardNo == null){
            throw new Exception("虚拟IC卡编号不能为空") ;
        }
        if(cvo.moneyRemain == null){
            throw new Exception("剩余金额不能为空") ;
        if(cvo.moneyRemain == null || cvo.moneyRemain == 0.0){
            throw new Exception("剩余金额不能为空或为0") ;
        }
        if(cvo.waterPrice == null){
            throw new Exception("水价不能为空") ;
        if(cvo.waterPrice == null || cvo.waterPrice == 0.0){
            throw new Exception("水价不能为空或为0") ;
        }
        if(cvo.waterAmount == null){
            throw new Exception("预用水量不能为空") ;
        if(cvo.waterAmount == null || cvo.waterAmount == 0.0){
            throw new Exception("预用水量不能为空或为0") ;
        }
       if(cvo.waterAmount < 0 || cvo.waterAmount > 9999){
            throw new Exception("预用水量取值范围是0~9999m3") ;
@@ -102,7 +102,7 @@
        //    midRs.param = icCardNoGrp[0] ;
        //}
        //ByteUtil.string2BCD_LE(bs, icCardNoGrp[1], index) ;
        byte[] bs = new byte[16] ;
        byte[] bs = new byte[8] ;
        index = 0 ;
        GlCreate.createIcCardNo(cvo.icCardNo, bs, 0);
        bytes = ByteUtil.bytesMerge(bsHead, bs) ;
pipIrr-platform/pipIrr-common/src/main/java/com/dy/common/mw/protocol/p206V1_0_0/parse/Cd_A1_Down.java
@@ -85,14 +85,14 @@
        if(cvo.icCardNo == null){
            throw new Exception("虚拟IC卡编号不能为空") ;
        }
        if(cvo.moneyRemain == null){
            throw new Exception("剩余金额不能为空") ;
        if(cvo.moneyRemain == null || cvo.moneyRemain == 0.0){
            throw new Exception("剩余金额不能为空或为0") ;
        }
        if(cvo.waterPrice == null){
            throw new Exception("水价不能为空") ;
        if(cvo.waterPrice == null || cvo.waterPrice == 0.0){
            throw new Exception("水价不能为空或为0") ;
        }
        if(cvo.minutes == null){
            throw new Exception("用水时长不能为空") ;
        if(cvo.minutes == null || cvo.minutes == 0.0){
            throw new Exception("用水时长不能为空或为0") ;
        }
        if(cvo.minutes < 0 || cvo.minutes > 9999){
            throw new Exception("用水时长取值范围是0~9999分钟") ;
pipIrr-platform/pipIrr-common/src/main/java/com/dy/common/mw/protocol/p206V1_0_0/parse/Cd_A2_Down.java
@@ -85,14 +85,14 @@
        if(cvo.icCardNo == null){
            throw new Exception("虚拟IC卡编号不能为空") ;
        }
        if(cvo.moneyRemain == null){
            throw new Exception("剩余金额不能为空") ;
        if(cvo.moneyRemain == null || cvo.moneyRemain == 0.0){
            throw new Exception("剩余金额不能为空或为0") ;
        }
        if(cvo.waterPrice == null){
            throw new Exception("水价不能为空") ;
        if(cvo.waterPrice == null || cvo.waterPrice == 0.0){
            throw new Exception("水价不能为空或为0") ;
        }
        if(cvo.waterAmount == null){
            throw new Exception("预用水量不能为空") ;
        if(cvo.waterAmount == null || cvo.waterAmount == 0.0){
            throw new Exception("预用水量不能为空或为0") ;
        }
       if(cvo.waterAmount < 0 || cvo.waterAmount > 9999){
            throw new Exception("预用水量取值范围是0~9999m3") ;
@@ -136,7 +136,7 @@
        //    midRs.param = icCardNoGrp[0] ;
        //}
        //ByteUtil.string2BCD_LE(bs, icCardNoGrp[1], index) ;
        byte[] bs = new byte[16] ;
        byte[] bs = new byte[8] ;
        index = 0 ;
        GlCreate.createIcCardNo(cvo.icCardNo, bs, 0);
        bytes = ByteUtil.bytesMerge(bsHead, bs) ;
pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/daoRm/RmOnHourReportHistoryMapper.java
@@ -88,16 +88,16 @@
    List<VoIntake> getNotOnlineIntakes(Map<?, ?> params);
    /**
     * 指定时间段内用水量超过指定值的取水口数量
     * 指定时间段内累积流量超过指定值的取水口数量
     * @param params
     * @return
     */
    Long getUseWaterGtValueIntakesCount(Map<String, Object> params);
    Long getTotalFlowGtValueIntakesCount(Map<String, Object> params);
    /**
     * 指定时间段内用水量超过指定值的取水口
     * 指定时间段内累积流量超过指定值的取水口
     * @param params
     * @return
     */
    List<VoIntakeAccumulateAmount> getUseWaterGtValueIntakes(Map<String, Object> params);
    List<VoIntakeAccumulateAmount> getTotalFlowGtValueIntakes(Map<String, Object> params);
}
pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/daoRm/RmOpenCloseValveHistoryMapper.java
@@ -5,6 +5,7 @@
import com.dy.pipIrrGlobal.voRm.VoOpenCloseValve;
import com.dy.pipIrrGlobal.voSt.VoClient;
import com.dy.pipIrrGlobal.voSt.VoIntake;
import com.dy.pipIrrGlobal.voSt.VoIntakeAccumulateAmount;
import com.dy.pipIrrGlobal.voSt.VoIntakeOpenCount;
import org.apache.ibatis.annotations.Mapper;
@@ -192,4 +193,46 @@
     * @return
     */
    List<VoClient> getLargeWaterDurationClients(Map<String, Object> params);
    /**
     * 指定时间段用水量超过指定值的取水口数量
     * @param params
     * @return
     */
    Long getUseWaterGtValueIntakesCount(Map<String, Object> params);
    /**
     * 指定时间段用水量超过指定值的取水口
     * @param params
     * @return
     */
    List<VoIntakeAccumulateAmount> getUseWaterGtValueIntakes(Map<String, Object> params);
    /**
     * 指定时间段内消费金额超过指定值的取水口的数量
     * @param params
     * @return
     */
    Long getExpenseGtValueIntakesCount(Map<String, Object> params);
    /**
     * 指定时间段内消费金额超过指定值的取水口
     * @param params
     * @return
     */
    List<VoIntakeAccumulateAmount> getExpenseGtValueIntakes(Map<String, Object> params);
    /**
     * 指定时间段内用水时长超过指定值的取水口数量
     * @param params
     * @return
     */
    Long getUseWaterDurationGtValueIntakesCount(Map<String, Object> params);
    /**
     * 指定时间段内用水时长超过指定值的取水口
     * @param params
     * @return
     */
    List<VoIntakeOpenCount> getUseWaterDurationGtValueIntakes(Map<String, Object> params);
}
pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/voSt/VoIntakeAccumulateAmount.java
@@ -6,7 +6,9 @@
 * @author :WuZeYu
 * @Date :2024/8/5  10:45
 * @LastEditTime :2024/8/5  10:45
 * @Description 取水口累积流量 大于 指定值
 * @Description 取水口 累积流量 大于 指定值  视图
 *                    用水量 大于 指定值
 *                    消费金额 大于 指定值
 */
@Data
public class VoIntakeAccumulateAmount extends VoIntake{
pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/voSt/VoIntakeOpenCount.java
@@ -1,14 +1,14 @@
package com.dy.pipIrrGlobal.voSt;
import com.alibaba.fastjson2.annotation.JSONField;
import com.alibaba.fastjson2.writer.ObjectWriterImplToString;
import lombok.Data;
/**
 * @author :WuZeYu
 * @Date :2024/8/5  10:45
 * @LastEditTime :2024/8/5  10:45
 * @Description 取水口开阀 指定值 次数
 * @Description 取水口开阀 >  指定值 (次数)
 *                用水时长 > 指定值  (分钟)
 */
@Data
public class VoIntakeOpenCount extends VoIntake{
pipIrr-platform/pipIrr-global/src/main/resources/application-global.yml
@@ -72,7 +72,7 @@
pipIrr:
    global:
        dev: true   #是否开发阶段,true或false
        dev: flase   #是否开发阶段,true或false
        dsName: ym  #开发阶段,设置临时的数据库名称
    mw:
        webPort: 8070
pipIrr-platform/pipIrr-global/src/main/resources/mapper/RmOnHourReportHistoryMapper.xml
@@ -283,8 +283,8 @@
      </if>
    </trim>
  </select>
  <!--指定时间段内用水量超过指定值的取水口数量-->
  <select id="getUseWaterGtValueIntakesCount" resultType="java.lang.Long">
  <!--指定时间段内累积流量超过指定值的取水口数量-->
  <select id="getTotalFlowGtValueIntakesCount" resultType="java.lang.Long">
    select
    count(*)
    from
@@ -316,8 +316,8 @@
    WHERE IFNULL(b.total_amount, 0)-IFNULL(a.total_amount, 0) &gt; #{value} AND inta.deleted = 0
    ) c
    </select>
  <!--指定时间段内用水量超过指定值的取水口-->
  <select id="getUseWaterGtValueIntakes" resultType="com.dy.pipIrrGlobal.voSt.VoIntakeAccumulateAmount">
  <!--指定时间段内累积流量超过指定值的取水口-->
  <select id="getTotalFlowGtValueIntakes" resultType="com.dy.pipIrrGlobal.voSt.VoIntakeAccumulateAmount">
    SELECT
      inta.id AS intakeId,
      inta.NAME AS intakeNum,
pipIrr-platform/pipIrr-global/src/main/resources/mapper/RmOpenCloseValveHistoryMapper.xml
@@ -878,4 +878,121 @@
            </if>
        </trim>
    </select>
    <!--指定时间段用水量超过指定值的取水口数量-->
    <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>
    <!--指定时间段内消费金额超过指定值的取水口的数量-->
    <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>
    <!--指定时间段内用水时长超过指定值的取水口数量-->
    <select id="getUseWaterDurationGtValueIntakesCount" 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_time),0) AS recordCount
        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_time),0) &gt; #{value}) c
    </select>
    <!--指定时间段内用水时长超过指定值的取水口-->
    <select id="getUseWaterDurationGtValueIntakes" resultType="com.dy.pipIrrGlobal.voSt.VoIntakeOpenCount">
        SELECT
        inta.id AS intakeId,
        inta.NAME AS intakeNum,
        blo.NAME AS blockName ,
        IFNULL(SUM(rocvh.cl_this_time),0) AS recordCount
        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_time),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>
</mapper>
pipIrr-platform/pipIrr-web/pipIrr-mwTest-web/src/main/java/com/dy/pipIrrMwTestWeb/p206V1_0_0/CommandP206V1_0_0Ctrl.java
@@ -228,7 +228,7 @@
    private BaseResponse cdA0(){
        ComA0Vo comVo = new ComA0Vo() ;
        comVo.icCardNo = CommandP206V1_0_0Ctrl.vsIcCardNo;
        comVo.moneyRemain = 234.56 ;
        comVo.moneyRemain = 1.23 ;
        comVo.waterPrice = 1.2 ;
        comVo.waterAmount = 10 ;
        return this.sendCom2Mw(this.commandOuter(CodeV1_0_1.cd_A0, comVo, null)) ;
@@ -239,10 +239,10 @@
    private BaseResponse cdA1() throws Exception {
        ComA1Vo comVo = new ComA1Vo() ;
        comVo.icCardNo = CommandP206V1_0_0Ctrl.vsIcCardNo;
        comVo.moneyRemain = 234.56 ;
        comVo.moneyRemain = 1.23 ;
        comVo.waterPrice = 1.2 ;
        comVo.minutes = 3 ;
        String nextDtStr = DateTime.nextXMinute_yyyy_MM_dd_HH_mm_ss(DateTime.yyyy_MM_dd_HH_mm_ss(), comVo.minutes) ;//将来X分钟
        comVo.minutes = 30 ;
        String nextDtStr = DateTime.nextXMinute_yyyy_MM_dd_HH_mm_ss(DateTime.yyyy_MM_dd_HH_mm_ss(), 3) ;//将来X分钟
        int[] nextDt = DateTime.yyyy_MM_dd_HH_MM_SS_2_ymdhmsGroup(nextDtStr) ;
        comVo.year = nextDt[0] ;
        comVo.month = nextDt[1] ;
@@ -259,7 +259,7 @@
        comVo.moneyRemain = 234.56 ;
        comVo.waterPrice = 1.2 ;
        comVo.waterAmount = 10 ;
        String nextDtStr = DateTime.nextXMinute_yyyy_MM_dd_HH_mm_ss(DateTime.yyyy_MM_dd_HH_mm_ss(), 5) ;//将来5分钟
        String nextDtStr = DateTime.nextXMinute_yyyy_MM_dd_HH_mm_ss(DateTime.yyyy_MM_dd_HH_mm_ss(), 3) ;//将来X分钟
        int[] nextDt = DateTime.yyyy_MM_dd_HH_MM_SS_2_ymdhmsGroup(nextDtStr) ;
        comVo.year = nextDt[0] ;
        comVo.month = nextDt[1] ;
pipIrr-platform/pipIrr-web/pipIrr-web-statistics/src/main/java/com/dy/pipIrrStatistics/intake/IntakeSv.java
@@ -424,6 +424,46 @@
    }
    /**
     * 指定时间段内累积流量超过指定值的取水口
     * @param qo
     * @return
     */
    public QueryResultVo<List<VoIntakeAccumulateAmount>> getTotalFlowGtValueIntakes(IntakeAmountValueQO qo) {
        String timeStart = qo.getTimeStart();
        String timeStop = qo.getTimeStop();
        if(timeStart != null && timeStart != "") {
            timeStart = timeStart + " 00:00:00";
        } else {
            timeStart = LocalDateTime.of(2024, 1, 1, 0, 0, 0).toString();
        }
        qo.setTimeStart(timeStart);
        if(timeStop != null && timeStop != "") {
            timeStop = timeStop + " 23:59:59";
        }else {
            timeStop = LocalDate.now() + " 23:59:59";
        }
        qo.setTimeStop(timeStop);
        if (qo.getValue() == null){
            qo.setValue(0.0);
        }
        Map<String, Object> params = (Map<String, Object>) PojoUtils.generalize(qo);
        Long itemTotal = rmOnHourReportHistoryMapper.getTotalFlowGtValueIntakesCount(params);
        QueryResultVo<List<VoIntakeAccumulateAmount>> rsVo = new QueryResultVo<>() ;
        rsVo.pageSize = qo.pageSize ;
        rsVo.pageCurr = qo.pageCurr ;
        rsVo.calculateAndSet(itemTotal, params);
        rsVo.obj = rmOnHourReportHistoryMapper.getTotalFlowGtValueIntakes(params);
        return rsVo ;
    }
    /**
     * 指定时间段内用水量超过指定值的取水口
     * @param qo
     * @return
@@ -451,14 +491,90 @@
        Map<String, Object> params = (Map<String, Object>) PojoUtils.generalize(qo);
        Long itemTotal = rmOnHourReportHistoryMapper.getUseWaterGtValueIntakesCount(params);
        Long itemTotal = rmOpenCloseValveHistoryMapper.getUseWaterGtValueIntakesCount(params);
        QueryResultVo<List<VoIntakeAccumulateAmount>> rsVo = new QueryResultVo<>() ;
        rsVo.pageSize = qo.pageSize ;
        rsVo.pageCurr = qo.pageCurr ;
        rsVo.calculateAndSet(itemTotal, params);
        rsVo.obj = rmOnHourReportHistoryMapper.getUseWaterGtValueIntakes(params);
        rsVo.obj = rmOpenCloseValveHistoryMapper.getUseWaterGtValueIntakes(params);
        return rsVo ;
    }
    /**
     * 指定时间段内消费金额超过指定值的取水口
     * @param qo
     * @return
     */
    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 = LocalDateTime.of(2024, 1, 1, 0, 0, 0).toString();
        }
        qo.setTimeStart(timeStart);
        if(timeStop != null && timeStop != "") {
            timeStop = timeStop + " 23:59:59";
        }else {
            timeStop = LocalDate.now() + " 23:59:59";
        }
        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);
        QueryResultVo<List<VoIntakeAccumulateAmount>> rsVo = new QueryResultVo<>() ;
        rsVo.pageSize = qo.pageSize ;
        rsVo.pageCurr = qo.pageCurr ;
        rsVo.calculateAndSet(itemTotal, params);
        rsVo.obj = rmOpenCloseValveHistoryMapper.getExpenseGtValueIntakes(params);
        return rsVo ;
    }
    /**
     * 指定时间段内用水时长超过指定值的取水口
     * @param qo
     * @return
     */
    public QueryResultVo<List<VoIntakeOpenCount>> getUseWaterDurationGtValueIntakes(IntakeCountValueQO qo) {
        String timeStart = qo.getTimeStart();
        String timeStop = qo.getTimeStop();
        if(timeStart != null && timeStart != "") {
            timeStart = timeStart + " 00:00:00";
        } else {
            timeStart = LocalDateTime.of(2024, 1, 1, 0, 0, 0).toString();
        }
        qo.setTimeStart(timeStart);
        if(timeStop != null && timeStop != "") {
            timeStop = timeStop + " 23:59:59";
        }else {
            timeStop = LocalDate.now() + " 23:59:59";
        }
        qo.setTimeStop(timeStop);
        Map<String, Object> params = (Map<String, Object>) PojoUtils.generalize(qo);
        Long itemTotal = rmOpenCloseValveHistoryMapper.getUseWaterDurationGtValueIntakesCount(params);
        QueryResultVo<List<VoIntakeOpenCount>> rsVo = new QueryResultVo<>() ;
        rsVo.pageSize = qo.pageSize ;
        rsVo.pageCurr = qo.pageCurr ;
        rsVo.calculateAndSet(itemTotal, params);
        rsVo.obj = rmOpenCloseValveHistoryMapper.getUseWaterDurationGtValueIntakes(params);
        return rsVo ;
    }
}
pipIrr-platform/pipIrr-web/pipIrr-web-statistics/src/main/java/com/dy/pipIrrStatistics/intake/IntkeCtrl.java
@@ -183,12 +183,12 @@
     */
    @GetMapping(path = "/getNeverOpenValveIntakes")
    @SsoAop()
    public BaseResponse<QueryResultVo<List<VoIntake>>> getNeverOpenValveIntakes(CommonQO qo) {
    public BaseResponse<QueryResultVo<List<VoIntake>>> getNeverOpenValveIntakes(@Valid CommonQO qo, BindingResult bindingResult) {
        if(bindingResult != null && bindingResult.hasErrors()){
            return BaseResponseUtils.buildFail(Objects.requireNonNull(bindingResult.getFieldError()).getDefaultMessage());
        }
        try {
            QueryResultVo<List<VoIntake>> res = intakeSv.getNeverOpenValveIntakes(qo);
            if(res.itemTotal == 0) {
                return BaseResponseUtils.buildErrorMsg(StatisticlResultCode.NO_RECORDS.getMessage());
            }
            return BaseResponseUtils.buildSuccess(res);
        } catch (Exception e) {
            log.error("获取记录异常", e);
@@ -204,12 +204,12 @@
     */
    @GetMapping(path = "/getOpenValveGtIntakes")
    @SsoAop()
    public BaseResponse<QueryResultVo<List<VoIntakeOpenCount>>> getOpenValveGtIntakes(IntakeCountValueQO qo) {
    public BaseResponse<QueryResultVo<List<VoIntakeOpenCount>>> getOpenValveGtIntakes(@Valid IntakeCountValueQO qo, BindingResult bindingResult) {
        if(bindingResult != null && bindingResult.hasErrors()){
            return BaseResponseUtils.buildFail(Objects.requireNonNull(bindingResult.getFieldError()).getDefaultMessage());
        }
        try {
            QueryResultVo<List<VoIntakeOpenCount>> res = intakeSv.getOpenValveGtIntakes(qo);
            if(res.itemTotal == 0) {
                return BaseResponseUtils.buildErrorMsg(StatisticlResultCode.NO_RECORDS.getMessage());
            }
            return BaseResponseUtils.buildSuccess(res);
        } catch (Exception e) {
            log.error("获取记录异常", e);
@@ -225,12 +225,33 @@
     */
    @GetMapping(path = "/getOpenValveLtIntakes")
    @SsoAop()
    public BaseResponse<QueryResultVo<List<VoIntakeOpenCount>>> getOpenValveLtIntakes(IntakeCountValueQO qo) {
    public BaseResponse<QueryResultVo<List<VoIntakeOpenCount>>> getOpenValveLtIntakes(@Valid IntakeCountValueQO qo, BindingResult bindingResult) {
        if(bindingResult != null && bindingResult.hasErrors()){
            return BaseResponseUtils.buildFail(Objects.requireNonNull(bindingResult.getFieldError()).getDefaultMessage());
        }
        try {
            QueryResultVo<List<VoIntakeOpenCount>> res = intakeSv.getOpenValveLtIntakes(qo);
            if(res.itemTotal == 0) {
                return BaseResponseUtils.buildErrorMsg(StatisticlResultCode.NO_RECORDS.getMessage());
            }
            return BaseResponseUtils.buildSuccess(res);
        } catch (Exception e) {
            log.error("获取记录异常", e);
            return BaseResponseUtils.buildException(e.getMessage()) ;
        }
    }
    /**
     * 指定时间段内累积流量(定时报里的累积流量)超过指定值的取水口
     * @param
     * @return
     */
    @GetMapping(path = "/getTotalFlowGtValueIntakes")
    @SsoAop()
    public BaseResponse<QueryResultVo<List<VoIntakeAccumulateAmount>>> getTotalFlowGtValueIntakes(@Valid IntakeAmountValueQO qo, BindingResult bindingResult) {
        if(bindingResult != null && bindingResult.hasErrors()){
            return BaseResponseUtils.buildFail(Objects.requireNonNull(bindingResult.getFieldError()).getDefaultMessage());
        }
        try {
            QueryResultVo<List<VoIntakeAccumulateAmount>> res = intakeSv.getTotalFlowGtValueIntakes(qo);
            return BaseResponseUtils.buildSuccess(res);
        } catch (Exception e) {
            log.error("获取记录异常", e);
@@ -246,12 +267,55 @@
     */
    @GetMapping(path = "/getUseWaterGtValueIntakes")
    @SsoAop()
    public BaseResponse<QueryResultVo<List<VoIntakeAccumulateAmount>>> getUseWaterGtValueIntakes(IntakeAmountValueQO qo) {
    public BaseResponse<QueryResultVo<List<VoIntakeAccumulateAmount>>> getUseWaterGtValueIntakes(@Valid IntakeAmountValueQO qo, BindingResult bindingResult) {
        if(bindingResult != null && bindingResult.hasErrors()){
            return BaseResponseUtils.buildFail(Objects.requireNonNull(bindingResult.getFieldError()).getDefaultMessage());
        }
        try {
            QueryResultVo<List<VoIntakeAccumulateAmount>> res = intakeSv.getUseWaterGtValueIntakes(qo);
            if(res.itemTotal == 0) {
                return BaseResponseUtils.buildErrorMsg(StatisticlResultCode.NO_RECORDS.getMessage());
            }
            return BaseResponseUtils.buildSuccess(res);
        } catch (Exception e) {
            log.error("获取记录异常", e);
            return BaseResponseUtils.buildException(e.getMessage()) ;
        }
    }
    /**
     * 指定时间段内消费金额超过指定值的取水口
     * @param
     * @return
     */
    @GetMapping(path = "/getExpenseGtValueIntakes")
    @SsoAop()
    public BaseResponse<QueryResultVo<List<VoIntakeAccumulateAmount>>> getExpenseGtValueIntakes(@Valid IntakeAmountValueQO qo, BindingResult bindingResult) {
        if(bindingResult != null && bindingResult.hasErrors()){
            return BaseResponseUtils.buildFail(Objects.requireNonNull(bindingResult.getFieldError()).getDefaultMessage());
        }
        try {
            QueryResultVo<List<VoIntakeAccumulateAmount>> res = intakeSv.getExpenseGtValueIntakes(qo);
            return BaseResponseUtils.buildSuccess(res);
        } catch (Exception e) {
            log.error("获取记录异常", e);
            return BaseResponseUtils.buildException(e.getMessage()) ;
        }
    }
    /**
     * 指定时间段内用水时长超过指定值的取水口
     * @param
     * @return
     */
    @GetMapping(path = "/getUseWaterDurationGtValueIntakes")
    @SsoAop()
    public BaseResponse<QueryResultVo<List<VoIntakeOpenCount>>> getUseWaterDurationGtValueIntakes(@Valid IntakeCountValueQO qo, BindingResult bindingResult) {
        if(bindingResult != null && bindingResult.hasErrors()){
            return BaseResponseUtils.buildFail(Objects.requireNonNull(bindingResult.getFieldError()).getDefaultMessage());
        }
        try {
            QueryResultVo<List<VoIntakeOpenCount>> res = intakeSv.getUseWaterDurationGtValueIntakes(qo);
            return BaseResponseUtils.buildSuccess(res);
        } catch (Exception e) {
            log.error("获取记录异常", e);