Pu Zhibing
2025-04-22 fd7b8fb7c89832c28a838b0449bbb8a392433ee2
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.ruoyi.order.mapper.RefundPassMapper">
 
 
    <select id="getOrderRefundPassList" resultType="com.ruoyi.order.vo.OrderRefundPassList">
        select
            a.id,
            b.order_number as orderNumber,
            b.app_user_id as appUserId,
            a.create_time as createTime,
            a.refund_method as refundMethod,
            a.refund_reason as refundReason,
            a.pass_status as passStatus,
            a.status
        from t_refund_pass a
        left join t_order b on (a.order_id = b.id)
        where a.del_flag = 0
        <if test="null != orderNumber and '' != orderNumber">
            and b.order_number like CONCAT('%', #{orderNumber}, '%')
        </if>
        <if test="null != appUserIds and appUserIds.size() > 0">
            and b.app_user_id in
            <foreach collection="appUserIds" item="item" index="index" open="(" separator="," close=")">
                #{item}
            </foreach>
        </if>
        <if test="null != refundMethod">
            and a.refund_method = #{refundMethod}
        </if>
        <if test="null != status">
            and a.status = #{status}
        </if>
        <if test="null != shopId">
            and b.shop_id = #{shopId} and b.order_type = 1
        </if>
        order by a.create_time desc
    </select>
</mapper>