ydj
2024-05-20 16c9afecf5c800922527ad27d42212141ac62c2e
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
<?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.nq.dao.UserOptionLogMapper">
 
    <select id="selective" resultType="com.nq.vo.user.UserOptionLogVO">
        SELECT
            t1.*,
            t2.accect_type AS userAccectType,
            t3.nick_name AS userName
        FROM
            user_option_log t1
                LEFT JOIN user_assets t2 ON t1.user_accect_id = t2.id
                LEFT JOIN `user` t3 ON t1.user_id = t3.id
            where 1=1
        <if test="userId!=null and userId!=''">
            and t1.user_id = #{userId}
        </if>
    </select>
 
</mapper>