|
|
@@ -146,8 +146,18 @@
|
|
|
#{item}
|
|
|
</foreach>
|
|
|
</if>
|
|
|
- ORDER BY OD.ORD_NO DESC
|
|
|
- , OD.ORD_DTL_NO DESC
|
|
|
+ <if test="optCd != null and optCd != ''">
|
|
|
+ AND ODI.OPT_CD LIKE CONCAT('%',#{optCd},'%')
|
|
|
+ </if>
|
|
|
+ <if test="extmallId != null and extmallId != ''">
|
|
|
+ AND OD.VENDOR_ID = #{vendorId}
|
|
|
+ AND OD.EXTMALL_ID = #{extmallId}
|
|
|
+ </if>
|
|
|
+ <if test="extmallOrderId != null and extmallOrderId != ''">
|
|
|
+ AND OD.EXTMALL_ORDER_ID LIKE CONCAT('%',#{extmallOrderId},'%')
|
|
|
+ </if>
|
|
|
+ ORDER BY OD.ORD_NO DESC
|
|
|
+ , OD.ORD_DTL_NO DESC
|
|
|
),
|
|
|
CTE_PAYMENT AS (
|
|
|
SELECT A.*
|
|
|
@@ -356,6 +366,16 @@
|
|
|
<foreach collection="ordNoList" item="item" index="index" open="(" close=")" separator=",">
|
|
|
#{item}
|
|
|
</foreach>
|
|
|
+ </if>
|
|
|
+ <if test="optCd != null and optCd != ''">
|
|
|
+ AND ODI.OPT_CD LIKE CONCAT('%',#{optCd},'%')
|
|
|
+ </if>
|
|
|
+ <if test="extmallId != null and extmallId != ''">
|
|
|
+ AND OD.VENDOR_ID = #{vendorId}
|
|
|
+ AND OD.EXTMALL_ID = #{extmallId}
|
|
|
+ </if>
|
|
|
+ <if test="extmallOrderId != null and extmallOrderId != ''">
|
|
|
+ AND OD.EXTMALL_ORDER_ID LIKE CONCAT('%',#{extmallOrderId},'%')
|
|
|
</if>
|
|
|
GROUP BY OD.ORD_NO, OD.GOODS_CD, OD.ORD_DTL_NO, OD.DELV_ADDR_SQ, O.CUST_NO
|
|
|
ORDER BY OD.ORD_NO DESC
|