|
|
|
@@ -182,7 +182,8 @@ |
|
|
|
</select> |
|
|
|
|
|
|
|
<select id="sumVoList" parameterType="com.iformall.domain.po.WxMerchantSubsidy" resultType="hashmap"> |
|
|
|
select IFNULL(sum(ms.`order_payment`),0) as sum_order_payment, |
|
|
|
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, |
|
|
|
IFNULL(sum(ms.`real_subsidy`),0) as sum_real_subsidy |
|
|
|
@@ -190,7 +191,14 @@ |
|
|
|
left join wx_coupon_order co on co.id = ms.coupon_order_id |
|
|
|
left join wx_coupon c on c.id = co.coupon_id |
|
|
|
left join wx_merchant m on m.id = ms.merchant_id |
|
|
|
<include refid="dynamicVoWhereConditions" /> |
|
|
|
<where> |
|
|
|
<if test=" null != status "> |
|
|
|
and ms.`status` = #{status} |
|
|
|
</if> |
|
|
|
<if test=" null != startdate and null!=enddate"> |
|
|
|
and ms.`create_date` between #{startdate} and #{enddate} |
|
|
|
</if> |
|
|
|
</where> |
|
|
|
</select> |
|
|
|
|
|
|
|
|
|
|
|
|