|
@@ -42,9 +42,7 @@
|
|
sum(his_stagnation_amount) hisStagnationAmount,
|
|
sum(his_stagnation_amount) hisStagnationAmount,
|
|
sum(his_falling_bed_amount) hisFallingBedAmount,
|
|
sum(his_falling_bed_amount) hisFallingBedAmount,
|
|
sum(his_active_call_amount) hisActiveCallAmount,
|
|
sum(his_active_call_amount) hisActiveCallAmount,
|
|
- sum(his_outdoors_call_amount) hisOutdoorsCallAmount,
|
|
|
|
- sum(seats_amount) seatsAmount,
|
|
|
|
- convert(sum(seats_online_duration)/3600,decimal(20,2)) seatsOnlineDuration
|
|
|
|
|
|
+ sum(his_outdoors_call_amount) hisOutdoorsCallAmount
|
|
FROM st_station t
|
|
FROM st_station t
|
|
<where>
|
|
<where>
|
|
1 = 1
|
|
1 = 1
|
|
@@ -57,6 +55,19 @@
|
|
</where>
|
|
</where>
|
|
</select>
|
|
</select>
|
|
|
|
|
|
|
|
+ <select id="selectBigScreenOrgStatistics" resultType="com.care.bigscreen.vo.BigScreenStatisticsVO">
|
|
|
|
+ SELECT
|
|
|
|
+ sum(seats_amount) seatsAmount,
|
|
|
|
+ convert(sum(seats_online_duration)/3600,decimal(20,2)) seatsOnlineDuration
|
|
|
|
+ FROM st_organization t
|
|
|
|
+ <where>
|
|
|
|
+ 1 = 1
|
|
|
|
+ <if test="orgId != null and orgId != ''">
|
|
|
|
+ AND t.org_id = #{orgId}
|
|
|
|
+ </if>
|
|
|
|
+ </where>
|
|
|
|
+ </select>
|
|
|
|
+
|
|
<!--根据经纬度查询-->
|
|
<!--根据经纬度查询-->
|
|
<select id="selectBigScreenStatisticsByLongitudeLatitude" resultType="com.care.bigscreen.vo.BigScreenStatisticsVO">
|
|
<select id="selectBigScreenStatisticsByLongitudeLatitude" resultType="com.care.bigscreen.vo.BigScreenStatisticsVO">
|
|
SELECT
|
|
SELECT
|
|
@@ -134,9 +145,9 @@
|
|
a.chamberlain_amount chamberlainAmount,
|
|
a.chamberlain_amount chamberlainAmount,
|
|
a.serve_amount serveAmount,
|
|
a.serve_amount serveAmount,
|
|
a.serve_today_amount serveTodayAmount,
|
|
a.serve_today_amount serveTodayAmount,
|
|
- a.seats_amount seatsAmount,
|
|
|
|
- a.seats_curr_online_amount seatsCurrOnlineAmount,
|
|
|
|
- a.seats_call_min_amount seatsCallMinAmount
|
|
|
|
|
|
+ (select b.seats_amount from st_organization b where b.org_id=a.org_id) seatsAmount,
|
|
|
|
+ (select b.seats_curr_online_amount from st_organization b where b.org_id=a.org_id) seatsCurrOnlineAmount,
|
|
|
|
+ (select b.seats_call_min_amount from st_organization b where b.org_id=a.org_id) seatsCallMinAmount
|
|
FROM st_station a
|
|
FROM st_station a
|
|
where a.station_id = #{stationId}
|
|
where a.station_id = #{stationId}
|
|
</select>
|
|
</select>
|