|
@@ -5,6 +5,7 @@
|
|
|
<mapper namespace="com.ydtech.modules.admin.dao.SysUserAccountMapper">
|
|
<mapper namespace="com.ydtech.modules.admin.dao.SysUserAccountMapper">
|
|
|
|
|
|
|
|
<resultMap id="BaseResultMap" type="com.ydtech.modules.admin.model.po.SysUserAccount">
|
|
<resultMap id="BaseResultMap" type="com.ydtech.modules.admin.model.po.SysUserAccount">
|
|
|
|
|
+ <id property="id" column="id" jdbcType="VARCHAR"/>
|
|
|
<id property="userId" column="user_id" jdbcType="VARCHAR"/>
|
|
<id property="userId" column="user_id" jdbcType="VARCHAR"/>
|
|
|
<result property="handlingFee" column="handling_fee" jdbcType="DECIMAL"/>
|
|
<result property="handlingFee" column="handling_fee" jdbcType="DECIMAL"/>
|
|
|
<result property="documentary" column="documentary" jdbcType="DECIMAL"/>
|
|
<result property="documentary" column="documentary" jdbcType="DECIMAL"/>
|
|
@@ -28,8 +29,8 @@
|
|
|
<result property="sumAmountPayment" column="sum_amount_payment" jdbcType="DECIMAL"/>
|
|
<result property="sumAmountPayment" column="sum_amount_payment" jdbcType="DECIMAL"/>
|
|
|
<result property="managementSource" column="managementSource" jdbcType="VARCHAR"/>
|
|
<result property="managementSource" column="managementSource" jdbcType="VARCHAR"/>
|
|
|
<result property="roleId" column="roleId" jdbcType="VARCHAR"/>
|
|
<result property="roleId" column="roleId" jdbcType="VARCHAR"/>
|
|
|
- <collection property="sysUserAccountCardList" ofType="com.ydtech.modules.admin.model.po.SysUserBankCard"
|
|
|
|
|
- resultMap="sysUserAccountCardList"/>
|
|
|
|
|
|
|
+ <!-- <collection property="sysUserAccountCardList" ofType="com.ydtech.modules.admin.model.po.SysUserBankCard"
|
|
|
|
|
+ resultMap="sysUserAccountCardList"/> -->
|
|
|
</resultMap>
|
|
</resultMap>
|
|
|
|
|
|
|
|
<resultMap id="sysUserAccountCardList" type="com.ydtech.modules.admin.model.po.SysUserBankCard">
|
|
<resultMap id="sysUserAccountCardList" type="com.ydtech.modules.admin.model.po.SysUserBankCard">
|
|
@@ -109,6 +110,7 @@
|
|
|
|
|
|
|
|
<select id="queryPageOrder1" resultMap="BaseResultMap">
|
|
<select id="queryPageOrder1" resultMap="BaseResultMap">
|
|
|
select
|
|
select
|
|
|
|
|
+ a.user_id as id,
|
|
|
a.user_id,
|
|
a.user_id,
|
|
|
a.handling_fee,
|
|
a.handling_fee,
|
|
|
a.documentary,
|
|
a.documentary,
|
|
@@ -126,13 +128,6 @@
|
|
|
b.dept_id as deptId,
|
|
b.dept_id as deptId,
|
|
|
b.name as name,
|
|
b.name as name,
|
|
|
sd.name as deptName,
|
|
sd.name as deptName,
|
|
|
- c.id,
|
|
|
|
|
- c.bank_number,
|
|
|
|
|
- c.bank_account,
|
|
|
|
|
- c.bank_address,
|
|
|
|
|
- c.del_flag,
|
|
|
|
|
- c.audit_status,
|
|
|
|
|
- c.real_user_name,
|
|
|
|
|
a.sum_amount,
|
|
a.sum_amount,
|
|
|
a.sum_amount_withdrawal,
|
|
a.sum_amount_withdrawal,
|
|
|
a.sum_amount_account,
|
|
a.sum_amount_account,
|
|
@@ -143,10 +138,8 @@
|
|
|
sys_user_account a
|
|
sys_user_account a
|
|
|
left join sys_user b on a.user_id = b.id
|
|
left join sys_user b on a.user_id = b.id
|
|
|
left join sys_dept sd on sd.id = b.dept_id
|
|
left join sys_dept sd on sd.id = b.dept_id
|
|
|
- left join sys_user_bank_card c on c.user_id = a.user_id
|
|
|
|
|
left join sys_user_role role on role.user_id = a.user_id
|
|
left join sys_user_role role on role.user_id = a.user_id
|
|
|
<where>
|
|
<where>
|
|
|
- 1=1
|
|
|
|
|
<if test="sysUserAccountVo.userId != null and sysUserAccountVo.userId != ''">
|
|
<if test="sysUserAccountVo.userId != null and sysUserAccountVo.userId != ''">
|
|
|
and a.user_id = #{sysUserAccountVo.userId}
|
|
and a.user_id = #{sysUserAccountVo.userId}
|
|
|
</if>
|
|
</if>
|
|
@@ -171,4 +164,66 @@
|
|
|
</select>
|
|
</select>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
+ <select id="queryCount" resultMap="BaseResultMap">
|
|
|
|
|
+ select
|
|
|
|
|
+ a.user_id,
|
|
|
|
|
+ a.handling_fee,
|
|
|
|
|
+ a.documentary,
|
|
|
|
|
+ a.promotion,
|
|
|
|
|
+ a.create_time,
|
|
|
|
|
+ a.handling_amount_withdrawal,
|
|
|
|
|
+ a.handling_amount_account,
|
|
|
|
|
+ a.handling_amount_payment,
|
|
|
|
|
+ a.documentary_amount_withdrawal,
|
|
|
|
|
+ a.documentary_amount_account,
|
|
|
|
|
+ a.documentary_amount_payment,
|
|
|
|
|
+ a.promotion_amount_withdrawal,
|
|
|
|
|
+ a.promotion_amount_account,
|
|
|
|
|
+ a.promotion_amount_payment,
|
|
|
|
|
+ b.dept_id as deptId,
|
|
|
|
|
+ b.name as name,
|
|
|
|
|
+ sd.name as deptName,
|
|
|
|
|
+ sd.management_source as managementSource,
|
|
|
|
|
+ role.role_id as roleId
|
|
|
|
|
+ from
|
|
|
|
|
+ sys_user_account a
|
|
|
|
|
+ left join sys_user b on a.user_id = b.id
|
|
|
|
|
+ left join sys_dept sd on sd.id = b.dept_id
|
|
|
|
|
+ left join sys_user_role role on role.user_id = a.user_id
|
|
|
|
|
+ <where>
|
|
|
|
|
+ a.user_id not in (
|
|
|
|
|
+ SELECT
|
|
|
|
|
+ su.id AS userId
|
|
|
|
|
+ FROM
|
|
|
|
|
+ sys_user su
|
|
|
|
|
+ LEFT JOIN sys_user_info info ON info.id = su.id
|
|
|
|
|
+ LEFT JOIN sys_dept sd ON su.dept_id = sd.id
|
|
|
|
|
+ LEFT JOIN sys_dept psd ON psd.id = sd.parent_id
|
|
|
|
|
+ LEFT JOIN sys_user_role t3 ON su.id = t3.user_id
|
|
|
|
|
+ LEFT JOIN sys_role t4 ON t3.role_id = t4.id
|
|
|
|
|
+ AND sd.del_flag = '0'
|
|
|
|
|
+ WHERE
|
|
|
|
|
+ su.dept_id LIKE concat( '%', '99', '%' )
|
|
|
|
|
+ AND t3.role_id IN ( 3 )
|
|
|
|
|
+ AND sd.management_source = 3
|
|
|
|
|
+ ORDER BY
|
|
|
|
|
+ su.create_time DESC
|
|
|
|
|
+ )
|
|
|
|
|
+ </where>
|
|
|
|
|
+ </select>
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
|
|
+ <select id="queryCardListByUserId" resultMap="sysUserAccountCardList">
|
|
|
|
|
+ select
|
|
|
|
|
+ c.id,
|
|
|
|
|
+ c.bank_number,
|
|
|
|
|
+ c.bank_account,
|
|
|
|
|
+ c.bank_address,
|
|
|
|
|
+ c.del_flag,
|
|
|
|
|
+ c.audit_status,
|
|
|
|
|
+ c.real_user_name
|
|
|
|
|
+ from
|
|
|
|
|
+ sys_user_bank_card c
|
|
|
|
|
+ where c.user_id =#{userId}
|
|
|
|
|
+ </select>
|
|
|
</mapper>
|
|
</mapper>
|