From f90c019094eb02b45c390d01a1feebbb910e75d5 Mon Sep 17 00:00:00 2001 From: dearlin <1261008090@qq.com> Date: Wed, 28 Feb 2024 11:51:35 +0800 Subject: [PATCH] =?UTF-8?q?=E8=A7=A3=E5=86=B3=E4=BA=86=20Bug=20=E6=89=93?= =?UTF-8?q?=E5=9B=9E=E5=B9=B6=E5=88=A0=E9=99=A4=E7=9A=84=E6=95=B0=E5=AD=97?= =?UTF-8?q?=E6=B2=A1=E6=9C=89=E5=87=8F=E5=B0=91=2014193?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../eightwork/impl/EightWorkServiceImpl.java | 5 +- .../datasource/eightwork/EightWorkMapper.xml | 58 ++++++++++++++++++- 2 files changed, 60 insertions(+), 3 deletions(-) diff --git a/src/main/java/com/zcloud/service/eightwork/impl/EightWorkServiceImpl.java b/src/main/java/com/zcloud/service/eightwork/impl/EightWorkServiceImpl.java index 0d1d7fd..f35b5c0 100644 --- a/src/main/java/com/zcloud/service/eightwork/impl/EightWorkServiceImpl.java +++ b/src/main/java/com/zcloud/service/eightwork/impl/EightWorkServiceImpl.java @@ -66,9 +66,10 @@ public class EightWorkServiceImpl implements EightWorkService { if(eightworks != null && eightworks.size() > 0){ eightworks.stream().forEach(e -> { staMap.get("total").add(e); - if(e.getString("NEXT_STEP_ID").equals("99")){ + if("99".equals(e.getString("NEXT_STEP_ID"))){ staMap.get("finished").add(e); - }else if(!e.getString("STATUS").equals("-1") && Integer.parseInt(e.getString("NEXT_STEP_ID")) > 1){ + // 被打回 也统计 被删除与暂存 不计入 申请中 + }else if(Integer.parseInt(e.getString("NEXT_STEP_ID")) > 1){ staMap.get("flowing").add(e); } diff --git a/src/main/resources/mybatis/datasource/eightwork/EightWorkMapper.xml b/src/main/resources/mybatis/datasource/eightwork/EightWorkMapper.xml index 3b94c70..ee850b3 100644 --- a/src/main/resources/mybatis/datasource/eightwork/EightWorkMapper.xml +++ b/src/main/resources/mybatis/datasource/eightwork/EightWorkMapper.xml @@ -8,7 +8,63 @@ DATE_FORMAT(tmp.ACT_TIME,'%Y-%m') WORK_MONTH FROM ( SELECT * FROM vi_eightwork_flow_log log - where log.CORPINFO_ID=#{CORPINFO_ID} HAVING 1 ORDER BY log.ACT_TIME DESC ) tmp + where log.CORPINFO_ID=#{CORPINFO_ID} and log.WORK_ID IN ( + SELECT + f.BLINDBOARD_ID id + FROM + BUS_BLINDBOARD f + WHERE + ISDELETE = 0 + AND CORPINFO_ID = #{CORPINFO_ID} UNION ALL + SELECT + f.BREAKGROUND_ID id + FROM + BUS_BREAKGROUND f + WHERE + ISDELETE = 0 + AND CORPINFO_ID = #{CORPINFO_ID} UNION ALL + SELECT + f.CONFINEDSPACE_ID id + FROM + BUS_CONFINEDSPACE f + WHERE + ISDELETE = 0 + AND CORPINFO_ID = #{CORPINFO_ID} UNION ALL + SELECT + f.ELECTRICITY_ID id + FROM + BUS_ELECTRICITY f + WHERE + ISDELETE = 0 + AND CORPINFO_ID = #{CORPINFO_ID} UNION ALL + SELECT + f.CUTROAD_ID id + FROM + BUS_CUTROAD f + WHERE + ISDELETE = 0 + AND CORPINFO_ID = #{CORPINFO_ID} UNION ALL + SELECT + f.HIGHWORK_ID id + FROM + BUS_HIGHWORK f + WHERE + ISDELETE = 0 + AND CORPINFO_ID = #{CORPINFO_ID} UNION ALL + SELECT + f.HOISTING_ID id + FROM + BUS_HOISTING f + WHERE + ISDELETE = 0 + AND CORPINFO_ID = #{CORPINFO_ID} UNION ALL + SELECT + f.HOTWORK_ID id + FROM + BUS_HOTWORK f + WHERE + ISDELETE = 0 + AND CORPINFO_ID = #{CORPINFO_ID}) HAVING 1 ORDER BY log.ACT_TIME DESC ) tmp GROUP BY tmp.WORK_ID order by tmp.ACT_TIME DESC