<?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="vip.xiaonuo.biz.modular.recommendrecord.mapper.BizRecommendRecordMapper">

    <select id="page" resultType="vip.xiaonuo.biz.modular.recommendrecord.entity.BizRecommendRecord">
        SELECT
            t.id,
            t.recommend_user_id,
            t.accept_user_id,
            t.create_time,
            u1.`NAME` acceptUserName,
            u1.`PHONE` acceptUserPhone,
            u2.`NAME` recommendUserName,
            u2.`PHONE` recommendUserPhone
        FROM
            biz_recommend_record t
        LEFT JOIN SYS_USER u1 ON u1.ID = t.accept_user_id
        LEFT JOIN SYS_USER u2 ON u2.ID = t.recommend_user_id
        ${ew.customSqlSegment}
    </select>
</mapper>
