chenjiahe
2023-04-02 2a45d42cebd76d0f0add392c0e06d2cbbb36c63f
提交 | 用户 | age
4df03d 1 <?xml version="1.0" encoding="UTF-8" ?>
C 2 <!DOCTYPE mapper
3 PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
4 "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
5 <!-- namespace:该mapper.xml映射文件的 唯一标识 -->
6 <mapper namespace="com.hx.phip.dao.mapper.RefundMapper">
7
510678 8     <!--一级支付方式记录返回-支付编号求和-->
2a45d4 9     <select id="getConsumePayGroupByNumberNo" resultType="com.hx.phip.vo.order.payment.PayMethodVo">
4df03d 10         SELECT ANY_VALUE(name) AS name
C 11              ,numberNo
ae6ff7 12              ,ROUND(SUM(actualTotal-refundTotal),2) AS surplusTotal
4df03d 13              ,ROUND(SUM(actualTotal),2) AS payTotal
C 14              ,ROUND(SUM(refundTotal),2) AS refundTotal
2a45d4 15              ,ANY_VALUE(isMoneyPay) AS IsMoneyPay
C 16              ,ANY_VALUE(isExecute) AS isExecute
4df03d 17         FROM consume_pay
ae6ff7 18         WHERE isDel = 0 AND orderId = #{orderId} GROUP BY numberNo
4df03d 19     </select>
C 20
510678 21     <!--一级支付方式记录返回-支付编号求和-->
2a45d4 22     <select id="getConsumePayOneGroupByNumberNo" resultType="com.hx.phip.vo.order.payment.PayMethodVo">
4df03d 23         SELECT ANY_VALUE(name) AS name
C 24              ,numberNo
ae6ff7 25              ,ROUND(SUM(actualTotal),2) AS surplusTotal
4df03d 26              ,ROUND(SUM(actualTotal),2) AS payTotal
2a45d4 27              ,ANY_VALUE(isMoneyPay) AS IsMoneyPay
C 28              ,ANY_VALUE(isExecute) AS isExecute
4df03d 29         FROM consume_pay_item
ae6ff7 30         WHERE isDel = 0 AND typeId = #{typeId} GROUP BY numberNo
4df03d 31     </select>
C 32
510678 33     <!--二级支付方式记录返回-支付编号求和-->
2a45d4 34     <select id="getConsumePayTwoGroupByNumberNo" resultType="com.hx.phip.vo.order.payment.PayMethodVo" >
4df03d 35         SELECT ANY_VALUE(name) AS name
C 36              ,numberNo
ae6ff7 37              ,ROUND(SUM(actualTotal),2) AS surplusTotal
4df03d 38              ,ROUND(SUM(actualTotal),2) AS payTotal
2a45d4 39              ,ANY_VALUE(isMoneyPay) AS IsMoneyPay
C 40              ,ANY_VALUE(isExecute) AS isExecute
4df03d 41         FROM consume_pay_item_son
ae6ff7 42         WHERE isDel = 0 AND typeId = #{typeId} GROUP BY numberNo
4df03d 43     </select>
C 44
2a45d4 45     <!--一级支付方式记录返回-->
C 46     <select id="selectConsumePayOneList" resultType="com.hx.phiappt.model.consume.ConsumePayItem">
47         SELECT
48             *
49         FROM consume_pay_item
50         WHERE isDel = 0 AND typeId = #{typeId}
51     </select>
52
53     <!--二级支付方式记录返回-->
54     <select id="selectConsumePayTwoList" resultType="com.hx.phiappt.model.consume.ConsumePayItemSon" >
55         SELECT
56             *
57         FROM consume_pay_item_son
58         WHERE isDel = 0 AND typeId = #{typeId}
59     </select>
60
4df03d 61
C 62 </mapper>