You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
38 lines
1.2 KiB
38 lines
1.2 KiB
<?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.wrj.driver.server.mapper.TdSysUserMemberMapper">
|
|
|
|
|
|
<select id="queryUserMemberList" resultType="com.wrj.driver.server.vo.UserMemberVo">
|
|
select
|
|
tm.MEMBER_ID,
|
|
tm.MEMBER_NAME,
|
|
tm.CAR_TYPE_ID,
|
|
tm.PRICE,
|
|
tm.SUBJECTS,
|
|
su.USER_ID,
|
|
su.PHONE,
|
|
c.CAR_NAME,
|
|
um.START_DATE,
|
|
um.END_DATE
|
|
from
|
|
td_sys_user_member um
|
|
left join td_member tm on um.MEMBER_ID = tm.MEMBER_ID
|
|
left join td_sys_user su on su.USER_ID = um.USER_ID
|
|
left join td_car c on c.CAR_TYPE_ID = TM.CAR_TYPE_ID
|
|
<where>
|
|
<if test="userMemberDto.phone !=null">
|
|
and su.PHONE like concat("%" + #{userMemberDto.phone} + "%")
|
|
</if>
|
|
<if test="userMemberDto.memberId !=null">
|
|
and tm.MEMBER_ID = #{userMemberDto.memberId}
|
|
</if>
|
|
|
|
<if test="userMemberDto.tenantId !=null">
|
|
and tm.TENANT_ID = #{userMemberDto.tenantId}
|
|
</if>
|
|
</where>
|
|
order by um.CREATE_TIME
|
|
</select>
|
|
|
|
</mapper>
|
|
|