pipIrr-platform/pipIrr-global/src/main/resources/mapper/RmLossDayMapper.xml
@@ -275,10 +275,10 @@
        from rm_loss_day
        <where>
          <if test="startDt != null ">
            AND dt <![CDATA[>=]]> #{startDt, jdbcType=DATE, jdbcType=DATE}
            AND dt <![CDATA[>=]]> #{startDt, javaType=DATE, jdbcType=DATE}
          </if>
          <if test="endDt != null ">
            AND dt <![CDATA[<]]> #{endDt, jdbcType=DATE, jdbcType=DATE}
            AND dt <![CDATA[<]]> #{endDt, javaType=DATE, jdbcType=DATE}
          </if>
        </where>
        order by intake_id DESC, id ASC
@@ -287,7 +287,6 @@
  <sql id="selectLossAmountOfDay_with">
    WITH intakeLossAmountDay AS (
      SELECT intaId.intakeId   AS intakeId,
             rld.dt            AS dt,
             rld.loss_amount   AS lossAmount
@@ -300,18 +299,17 @@
      INNER JOIN rm_loss_day rld ON rld.intake_id = intaId.intakeId
      <where>
        <if test="startDt != null ">
          AND rld.dt <![CDATA[>=]]> #{startDt, jdbcType=DATE, jdbcType=DATE}
          AND rld.dt <![CDATA[>=]]> #{startDt, javaType=DATE, jdbcType=DATE}
        </if>
        <if test="endDt != null ">
          AND rld.dt <![CDATA[<=]]> #{endDt, jdbcType=DATE, jdbcType=DATE}
          AND rld.dt <![CDATA[<=]]> #{endDt, javaType=DATE, jdbcType=DATE}
        </if>
      </where>
    )
  </sql>
  <!--统计指定月份各天漏损量(1号到5号)-->
  <select id="selectLossAmountOfDay01_05" resultType="com.dy.pipIrrGlobal.voSt.VoDayLoss">
    <include refid="selectLossAmountOfDay_with" />
    WITH intakeLossAmountDay AS (<include refid="selectLossAmountOfDay_with"/>)
    SELECT inta.intakeId     AS intakeId,
           inta.intakeNum    AS intakeNum,
           inta.intakeLng    AS intakeLng,
@@ -375,7 +373,7 @@
  <!--统计指定月份各天漏损量(6号到10号)-->
  <select id="selectLossAmountOfDay06_10" resultType="com.dy.pipIrrGlobal.voSt.VoDayLoss">
    <include refid="selectLossAmountOfDay_with" />
    WITH intakeLossAmountDay AS (<include refid="selectLossAmountOfDay_with"/>)
    SELECT inta.intakeId     AS intakeId,
           inta.intakeNum    AS intakeNum,
           inta.intakeLng    AS intakeLng,
@@ -438,7 +436,7 @@
  <!--统计指定月份各天漏损量(11号到15号)-->
  <select id="selectLossAmountOfDay11_15" resultType="com.dy.pipIrrGlobal.voSt.VoDayLoss">
    <include refid="selectLossAmountOfDay_with" />
    WITH intakeLossAmountDay AS (<include refid="selectLossAmountOfDay_with"/>)
    SELECT inta.intakeId     AS intakeId,
           inta.intakeNum    AS intakeNum,
           inta.intakeLng    AS intakeLng,
@@ -501,7 +499,7 @@
  <!--统计指定月份各天漏损量(20号到16号)-->
  <select id="selectLossAmountOfDay16_20" resultType="com.dy.pipIrrGlobal.voSt.VoDayLoss">
    <include refid="selectLossAmountOfDay_with" />
    WITH intakeLossAmountDay AS (<include refid="selectLossAmountOfDay_with"/>)
    SELECT inta.intakeId     AS intakeId,
           inta.intakeNum    AS intakeNum,
           inta.intakeLng    AS intakeLng,
@@ -564,7 +562,7 @@
  <!--统计指定月份各天漏损量(21号到25号)-->
  <select id="selectLossAmountOfDay21_25" resultType="com.dy.pipIrrGlobal.voSt.VoDayLoss">
    <include refid="selectLossAmountOfDay_with" />
    WITH intakeLossAmountDay AS (<include refid="selectLossAmountOfDay_with"/>)
    SELECT inta.intakeId     AS intakeId,
           inta.intakeNum    AS intakeNum,
           inta.intakeLng    AS intakeLng,
@@ -627,7 +625,7 @@
  <!--统计指定月份各天漏损量(26号到31号)-->
  <select id="selectLossAmountOfDay26_31" resultType="com.dy.pipIrrGlobal.voSt.VoDayLoss">
    <include refid="selectLossAmountOfDay_with" />
    WITH intakeLossAmountDay AS (<include refid="selectLossAmountOfDay_with"/>)
    SELECT inta.intakeId     AS intakeId,
           inta.intakeNum    AS intakeNum,
           inta.intakeLng    AS intakeLng,