瀏覽代碼

修改使用情况报告

bihuisong 2 月之前
父節點
當前提交
8b1fdb0716

+ 8 - 44
src/main/java/com/ruoyi/system/service/impl/SysReportServiceImpl.java

@@ -455,53 +455,17 @@ public class SysReportServiceImpl implements ISysReportService {
         if (eventMap.size() > 0) resultMap.putAll(eventMap);
         if (dataMap.size() > 0) resultMap.putAll(dataMap);
         /** 将map转为List **/
-        //set 铁东
-        arr = new String[]{"铁东区", "user_td", "active_td", "rate_td", "count3", "qr3", "qs3", "bjgd3", "bjgdRate3", "today_bjgd3", "today_bjgdRate3", "count101", "updateCount101", "updateRate101"};
+        //set 敖勒召其镇
+        arr = new String[]{"敖勒召其镇", "user_alzq", "active_alzq", "rate_alzq", "count3", "qr3", "qs3", "bjgd3", "bjgdRate3", "today_bjgd3", "today_bjgdRate3", "count101", "updateCount101", "updateRate101"};
         list = setDomain(list, resultMap, arr);
-        //set 铁西
-        arr = new String[]{"铁西区", "user_tx", "active_tx", "rate_tx", "count4", "qr4", "qs4", "bjgd4", "bjgdRate4", "today_bjgd4", "today_bjgdRate4", "count102", "updateCount102", "updateRate102"};
+        //set 城川镇
+        arr = new String[]{"城川镇", "user_ccz", "active_ccz", "rate_ccz", "count", "qr", "qs", "bjgd", "bjgdRate", "today_bjgd", "today_bjgdRate", "count105", "updateCount105", "updateRate105"};
         list = setDomain(list, resultMap, arr);
-        //set 梨树
-        arr = new String[]{"梨树县", "user_ls", "active_ls", "rate_ls", "count", "qr", "qs", "bjgd", "bjgdRate", "today_bjgd", "today_bjgdRate", "count105", "updateCount105", "updateRate105"};
+        //set 昂素镇
+        arr = new String[]{"昂素镇", "user_asz", "active_asz", "rate_asz", "count2", "qr2", "qs2", "bjgd2", "bjgdRate2", "today_bjgd2", "today_bjgdRate2", "count103", "updateCount103", "updateRate103"};
         list = setDomain(list, resultMap, arr);
-        //set 双辽
-        arr = new String[]{"双辽市", "user_sl", "active_sl", "rate_sl", "count2", "qr2", "qs2", "bjgd2", "bjgdRate2", "today_bjgd2", "today_bjgdRate2", "count103", "updateCount103", "updateRate103"};
-        list = setDomain(list, resultMap, arr);
-        //set 伊通
-        arr = new String[]{"伊通县", "user_yt", "active_yt", "rate_yt", "count1", "qr1", "qs1", "bjgd1", "bjgdRate1", "today_bjgd1", "today_bjgdRate1", "count104", "updateCount104", "updateRate104"};
-        list = setDomain(list, resultMap, arr);
-        //set 农业
-        arr = new String[]{"农业", "user_ny", "active_ny", "rate_ny", "ny", "nyqr", "nyqs", "nybjgd", "nybjgdRate", "today_nybjgd", "today_nybjgdRate", "count107", "updateCount107", "updateRate107"};
-        list = setDomain(list, resultMap, arr);
-        //set 林业
-        arr = new String[]{"林业", "user_ly", "active_ly", "rate_ly", "ly", "lyqr", "lyqs", "lybjgd", "lybjgdRate", "today_lybjgd", "today_lybjgdRate", "count106", "updateCount106", "updateRate106"};
-        list = setDomain(list, resultMap, arr);
-        //set 环保
-        arr = new String[]{"环保", "user_hb", "active_hb", "rate_hb", "hb", "hbqr", "hbqs", "hbbjgd", "hbbjgdRate", "today_hbbjgd", "today_hbbjgdRate", "count109", "updateCount109", "updateRate109"};
-        list = setDomain(list, resultMap, arr);
-        //set 资源
-        arr = new String[]{"资源", "user_zrzy", "active_zrzy", "rate_zrzy", "zy", "zyqr", "zyqs", "zybjgd", "zybjgdRate", "today_zybjgd", "today_zybjgdRate", "count112", "updateCount112", "updateRate112"};
-        list = setDomain(list, resultMap, arr);
-        //set 交通
-        arr = new String[]{"交通", "user_jtys", "active_jtys", "rate_jtys", "zy", "zyqr", "zyqs", "zybjgd", "zybjgdRate", "today_zybjgd", "today_zybjgdRate", "count111", "updateCount111", "updateRate111"};
-        list = setDomain(list, resultMap, arr);
-        //set 消防
-        arr = new String[]{"消防", "user_xfzd", "active_xfzd", "rate_xfzd", "xf", "xfqr", "xfqs", "xfbjgd", "xfbjgdRate", "today_xfbjgd", "today_xfbjgdRate", "count113", "updateCount113", "updateRate113"};
-        list = setDomain(list, resultMap, arr);
-        //set 应急
-        arr = new String[]{"应急", "user_yjgl", "active_yjgl", "rate_yjgl", "yj", "yjqr", "yjqs", "yjbjgd", "yjbjgdRate", "today_yjbjgd", "today_yjbjgdRate", "count110", "updateCount110", "updateRate110"};
-        list = setDomain(list, resultMap, arr);
-        //set 水利
-        arr = new String[]{"水利", "user_slj", "active_slj", "rate_slj", "sl", "slqr", "slqs", "slbjgd", "slbjgdRate", "today_slbjgd", "today_slbjgdRate", "count108", "updateCount108", "updateRate108"};
-        list = setDomain(list, resultMap, arr);
-        //set 森侦
-        arr = new String[]{"森侦", "user_sz", "active_sz", "rate_sz", "sz", "szqr", "szqs", "szbjgd", "szbjgdRate", "today_szbjgd", "today_szbjgdRate", "count202", "updateCount202", "updateRate202"};
-        list = setDomain(list, resultMap, arr);
-        //set 发改
-        arr = new String[]{"发改", "user_fg", "active_fg", "rate_fg", "fg", "fgqr", "fgqs", "fgbjgd", "fgbjgdRate", "today_fgbjgd", "today_fgbjgdRate", "count114", "updateCount114", "updateRate114"};
-        list = setDomain(list, resultMap, arr);
-        //set 公安
-        arr = new String[]{"公安", "user_ga", "active_ga", "rate_ga", "ga", "gaqr", "gaqs", "gabjgd", "gabjgdRate", "today_gabjgd", "today_gabjgdRate", "count201", "updateCount201", "updateRate201"};
+        //set 上海庙镇
+        arr = new String[]{"上海庙镇", "user_shmz", "active_shmz", "rate_shmz", "count1", "qr1", "qs1", "bjgd1", "bjgdRate1", "today_bjgd1", "today_bjgdRate1", "count104", "updateCount104", "updateRate104"};
         list = setDomain(list, resultMap, arr);
         return list;
     }

+ 20 - 80
src/main/resources/mapper/system/SysReportMapper.xml

@@ -386,74 +386,26 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
     </select>
     <select id="selectUserActiveAndRate" resultType="java.util.HashMap">
         SELECT
-        a.user_sl,
-        a.user_yt,
-        a.user_ls,
-        a.user_td,
-        a.user_tx,
-        a.user_ny,
-        a.user_ly,
-        a.user_hb,
-        a.user_zrzy,
-        a.user_jtys,
-        a.user_xfzd,
-        a.user_yjgl,
-        a.user_slj,
-        a.user_sz,
-        a.user_fg,
-        a.user_ga,
-        b.active_sl,
-        b.active_yt,
-        b.active_ls,
-        b.active_td,
-        b.active_tx,
-        b.active_ny,
-        b.active_ly,
-        b.active_hb,
-        b.active_zrzy,
-        b.active_jtys,
-        b.active_xfzd,
-        b.active_yjgl,
-        b.active_slj,
-        b.active_sz,
-        b.active_fg,
-        b.active_ga,
-        CONCAT( IFNULL(FORMAT(( b.active_sl / a.user_sl * 100 ), 2 ), 0.00 ), "%" ) rate_sl,
-        CONCAT( IFNULL(FORMAT(( b.active_yt / a.user_yt * 100 ), 2 ), 0.00 ), "%" ) rate_yt,
-        CONCAT( IFNULL(FORMAT(( b.active_ls / a.user_ls * 100 ), 2 ), 0.00 ), "%" ) rate_ls,
-        CONCAT( IFNULL(FORMAT(( b.active_td / a.user_td * 100 ), 2 ), 0.00 ), "%" ) rate_td,
-        CONCAT( IFNULL(FORMAT(( b.active_tx / a.user_tx * 100 ), 2 ), 0.00 ), "%" ) rate_tx,
-        CONCAT( IFNULL(FORMAT(( b.active_ny / a.user_ny * 100 ), 2 ), 0.00 ), "%" ) rate_ny,
-        CONCAT( IFNULL(FORMAT(( b.active_ly / a.user_ly * 100 ), 2 ), 0.00 ), "%" ) rate_ly,
-        CONCAT( IFNULL(FORMAT(( b.active_hb / a.user_hb * 100 ), 2 ), 0.00 ), "%" ) rate_hb,
-        CONCAT( IFNULL(FORMAT(( b.active_zrzy / a.user_zrzy * 100 ), 2 ), 0.00 ), "%" ) rate_zrzy,
-        CONCAT( IFNULL(FORMAT(( b.active_jtys / a.user_jtys * 100 ), 2 ), 0.00 ), "%" ) rate_jtys,
-        CONCAT( IFNULL(FORMAT(( b.active_xfzd / a.user_xfzd * 100 ), 2 ), 0.00 ), "%" ) rate_xfzd,
-        CONCAT( IFNULL(FORMAT(( b.active_yjgl / a.user_yjgl * 100 ), 2 ), 0.00 ), "%" ) rate_yjgl,
-        CONCAT( IFNULL(FORMAT(( b.active_slj / a.user_slj * 100 ), 2 ), 0.00 ), "%" ) rate_slj,
-        CONCAT( IFNULL( FORMAT(( b.active_sz / a.user_sz * 100 ), 2 ), 0.00 ), "%" ) rate_sz,
-        CONCAT( IFNULL( FORMAT(( b.active_fg / a.user_fg * 100 ), 2 ), 0.00 ), "%" ) rate_fg,
-        CONCAT( IFNULL(FORMAT(( b.active_ga / a.user_ga * 100 ), 2 ), 0.00 ), "%" ) rate_ga
+        a.user_alzq,
+        a.user_ccz,
+        a.user_asz,
+        a.user_shmz,
+        b.active_alzq,
+        b.active_ccz,
+        b.active_asz,
+        b.active_shmz,
+        CONCAT( IFNULL(FORMAT(( b.active_alzq / a.user_alzq * 100 ), 2 ), 0.00 ), "%" ) rate_alzq,
+        CONCAT( IFNULL(FORMAT(( b.active_ccz / a.user_ccz * 100 ), 2 ), 0.00 ), "%" ) rate_ccz,
+        CONCAT( IFNULL(FORMAT(( b.active_asz / a.user_asz * 100 ), 2 ), 0.00 ), "%" ) rate_asz,
+        CONCAT( IFNULL(FORMAT(( b.active_shmz / a.user_shmz * 100 ), 2 ), 0.00 ), "%" ) rate_shmz
         FROM
         (
         SELECT
         "data" AS NAME,
-        count( a.dept_id = 369 OR FIND_IN_SET( 369, a.ancestors ) OR NULL ) user_sl,
-        count( a.dept_id = 370 OR FIND_IN_SET( 370, a.ancestors ) OR NULL ) user_yt,
-        count( a.dept_id = 371 OR FIND_IN_SET( 371, a.ancestors ) OR NULL ) user_ls,
-        count( a.dept_id = 372 OR FIND_IN_SET( 372, a.ancestors ) OR NULL ) user_td,
-        count( a.dept_id = 373 OR FIND_IN_SET( 373, a.ancestors ) OR NULL ) user_tx,
-        count( a.dept_id = 3776 OR FIND_IN_SET( 3776, a.ancestors ) OR NULL ) user_ny,
-        count( a.dept_id = 367 OR FIND_IN_SET( 367, a.ancestors ) OR NULL ) user_ly,
-        count( a.dept_id = 3773 OR FIND_IN_SET( 3773, a.ancestors ) OR NULL ) user_hb,
-        count( a.dept_id = 3772 OR FIND_IN_SET( 3772, a.ancestors ) OR NULL ) user_zrzy,
-        count( a.dept_id = 3775 OR FIND_IN_SET( 3775, a.ancestors ) OR NULL ) user_jtys,
-        count( a.dept_id = 3777 OR FIND_IN_SET( 3777, a.ancestors ) OR NULL ) user_xfzd,
-        count( a.dept_id = 3774 OR FIND_IN_SET( 3774, a.ancestors ) OR NULL ) user_yjgl,
-        count( a.dept_id = 3778 OR FIND_IN_SET( 3778, a.ancestors ) OR NULL ) user_slj,
-        count( a.dept_id = 14449 OR FIND_IN_SET( 14449, a.ancestors ) OR NULL ) user_sz,
-        count( a.dept_id = 14451 OR FIND_IN_SET( 14451, a.ancestors ) OR NULL ) user_fg,
-        count( a.dept_id = 14450 OR FIND_IN_SET( 14450, a.ancestors ) OR NULL ) user_ga
+        count( a.dept_id = 314391 OR FIND_IN_SET( 314391, a.ancestors ) OR NULL ) user_alzq,
+        count( a.dept_id = 314392 OR FIND_IN_SET( 314392, a.ancestors ) OR NULL ) user_ccz,
+        count( a.dept_id = 314393 OR FIND_IN_SET( 314393, a.ancestors ) OR NULL ) user_asz,
+        count( a.dept_id = 314394 OR FIND_IN_SET( 314394, a.ancestors ) OR NULL ) user_shmz
         FROM
         (
         SELECT
@@ -474,22 +426,10 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
         LEFT JOIN (
         SELECT
         "data" AS NAME,
-        count( b.dept_id = 369 OR FIND_IN_SET( 369, b.ancestors ) OR NULL ) active_sl,
-        count( b.dept_id = 370 OR FIND_IN_SET( 370, b.ancestors ) OR NULL ) active_yt,
-        count( b.dept_id = 371 OR FIND_IN_SET( 371, b.ancestors ) OR NULL ) active_ls,
-        count( b.dept_id = 372 OR FIND_IN_SET( 372, b.ancestors ) OR NULL ) active_td,
-        count( b.dept_id = 373 OR FIND_IN_SET( 373, b.ancestors ) OR NULL ) active_tx,
-        count( b.dept_id = 3776 OR FIND_IN_SET( 3776, b.ancestors ) OR NULL ) active_ny,
-        count( b.dept_id = 367 OR FIND_IN_SET( 367, b.ancestors ) OR NULL ) active_ly,
-        count( b.dept_id = 3773 OR FIND_IN_SET( 3773, b.ancestors ) OR NULL ) active_hb,
-        count( b.dept_id = 3772 OR FIND_IN_SET( 3772, b.ancestors ) OR NULL ) active_zrzy,
-        count( b.dept_id = 3775 OR FIND_IN_SET( 3775, b.ancestors ) OR NULL ) active_jtys,
-        count( b.dept_id = 3777 OR FIND_IN_SET( 3777, b.ancestors ) OR NULL ) active_xfzd,
-        count( b.dept_id = 3774 OR FIND_IN_SET( 3774, b.ancestors ) OR NULL ) active_yjgl,
-        count( b.dept_id = 3778 OR FIND_IN_SET( 3778, b.ancestors ) OR NULL ) active_slj,
-        count( b.dept_id = 14449 OR FIND_IN_SET( 14449, b.ancestors ) OR NULL ) active_sz,
-        count( b.dept_id = 14451 OR FIND_IN_SET( 14451, b.ancestors ) OR NULL ) active_fg,
-        count( b.dept_id = 14450 OR FIND_IN_SET( 14450, b.ancestors ) OR NULL ) active_ga
+        count( b.dept_id = 314391 OR FIND_IN_SET( 314391, b.ancestors ) OR NULL ) active_alzq,
+        count( b.dept_id = 314392 OR FIND_IN_SET( 314392, b.ancestors ) OR NULL ) active_ccz,
+        count( b.dept_id = 314393 OR FIND_IN_SET( 314393, b.ancestors ) OR NULL ) active_asz,
+        count( b.dept_id = 314394 OR FIND_IN_SET( 314394, b.ancestors ) OR NULL ) active_shmz
         FROM
         (
         SELECT