|
@@ -31,11 +31,13 @@
|
|
|
if(t2.prize_type = 'goods' AND t3.title is not null,t3.title,t2.title) as title,
|
|
|
if(t2.prize_type = 'goods' AND t3.title is not null,t3.pic_url,t2.pic_url) as pic_url,
|
|
|
if(t2.prize_type = 'goods' AND t3.value is not null,t3.value,t2.value) as value,
|
|
|
+ if(t4.coupon_detail is not null, t3.coupon_detail, '') as coupon_detail,
|
|
|
t1.*,
|
|
|
t2.*
|
|
|
from mp_ticket_awards t1
|
|
|
left join mp_ticket_awards_prize t2 on t1.awards_id = t2.awards_id
|
|
|
left join mp_goods t3 on t2.ref_id = t3.goods_id
|
|
|
+ left join mp_coupon t4 on t2.ref_id = t4.coupon_id
|
|
|
${ew.customSqlSegment}
|
|
|
</select>
|
|
|
|