| | |
| | | left join t_coupon_receive tcr on tcr.id = o.couponId |
| | | left join t_coupon tc on tc.id = tcr.couponId |
| | | </select> |
| | | |
| | | <select id="pageList" resultType="com.jilongda.manage.model.TOrder"> |
| | | select * from t_order |
| | | where 1=1 |
| | | <if test="query.startTime != null and query.startTime != '' and query.endTime != null and query.endTime != ''"> |
| | | and createTime between #{query.startTime} and #{query.endTime} |
| | | </if> |
| | | <if test="query.startMoney != null "> |
| | | and orderMoney between #{query.startMoney} and #{query.endMoney} |
| | | </if> |
| | | <if test="query.realName != null and query.realName != ''"> |
| | | and `name` like concat('%',#{query.realName},'%') |
| | | </if> |
| | | <if test="query.storeId != null"> |
| | | and storeId = #{query.storeId} |
| | | </if> |
| | | <if test="query.sysId != null"> |
| | | and sysId = #{query.sysId} |
| | | </if> |
| | | <if test="query.userIds != null and query.userIds.size()>0"> |
| | | AND userId IN |
| | | <foreach collection="query.userIds" close=")" open="(" item="id" separator=","> |
| | | #{id} |
| | | </foreach> |
| | | </if> |
| | | <if test="query.orderIds != null and query.orderIds.size()>0"> |
| | | AND id IN |
| | | <foreach collection="query.orderIds" close=")" open="(" item="id" separator=","> |
| | | #{id} |
| | | </foreach> |
| | | </if> |
| | | </select> |
| | | </mapper> |