xiaoyong931011
2021-07-21 1d03a9e224dc0ce11d47bede74da9db2189d663c
gc-user/src/main/resources/mapper/user/JhyInfoMapper.xml
@@ -17,4 +17,26 @@
    <select id="selectExistJhyByIndeityOrMobile" resultType="com.xzx.gc.entity.JhyInfo">
        select * from xzx_jhy_info where (mobile=#{mobile} or identity = #{identity}) and status in (1, 2)
    </select>
    <select id="selectJhyInfoList" resultType="com.xzx.gc.user.vo.JhyInfoListVo">
        select *,CREATED_TIME createTime from xzx_jhy_info
        <where>
            1=1
            <if test="record.name != null and record.name != ''">
                and (username like concat('%',#{record.name},'%')
                or mobile like concat('%',#{record.name},'%') )
            </if>
            <if test="record.isJhy != null and record.isJhy != ''">
                and is_jhy=#{record.isJhy}
            </if>
            <if test="record.status != null">
                and status = #{record.status}
            </if>
        </where>
        order by id desc
    </select>
    <delete id="deleteByUserId">
        delete from xzx_jhy_info where user_id=#{userId}
    </delete>
</mapper>