|
|
|
@ -120,12 +120,10 @@
|
|
|
|
|
AND io.preInSelected is not null
|
|
|
|
|
</if>
|
|
|
|
|
<if test="startTime != null and startTime != '' and endTime != null and endTime != ''">
|
|
|
|
|
AND date_format(io.createTime, '%Y-%m-%d') between date_format(#{startTime}, '%Y-%m-%d') and
|
|
|
|
|
date_format(#{endTime}, '%Y-%m-%d')
|
|
|
|
|
AND io.createTime between #{startTime} and #{endTime}
|
|
|
|
|
</if>
|
|
|
|
|
<if test="startAduditTime != null and startAduditTime != '' and endAduditTime != null and endAduditTime != ''">
|
|
|
|
|
AND date_format(io.auditTime, '%Y-%m-%d') between date_format(#{startAduditTime}, '%Y-%m-%d') and
|
|
|
|
|
date_format(#{endAduditTime}, '%Y-%m-%d')
|
|
|
|
|
AND io.auditTime between #{startAduditTime} and #{endAduditTime}
|
|
|
|
|
</if>
|
|
|
|
|
<if test="actions != null and actions.size() != 0">
|
|
|
|
|
AND io.`action` in
|
|
|
|
@ -134,6 +132,13 @@
|
|
|
|
|
</foreach>
|
|
|
|
|
</if>
|
|
|
|
|
|
|
|
|
|
<if test="workplaceCodes != null and workplaceCodes.size() != 0">
|
|
|
|
|
AND io.`workPlaceCode` in
|
|
|
|
|
<foreach collection="workplaceCodes" index="index" item="item" open="(" close=")" separator=",">
|
|
|
|
|
#{item}
|
|
|
|
|
</foreach>
|
|
|
|
|
</if>
|
|
|
|
|
|
|
|
|
|
<if test="sourceTypes != null and sourceTypes.size() != 0">
|
|
|
|
|
AND io.fromType in
|
|
|
|
|
<foreach collection="sourceTypes" index="index" item="item" open="(" close=")" separator=",">
|
|
|
|
@ -257,7 +262,7 @@
|
|
|
|
|
from io_order
|
|
|
|
|
<where>
|
|
|
|
|
<if test="billNo != null and billNo != ''">
|
|
|
|
|
AND billNo like concat( #{billNo}, '%')
|
|
|
|
|
AND billNo like concat(#{billNo}, '%')
|
|
|
|
|
</if>
|
|
|
|
|
<if test="action != null and action != ''">
|
|
|
|
|
AND action = #{action}
|
|
|
|
@ -315,13 +320,11 @@
|
|
|
|
|
SELECT io.*
|
|
|
|
|
FROM io_order io
|
|
|
|
|
WHERE (io.supplementNo IS NULL OR io.supplementNo = '')
|
|
|
|
|
AND EXISTS(
|
|
|
|
|
SELECT 1
|
|
|
|
|
AND EXISTS(SELECT 1
|
|
|
|
|
FROM basic_bussiness_type bbt
|
|
|
|
|
WHERE bbt.action = io.action
|
|
|
|
|
AND bbt.supplementOrderType IS NOT NULL
|
|
|
|
|
AND bbt.supplementOrderType != ''
|
|
|
|
|
)
|
|
|
|
|
AND bbt.supplementOrderType != '')
|
|
|
|
|
</select>
|
|
|
|
|
|
|
|
|
|
<select id="selectBillNos" resultType="com.glxp.api.res.inout.OrderNoResult">
|
|
|
|
@ -331,8 +334,7 @@
|
|
|
|
|
</select>
|
|
|
|
|
|
|
|
|
|
<select id="selectUploadOrder" resultType="com.glxp.api.res.inout.IoOrderResponse">
|
|
|
|
|
SELECT
|
|
|
|
|
io.*,
|
|
|
|
|
SELECT io.*,
|
|
|
|
|
ioul.result,
|
|
|
|
|
bbt.name AS billTypeName,
|
|
|
|
|
ad.name AS deptName,
|
|
|
|
@ -345,8 +347,7 @@
|
|
|
|
|
aw_from.name AS fromInvName,
|
|
|
|
|
bc_from.name AS fromCorpName,
|
|
|
|
|
bc_customer.name AS customerName
|
|
|
|
|
FROM
|
|
|
|
|
io_order io
|
|
|
|
|
FROM io_order io
|
|
|
|
|
LEFT JOIN
|
|
|
|
|
io_order_upload_log ioul ON io.billNo = ioul.billNo
|
|
|
|
|
LEFT JOIN
|
|
|
|
@ -505,7 +506,7 @@
|
|
|
|
|
or io.outSickInfo like concat('%', #{unionRemark}, '%'))
|
|
|
|
|
</if>
|
|
|
|
|
<if test="billNo != null and billNo != ''">
|
|
|
|
|
AND io.billNo like concat( #{billNo}, '%')
|
|
|
|
|
AND io.billNo like concat(#{billNo}, '%')
|
|
|
|
|
</if>
|
|
|
|
|
<if test="corpOrderId != null and corpOrderId != ''">
|
|
|
|
|
AND io.corpOrderId = #{corpOrderId}
|
|
|
|
|