|
|
@@ -201,6 +201,7 @@
|
|
|
LEFT JOIN ota_distributor od on od.id = td.source_id
|
|
|
LEFT JOIN trade_order_audit toa on toa.order_id = td.id and toa.audit_status = 1
|
|
|
LEFT JOIN (select m2.order_id,sum(m2.refund_amount) refund_amount,sum(m2.origin_amount) origin_amount from trade_refund m2 where m2.refund_status = 6 and m2.refund_method !=2 GROUP BY m2.order_id) tr on td.id = tr.order_id
|
|
|
+ LEFT JOIN trade_order_room_model torm on torm.order_id = td.id
|
|
|
where td.deleted = 0 and tou.deleted = 0
|
|
|
<if test="vo.orderStatus!=null and vo.orderStatus.size()>0">
|
|
|
and td.order_status in
|
|
|
@@ -351,6 +352,12 @@
|
|
|
<if test="vo.travelStatus != null">
|
|
|
AND td.travel_status = #{vo.travelStatus}
|
|
|
</if>
|
|
|
+ <if test="vo.roomModelId != null">
|
|
|
+ AND torm.room_model_id = #{vo.roomModelId}
|
|
|
+ </if>
|
|
|
+ <if test="vo.floor != null">
|
|
|
+ AND torm.floor = #{vo.floor}
|
|
|
+ </if>
|
|
|
<if test="vo.orderRefundDateStart != null and vo.orderRefundDateEnd != ''">
|
|
|
AND exists (select 1 from trade_refund tr where tr.order_id=td.id and tr.refund_status = 6 and tr.refund_time BETWEEN #{vo.orderRefundDateStart} and #{vo.orderRefundDateEnd} )
|
|
|
</if>
|