41 lines
1.5 KiB
XML
41 lines
1.5 KiB
XML
<?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.haitongauto.mapper.admin.UsersAdminMapper">
|
|
<!--根据用户ID、手机号、昵称、注册时间和用户状态查询小程序注册用户信息: keywords, registerDate,usersState-->
|
|
<select id="usersListForCondition" resultType="com.haitongauto.models.pojo.Users">
|
|
select
|
|
id,
|
|
access_token,
|
|
access_token_rtos,
|
|
users_name,
|
|
wx_openid,
|
|
wx_unionid,
|
|
wx_nick,
|
|
wx_sex,
|
|
wx_head_sculpture,
|
|
tel_number,
|
|
id_code,
|
|
users_state,
|
|
create_time,
|
|
update_time,
|
|
is_del
|
|
from applet_users
|
|
where is_del=0
|
|
<if test="keywords!=null and keywords!=''" >
|
|
and (id_code like concat('%',#{keywords},'%') or tel_number like concat('%',#{keywords},'%') or wx_nick like concat('%',#{keywords},'%') or users_name like concat('%',#{keywords},'%'))
|
|
</if>
|
|
<if test="registerDateStart!=null and registerDateStart!=''">
|
|
and to_char(create_time,'yyyy-mm-dd')>=#{registerDateStart}
|
|
</if>
|
|
<if test="registerDateEnd!=null and registerDateEnd!=''">
|
|
and to_char(create_time,'yyyy-mm-dd')<=#{registerDateEnd}
|
|
</if>
|
|
<if test="usersState!=null">
|
|
and users_state=#{usersState}
|
|
</if>
|
|
order by create_time desc
|
|
</select>
|
|
|
|
</mapper> |