Files
cai-server/ruoyi-cai/src/main/resources/mapper/cai/RankMapper.xml
dute7liang 96570448b5 init
2024-01-20 22:07:35 +08:00

33 lines
1.1 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.ruoyi.cai.mapper.RankMapper">
<select id="pageAdmin" resultType="com.ruoyi.cai.dto.admin.vo.RankAdminVo">
select t1.*,t2.usercode,t2.nickname,t2.mobile,t2.avatar,t2.gender,t2.is_anchor,t2.age
from cai_rank t1
left join cai_user t2 on t1.user_id = t2.id
<where>
<if test="bo.mobile != null and bo.mobile != ''">
and t2.mobile = #{bo.mobile}
</if>
<if test="bo.usercode != null and bo.usercode != ''">
and t2.usercode = #{bo.usercode}
</if>
<if test="bo.rankBeginTime != null">
and t1.rank_begin_time = #{bo.rankBeginTime}
</if>
<if test="bo.type != null">
and t1.type = #{bo.type}
</if>
<if test="bo.dataType != null">
and t1.data_type = #{bo.dataType}
</if>
</where>
order by t1.order_rank
</select>
</mapper>