|
|
@ -71,7 +71,7 @@ select * from pmn_activity_promotion_param where id in(select param_id from pmn_
|
|
|
|
<select id="pageVO" resultMap="activityInstanceVOMap">
|
|
|
|
<select id="pageVO" resultMap="activityInstanceVOMap">
|
|
|
|
select t.*,t1.store_count,t2.abbreviation as store_name,t3.company_count,t4.name as company_name
|
|
|
|
select t.*,t1.store_count,t2.abbreviation as store_name,t3.company_count,t4.name as company_name
|
|
|
|
from pmn_activity_instance t
|
|
|
|
from pmn_activity_instance t
|
|
|
|
left join (select instance_id, count(1) as store_count,store_id,org_id from pmn_activity_store_relation group by
|
|
|
|
left join (select instance_id, count(DISTINCT store_id) as store_count,store_id,org_id from pmn_activity_store_relation group by
|
|
|
|
instance_id) t1 on t.id=t1.instance_id
|
|
|
|
instance_id) t1 on t.id=t1.instance_id
|
|
|
|
left join poi_store t2 on t2.id=t1.store_id
|
|
|
|
left join poi_store t2 on t2.id=t1.store_id
|
|
|
|
left join (select instance_id, count(DISTINCT org_id) as company_count,store_id from pmn_activity_store_relation
|
|
|
|
left join (select instance_id, count(DISTINCT org_id) as company_count,store_id from pmn_activity_store_relation
|
|
|
|