1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556 |
- <?xml version="1.0" encoding="UTF-8"?>
- <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
- <mapper namespace="com.huiju.estateagents.mapper.TaShareRecordMapper">
- <select id="recordSuccessList" resultType="com.huiju.estateagents.entity.TaShareRecord">
- (select
- t.nickname,
- t.phone,
- t.create_time,
- t.end_time,
- t.verification_status,
- t.verification_code
- from ta_share_record t where 1=1
- <if test="status !=null and status != ''">
- and t.status = #{status}
- </if>
- <if test="orgId != null and orgId != ''">
- and t.org_id = #{orgId}
- </if>
- <if test="phone != null and phone != ''">
- and t.phone = #{phone}
- </if> order by t.end_time desc limit 100000000)
- union all
- (select
- a.nickname as joinNickName,
- a.phone as joinPhone,
- a.create_time as joinCreateTime,
- a.end_time as joinEndTime,
- a.verification_status as joinVerificationStatus,
- a.verification_code as joinVerificationCode
- from ta_share_child_record a where where 1=1
- <if test="status !=null and status != ''">
- and a.status = #{status}
- </if>
- <if test="orgId != null and orgId != ''">
- and a.org_id = #{orgId}
- </if>
- <if test="phone != null and phone != ''">
- and a.phone = #{phone}
- </if> order by a.end_time desc limit 100000000)
- </select>
-
- <select id="recordFailAndProcessingList" resultType="com.huiju.estateagents.po.TaShareRecordPO">
- select t.record_id, t.nickname, t.phone, t.create_time, a.group_buy_people, a.join_people from ta_share_record t
- left join ta_share_activity a on t.group_activity_id = a.group_acticity_id
- where 1=1
- <if test="status !=null and status != ''">
- and t.status = #{status}
- </if>
- <if test="orgId != null and orgId != ''">
- and t.org_id = #{orgId}
- </if>
- <if test="phone != null and phone != ''">
- and t.phone = #{phone}
- </if> order by t.create_time desc
- </select>
- </mapper>
|