Преглед на файлове

[补贴][修复]:sum修复

release_toaliyun_real
Stormeye Wu преди 7 години
родител
ревизия
73cdbcee5b
променени са 1 файла, в които са добавени 24 реда и са изтрити 2 реда
  1. +24
    -2
      mallinkService/src/main/resources/mapper/WxMerchantSubsidyMapper.xml

+ 24
- 2
mallinkService/src/main/resources/mapper/WxMerchantSubsidyMapper.xml Целия файл

@@ -69,6 +69,12 @@
<if test=" null != startdate and null!=enddate">
and `create_date` between #{startdate} and #{enddate}
</if>
<if test=" null != statusS ">
and `status` in
<foreach collection="statusS" index="index" item="sItem" open="(" separator="," close=")">
#{sItem}
</foreach>
</if>
<if test=" null != ids ">
and id in
<foreach collection="ids" index="index" item="idItem" open="(" separator="," close=")">
@@ -169,8 +175,14 @@
<if test=" null != startdate and null!=enddate">
and ms.`create_date` between #{startdate} and #{enddate}
</if>
<if test=" null != statusS ">
and ms.`status` in
<foreach collection="statusS" index="index" item="sItem" open="(" separator="," close=")">
#{sItem}
</foreach>
</if>
<if test=" null != ids ">
and id in
and ms.`id` in
<foreach collection="ids" index="index" item="idItem" open="(" separator="," close=")">
#{idItem}
</foreach>
@@ -188,7 +200,7 @@
</select>

<select id="sumVoList" parameterType="com.iformall.domain.po.WxMerchantSubsidy" resultType="hashmap">
select ms.merchant_id, m.name as merchant_name,
select ms.`merchant_id`, m.`name` as merchant_name,
IFNULL(sum(ms.`order_payment`),0) as sum_order_payment,
IFNULL(sum(ms.`receiver_payment`),0) as sum_receiver_payment,
IFNULL(sum(ms.`subsidy`),0) as sum_subsidy,
@@ -201,10 +213,20 @@
<if test=" null != status ">
and ms.`status` = #{status}
</if>
<if test=" null != merchantId ">
and ms.`merchant_id` = #{merchantId}
</if>
<if test=" null != statusS ">
and ms.`status` in
<foreach collection="statusS" index="index" item="sItem" open="(" separator="," close=")">
#{sItem}
</foreach>
</if>
<if test=" null != startdate and null!=enddate">
and ms.`create_date` between #{startdate} and #{enddate}
</if>
</where>
group by ms.`merchant_id`
</select>


Зареждане…
Отказ
Запис