|
|
@@ -17,6 +17,21 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<result property="shareCode" column="share_code"/>
|
|
|
</resultMap>
|
|
|
|
|
|
+
|
|
|
+ <resultMap type="com.zhongzheng.modules.distribution.vo.DistributionSellerVo" id="DistributionSellerVoResult">
|
|
|
+ <result property="sellerId" column="seller_id"/>
|
|
|
+ <result property="realname" column="realname"/>
|
|
|
+ <result property="status" column="status"/>
|
|
|
+ <result property="userAccount" column="user_account"/>
|
|
|
+ <result property="gzhOpenId" column="gzh_open_id"/>
|
|
|
+ <result property="unionId" column="union_id"/>
|
|
|
+ <result property="parentId" column="parent_id"/>
|
|
|
+ <result property="shareCode" column="share_code"/>
|
|
|
+ <result property="idCard" column="id_card" typeHandler="com.zhongzheng.common.type.EncryptHandler"/>
|
|
|
+ <result property="phonenumber" column="phonenumber"/>
|
|
|
+ </resultMap>
|
|
|
+
|
|
|
+
|
|
|
<select id="getSellerListByTenant" parameterType="com.zhongzheng.modules.top.distribution.bo.DistributionSellerQuery" resultType="com.zhongzheng.modules.distribution.vo.DistributionSellerVo">
|
|
|
SELECT ds.*,sr.realname,sr.user_account,t.tenant_name,
|
|
|
(SELECT COUNT(*) FROM distribution_seller dr WHERE dr.parent_id = ds.seller_id) promotionNum
|
|
|
@@ -35,5 +50,16 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
</if>
|
|
|
</select>
|
|
|
|
|
|
+ <select id="findList" parameterType="com.zhongzheng.modules.top.distribution.bo.DistributionSellerQuery" resultMap="DistributionSellerVoResult">
|
|
|
+ SELECT
|
|
|
+ s.*,
|
|
|
+ u.id_card,
|
|
|
+ u.phonenumber
|
|
|
+ FROM
|
|
|
+ distribution_seller s
|
|
|
+ LEFT JOIN sys_user u ON s.seller_id = u.seller_id
|
|
|
+ ORDER BY
|
|
|
+ s.seller_id DESC
|
|
|
+ </select>
|
|
|
|
|
|
</mapper>
|