| | |
| | | <!-- 非模板--> |
| | | <sql id="listWhere"> |
| | | <if test="query.activityId!=null">and activity_id=#{query.activityId}</if> |
| | | <if test="query.level!=null">and `level`=#{query.level}</if> |
| | | <if test="query.minCreateTime!=null">and create_time>=#{query.minCreateTime}</if> |
| | | <if test="query.maxCreateTime!=null">and #{query.maxCreateTime}>create_time</if> |
| | | </sql> |
| | |
| | | from lucky_activity_awards where 1=1 |
| | | <include refid="listWhere"/> |
| | | <if test="query.sortList!=null"> |
| | | <foreach collection="query.sortList" item="item" separator="," open=" order by ">#{item}</foreach> |
| | | <foreach collection="query.sortList" item="item" separator="," open=" order by "> ${item}</foreach> |
| | | </if> |
| | | limit #{query.start},#{query.count} |
| | | </select> |