体现记录接口修改

This commit is contained in:
张松
2025-01-04 13:39:56 +08:00
parent acb3e97e5a
commit 362e99c8c9
3 changed files with 67 additions and 1 deletions

View File

@@ -45,6 +45,22 @@
select money from user_money where user_id=#{userId}
</select>
<select id="selectSumByUserIdList" resultType="com.sqx.modules.pay.entity.CashOut">
SELECT
user_id,
ROUND( sum( money ), 2 ) AS total,
count(*) AS count
FROM
cash_out
WHERE
state = #{state}
and user_id in
<foreach collection="userIdList" item="id" open="(" separator="," close=")">
#{id}
</foreach>
GROUP BY
user_id
</select>
<select id="selectCashOutPage" resultType="com.sqx.modules.pay.entity.CashOut">
SELECT c.*,
ifnull(u.user_name,"用户不存在") as userName,
@@ -172,4 +188,5 @@
select format(sum(money),2) from cash_out where state = #{state} and user_id = #{userId}
</select>
</mapper>