From 8394c7de622940269dca3160b8e74a99bcb87a4f Mon Sep 17 00:00:00 2001 From: Administrator <zhubaomin> Date: 星期一, 22 一月 2024 09:41:25 +0800 Subject: [PATCH] 2024-01-22 朱宝民 充值查询接口,单点登录接口 --- pipIrr-platform/pipIrr-global/src/main/resources/mapper/SeCardOperateMapper.xml | 75 +++++++++++++++++++++++++++++++++++++ 1 files changed, 75 insertions(+), 0 deletions(-) diff --git a/pipIrr-platform/pipIrr-global/src/main/resources/mapper/SeCardOperateMapper.xml b/pipIrr-platform/pipIrr-global/src/main/resources/mapper/SeCardOperateMapper.xml index 52dc477..df474b2 100644 --- a/pipIrr-platform/pipIrr-global/src/main/resources/mapper/SeCardOperateMapper.xml +++ b/pipIrr-platform/pipIrr-global/src/main/resources/mapper/SeCardOperateMapper.xml @@ -218,4 +218,79 @@ operate_dt = #{operateDt,jdbcType=TIMESTAMP} where id = #{id,jdbcType=BIGINT} </update> + + <!--鏍规嵁鎸囧畾鏉′欢鑾峰彇鍏呭�艰褰曟暟閲�--> + <select id="getRecordCount" parameterType="java.util.Map" resultType="java.lang.Long"> + select + COUNT(*) AS recordCount + FROM se_card_operate ope + INNER JOIN se_client_card card ON ope.card_id = card.id + INNER JOIN se_client cli ON ope.client_id = cli.id + <where> + AND ope.operate_type = 2 + <if test = "clientName != null and clientName !=''"> + AND cli.name like CONCAT('%',#{clientName},'%') + </if> + + <if test = "clientNum != null and clientNum > 0"> + AND cli.clientNum like CONCAT('%',#{clientNum},'%') + </if> + + <if test = "cardNum != null and cardNum !=''"> + AND card.cardNum like CONCAT('%',#{cardNum},'%') + </if> + + <if test = "paymentId != null and paymentId > 0"> + AND ope.payment_id = ${paymentId} + </if> + + <if test = "rechargeTimeStart != null and rechargeTimeStop != null"> + AND ope.operate_dt BETWEEN #{rechargeTimeStart} AND #{rechargeTimeStop} + </if> + </where> + </select> + + <!--鏍规嵁鎸囧畾鏉′欢鑾峰彇鍏呭�艰褰�--> + <select id="getRecharges" resultType="com.dy.pipIrrGlobal.voSe.VoRecharge"> + SELECT + CAST(ope.id AS char) AS id , + cli.name AS clientName, + cli.clientNum, + card.cardNum, + ope.trade_amount AS amount, + (ope.money + ope.trade_amount) AS afterRecharge, + ope.payment_id, + ope.price, + (SELECT `name` FROM ba_user WHERE id = ope.operator) AS operator, + ope.operate_dt + FROM se_card_operate ope + INNER JOIN se_client_card card ON ope.card_id = card.id + INNER JOIN se_client cli ON ope.client_id = cli.id + <where> + AND ope.operate_type = 2 + <if test = "clientName != null and clientName !=''"> + AND cli.name like CONCAT('%',#{clientName},'%') + </if> + + <if test = "clientNum != null and clientNum > 0"> + AND cli.clientNum like CONCAT('%',#{clientNum},'%') + </if> + + <if test = "cardNum != null and cardNum !=''"> + AND card.cardNum like CONCAT('%',#{cardNum},'%') + </if> + + <if test = "paymentId != null and paymentId > 0"> + AND ope.payment_id = ${paymentId} + </if> + + <if test = "rechargeTimeStart != null and rechargeTimeStop != null"> + AND ope.operate_dt BETWEEN #{rechargeTimeStart} AND #{rechargeTimeStop} + </if> + </where> + ORDER BY ope.operate_dt DESC + <if test="pageCurr != null and pageSize != null"> + LIMIT ${pageCurr}, ${pageSize} + </if> + </select> </mapper> \ No newline at end of file -- Gitblit v1.8.0