|
|
@ -412,7 +412,7 @@ |
|
|
|
|
|
|
|
<select id="selectTrafficControlAnalysis" resultType="java.util.Map"> |
|
|
|
select t1.controlCause,t1.controlCauseName,IFNULL(t2.facilityClose,0) facilityClose, |
|
|
|
IFNULL(t2.facilityRestriction,0) facilityRestriction,IFNULL(t2.facilityInterval,0) facilityInterval |
|
|
|
IFNULL(t2.facilityRestriction,0) facilityRestriction |
|
|
|
from |
|
|
|
(select '1' controlCause,'车流量大' controlCauseName |
|
|
|
union all select '2' controlCause,'交通事故' controlCauseName |
|
|
@ -424,9 +424,8 @@ |
|
|
|
left join |
|
|
|
(select |
|
|
|
t2.control_cause, |
|
|
|
SUM(case when t2.classify = '6' then 1 else 0 end) facilityClose, |
|
|
|
SUM(case when t2.classify = '7' then 1 else 0 end) facilityRestriction, |
|
|
|
SUM(case when t2.classify = '9' then 1 else 0 end) facilityInterval |
|
|
|
SUM(case when t2.control_type = '1' then 1 else 0 end) facilityClose, |
|
|
|
SUM(case when t2.control_type = '2' then 1 else 0 end) facilityRestriction |
|
|
|
from dc_event t1 |
|
|
|
LEFT JOIN dc_event_traffic_control t2 on t1.id = t2.id |
|
|
|
where |
|
|
|