|
|
|
@@ -168,7 +168,7 @@ |
|
|
|
left join wx_merchant_trade_daily mtd on mtd.merchant_id = m.id |
|
|
|
left join wx_merchant_shop wmt on wmt.merchant_id = m.id |
|
|
|
left join wx_shop ws on(wmt.shop_id = ws.id) |
|
|
|
where m.business_id=#{id} and m.tenant_id=#{tenantId}) |
|
|
|
where m.business_id=#{id} and m.tenant_id=#{tenantId} and mtd.create_date between #{startdate} and #{enddate}) |
|
|
|
,2) devoteRate |
|
|
|
|
|
|
|
from wx_merchant m |
|
|
|
@@ -176,6 +176,7 @@ |
|
|
|
left join wx_merchant_shop wmt on wmt.merchant_id = m.id |
|
|
|
left join wx_shop ws on(wmt.shop_id = ws.id) |
|
|
|
where m.business_id=#{id} and m.tenant_id=#{tenantId} |
|
|
|
and mtd.create_date between #{startdate} and #{enddate} |
|
|
|
group by m.id |
|
|
|
order by devoteRate desc |
|
|
|
</select> |
|
|
|
|