|
|
|
@@ -15,6 +15,8 @@ |
|
|
|
<result column="createtime" property="createtime" /> |
|
|
|
<result column="updatetime" property="updatetime" /> |
|
|
|
<result column="bg_color" property="bgColor" /> |
|
|
|
<result column="couponChannelId" property="couponChannelId" /> |
|
|
|
|
|
|
|
</resultMap> |
|
|
|
|
|
|
|
<sql id="allColumns"> |
|
|
|
@@ -56,7 +58,8 @@ |
|
|
|
</select> |
|
|
|
|
|
|
|
<select id="show" parameterType="com.iformall.domain.po.WxTopic" resultMap="BaseResultMap"> |
|
|
|
select * from wx_topic t where t.status = 1 |
|
|
|
select t.*,cc.id as couponChannelId from wx_topic t left join wx_coupon_channel cc on(cc.sub_target_id = t.id) |
|
|
|
where t.status = 1 |
|
|
|
and now() >= t.begin_time and now() <= t.end_time |
|
|
|
order by t.begin_time desc limit 1 |
|
|
|
</select> |
|
|
|
|