|
@@ -1568,6 +1568,8 @@
|
|
|
table2.weight "weight",
|
|
|
-- 炉号生产的第一件钢材时间
|
|
|
table3.onetime "onetime",
|
|
|
+-- 炉号生产的最新钢材时间
|
|
|
+ table3.newtime "newtime",
|
|
|
-- 生产物资型号
|
|
|
RM.MATERIAL_NAME || RM.MATERIAL_SPECIFICATION || '(' ||
|
|
|
RM.MATERIAL_MODEL || ')' "materialName",
|
|
@@ -1627,6 +1629,7 @@
|
|
|
LEFT JOIN(
|
|
|
SELECT
|
|
|
MIN(WIR4.INSERT_TIME) onetime,
|
|
|
+ MAX(WIR4.INSERT_TIME) newtime,
|
|
|
MATERIAL_FURNACE_NUMBER "furnaceNumber3"
|
|
|
FROM
|
|
|
WMSP_INBOUND_RESULT WIR4
|
|
@@ -1652,7 +1655,39 @@
|
|
|
AND to_date(#{startDate}, 'yyyy-mm-dd hh24:mi:ss') <= WIR.INBOUND_TIME
|
|
|
AND to_date(#{endDate}, 'yyyy-mm-dd hh24:mi:ss') >= WIR.INBOUND_TIME
|
|
|
</if>
|
|
|
- AND WIR.RESULT_DELETED = 0 ORDER BY table3.onetime ASC
|
|
|
+ AND WIR.RESULT_DELETED = 0
|
|
|
+ <where>
|
|
|
+ <if test="count != null">
|
|
|
+ and "count" in
|
|
|
+ <foreach collection="count" item="item" open="(" separator="," close=")">
|
|
|
+ #{item}
|
|
|
+ </foreach>
|
|
|
+ </if>
|
|
|
+ <if test="weight != null">
|
|
|
+ and "weight" in
|
|
|
+ <foreach collection="weight" item="item" open="(" separator="," close=")">
|
|
|
+ #{item}
|
|
|
+ </foreach>
|
|
|
+ </if>
|
|
|
+ <if test="onetime != null">
|
|
|
+ and "onetime" in
|
|
|
+ <foreach collection="onetime" item="item" open="(" separator="," close=")">
|
|
|
+ #{item}
|
|
|
+ </foreach>
|
|
|
+ </if>
|
|
|
+ <if test="materialName != null">
|
|
|
+ and "materialName" in
|
|
|
+ <foreach collection="materialName" item="item" open="(" separator="," close=")">
|
|
|
+ #{item}
|
|
|
+ </foreach>
|
|
|
+ </if>
|
|
|
+ <if test="furnaceNumber1 != null">
|
|
|
+ and "furnaceNumber1" in
|
|
|
+ <foreach collection="furnaceNumber1" item="item" open="(" separator="," close=")">
|
|
|
+ #{item}
|
|
|
+ </foreach>
|
|
|
+ </if>
|
|
|
+ </where>
|
|
|
<include refid="orderBy"></include>
|
|
|
</select>
|
|
|
|