From 2c0eb3b5d5f8586406e7be8731e3553ee26665e0 Mon Sep 17 00:00:00 2001
From: zhoushihao <zsh19950802@163.com>
Date: 星期四, 19 十二月 2024 14:24:17 +0800
Subject: [PATCH] 1、大理片笼漏提配置
---
hangzhoumesParent/moduleService/howllowGlassModule/src/main/resources/mapper/HollowBigStorageCageDetailsMapper.xml | 24 ++++++++++++++----------
1 files changed, 14 insertions(+), 10 deletions(-)
diff --git a/hangzhoumesParent/moduleService/howllowGlassModule/src/main/resources/mapper/HollowBigStorageCageDetailsMapper.xml b/hangzhoumesParent/moduleService/howllowGlassModule/src/main/resources/mapper/HollowBigStorageCageDetailsMapper.xml
index 33b44fd..127a511 100644
--- a/hangzhoumesParent/moduleService/howllowGlassModule/src/main/resources/mapper/HollowBigStorageCageDetailsMapper.xml
+++ b/hangzhoumesParent/moduleService/howllowGlassModule/src/main/resources/mapper/HollowBigStorageCageDetailsMapper.xml
@@ -6,6 +6,8 @@
<result column="engineer_id" property="engineerId"/>
<result column="flow_card_id" property="flowCardId"/>
<result column="layer" property="layer"/>
+ <result column="films_id" property="filmsId"/>
+ <result column="thickness" property="thickness"/>
<result column="sum_count" property="sumCount"/>
<result column="pair_count" property="pairCount"/>
<result column="real_count" property="realCount"/>
@@ -39,10 +41,12 @@
</update>
<select id="hollowIsAll" resultMap="baseMap">
- WITH sum_flow_layer_count AS ( SELECT flow_card_id, layer, min( films_id ) AS films_id, count(*) AS sum_count FROM hollow_glass_relation_info GROUP BY flow_card_id, layer ),
- real_flow_layer_count AS ( SELECT flow_card_id, layer, count(*) AS real_count FROM hollow_glass_relation_info WHERE tempering_layout_id IS NOT NULL AND tempering_feed_sequence IS NOT NULL GROUP BY flow_card_id, layer ),
- damage_flow_layer_count AS ( SELECT process_id AS flow_card_id, technology_number AS layer, count(*) as damage_count FROM damage GROUP BY process_id, technology_number )
- ,
+ WITH sum_flow_layer_count AS ( SELECT flow_card_id, layer, min( films_id ) AS films_id, min(thickness) as
+ thickness,count(*) AS sum_count FROM hollow_glass_relation_info GROUP BY flow_card_id, layer ),
+ real_flow_layer_count AS ( SELECT flow_card_id, layer, count(*) AS real_count FROM
+ hollow_big_storage_cage_details t WHERE state = 100 GROUP BY flow_card_id, layer ),
+ damage_flow_layer_count AS ( SELECT process_id AS flow_card_id, technology_number AS layer, count(*) as
+ damage_count FROM damage GROUP BY process_id, technology_number ),
lack_flow_layer_count AS (
SELECT
t.flow_card_id,
@@ -55,9 +59,9 @@
left JOIN damage_flow_layer_count t2 ON t1.flow_card_id = t2.flow_card_id
AND t1.layer = t2.layer
),
- layer_one AS ( SELECT * FROM hollow_glass_relation_info WHERE layer = 1 AND tempering_layout_id IS NOT NULL AND tempering_feed_sequence IS NOT NULL ),
- layer_two AS ( SELECT * FROM hollow_glass_relation_info WHERE layer = 2 AND tempering_layout_id IS NOT NULL AND tempering_feed_sequence IS NOT NULL ),
- layer_three AS ( SELECT * FROM hollow_glass_relation_info WHERE layer = 3 AND tempering_layout_id IS NOT NULL AND tempering_feed_sequence IS NOT NULL )
+ layer_one AS ( SELECT * FROM hollow_big_storage_cage_details WHERE layer = 1 AND state = 100 ),
+ layer_two AS ( SELECT * FROM hollow_big_storage_cage_details WHERE layer = 2 AND state = 100),
+ layer_three AS ( SELECT * FROM hollow_big_storage_cage_details WHERE layer = 3 AND state = 100 )
,
pair_flow_layer_count AS (
SELECT
@@ -67,11 +71,11 @@
layer_one t
INNER JOIN layer_two t1 ON t.flow_card_id = t1.flow_card_id
AND t.virtual_slot = t1.virtual_slot
- AND t.slot_sequence = t1.slot_sequence
+ AND t.sequence = t1.sequence
<if test="totalLayer == 3">
inner join layer_three t2
on t.flow_card_id = t2.flow_card_id and
- t.virtual_slot = t2.virtual_slot and t.slot_sequence = t2.slot_sequence
+ t.virtual_slot = t2.virtual_slot and t.sequence = t2.sequence
</if>
GROUP BY
t.flow_card_id
@@ -81,6 +85,7 @@
t.flow_card_id,
t.layer,
t.films_id,
+ t.thickness,
sum_count,
IFNULL( t3.pair_count, 0 ) AS pair_count,
IFNULL( real_count, 0 ) AS real_count,
@@ -105,7 +110,6 @@
and sum_count = pair_count
</if>
</select>
-
<select id="queryIsAllNeedDispatchVirtualSlot" resultMap="virtualSlotSequenceDTO">
with relation_temp as (
--
Gitblit v1.8.0