|
@@ -556,9 +556,20 @@
|
|
<select id="selectByMobileOrEmail" resultType="com.caimei.modules.user.entity.CmUser">
|
|
<select id="selectByMobileOrEmail" resultType="com.caimei.modules.user.entity.CmUser">
|
|
select u.*,cu.mobile as operatorMobile from user u
|
|
select u.*,cu.mobile as operatorMobile from user u
|
|
left join cm_mall_operation_user cu on cu.userID = u.userID
|
|
left join cm_mall_operation_user cu on cu.userID = u.userID
|
|
- where (u.bindMobile = #{mobileOrEmail}
|
|
|
|
- or u.email = #{mobileOrEmail}
|
|
|
|
- or (cu.mobile = #{mobileOrEmail} and cu.delFlag != 1))
|
|
|
|
|
|
+ where (u.bindMobile = #{mobileOrEmail} or u.email = #{mobileOrEmail})
|
|
|
|
+ AND u.userIdentity IN (1,2,3,4)
|
|
|
|
+ AND u.userOrganizeID = 0
|
|
|
|
+ <if test="source == 'www'">
|
|
|
|
+ AND u.registerUserTypeID IN (1,3,4)
|
|
|
|
+ </if>
|
|
|
|
+ <if test="source == 'crm'">
|
|
|
|
+ AND u.registerUserTypeID IN (1,2,3,32,4)
|
|
|
|
+ </if>
|
|
|
|
+ UNION
|
|
|
|
+ select u.*,cu.mobile as operatorMobile from user u
|
|
|
|
+ left join cm_mall_operation_user cu on cu.userID = u.userID
|
|
|
|
+ where cu.mobile = #{mobileOrEmail}
|
|
|
|
+ AND cu.delFlag != 1
|
|
AND u.userIdentity IN (1,2,3,4)
|
|
AND u.userIdentity IN (1,2,3,4)
|
|
AND u.userOrganizeID = 0
|
|
AND u.userOrganizeID = 0
|
|
<if test="source == 'www'">
|
|
<if test="source == 'www'">
|