Browse Source

委托服务费用

master
张彭杰 1 week ago
parent
commit
4ecb1295fd
1 changed files with 38 additions and 2 deletions
  1. 40
      dating-agency-mall-server/src/main/resources/mapper/ora/PurchaseProductRecordQueryService.xml

40
dating-agency-mall-server/src/main/resources/mapper/ora/PurchaseProductRecordQueryService.xml

@ -4,6 +4,7 @@
<select id="pageMarriageBountyOrder"
resultType="com.qniao.dam.api.query.ora.user.response.UserPageMarriageBountyOrderRefundApplicationVo">
SELECT aa.* From (
select
dora.id,
dora.order_id,
@ -21,7 +22,7 @@
LEFT JOIN da_marriage_bounty_order as dmbo on dmbo.id=dora.order_id
LEFT JOIN da_marriage_information as dmi on dmi.id=dmbo.mi_id
LEFT JOIN da_account as daa on daa.is_delete=0 and daa.type=2 and daa.user_id=dmbo.user_id
where dora.is_delete=0
where dora.is_delete=0 and dora.refund_order_type=1
<if test="queryParams.operationStatus != null">
and dora.`operation_status` = #{queryParams.operationStatus}
</if>
@ -37,6 +38,41 @@
<if test="queryParams.applyTimeFrom != null and queryParams.applyTimeTo != null">
and dora.create_time BETWEEN #{queryParams.applyTimeFrom} and #{queryParams.applyTimeTo}
</if>
order by dora.create_time desc
UNION ALL
select
dora.id,
dora.order_id,
dmi.nick_name as miName,
daa.tid as phone,
dora.refund_order_type as refundOrderType,
dora.refund_amount,
dora.order_amount,
dora.`operation_status`,
dora.`status`,
dora.operation_remark,
dora.remark,
dora.create_time as applyTime
from da_order_refund_application as dora
LEFT JOIN da_entrust_service_order as dmbo on dmbo.id=dora.order_id
LEFT JOIN da_marriage_information as dmi on dmi.id=dmbo.initiator_mi_id
LEFT JOIN da_account as daa on daa.is_delete=0 and daa.type=2 and daa.user_id=dmbo.target_user_id
where dora.is_delete=0 and dora.refund_order_type=2
<if test="queryParams.operationStatus != null">
and dora.`operation_status` = #{queryParams.operationStatus}
</if>
<if test="queryParams.status != null">
and dora.`status` = #{queryParams.status}
</if>
<if test="queryParams.miName != null and queryParams.miName != '' ">
AND dmi.nick_name LIKE CONCAT('%', TRIM(#{queryParams.miName}), '%')
</if>
<if test="queryParams.phone != null and queryParams.phone != '' ">
AND daa.tid LIKE CONCAT('%', TRIM(#{queryParams.phone}), '%')
</if>
<if test="queryParams.applyTimeFrom != null and queryParams.applyTimeTo != null">
and dora.create_time BETWEEN #{queryParams.applyTimeFrom} and #{queryParams.applyTimeTo}
</if>) as aa
order by aa.applyTime desc
</select>
</mapper>
Loading…
Cancel
Save