Преглед на файлове

Merge branch 'master' of http://git.yvanui.com/hust/wuhan_epi

hudingbo преди 5 години
родител
ревизия
a362039741

+ 7 - 0
whepi-ui/templates/yeweihui/home.ftl

@@ -93,10 +93,17 @@
                         // $('#ribao_famliy').empty();
                         for (var i = 0; i < data.data.length; i++) {
                             var v = data.data[i];
+                            if(i == 0){
+                                $("#xiaoqu").text(v.uptownName);
+                            }
+
                             var t1 = $('<td align="center">' + v.num + '</td>');
                             $("#huiz").append(t1);
                         }
                     },
+                    error: function () {
+                    }
+                });
             }
         });
 

+ 1 - 1
whepi-ui/templates/yeweihui/ribaohuiz.ftl

@@ -1,7 +1,7 @@
 <#assign title="业委会"/>
 <div class="page__bd" style="height: 300px">
     <header class="demos-header">
-        <h1 class="demos-title" id="xiaoqu">抗疫小区</h1>
+        <h1 class="demos-title" id="xiaoqu"></h1>
     </header>
 
     <div id="ribaohuiz"></div>

+ 5 - 4
whepi-web/src/main/java/com/bofeng/dao/RbMapper.java

@@ -43,13 +43,14 @@ public interface RbMapper extends BaseMapper<sysUptownUnit> {
 
     @Select("select * from " +
             "(" +
-            "select count(*) as num,d.user_id as userId from sys_uptown_house a " +
+            "select count(*) as num,d.user_id as userId,e.uptown_name as uptownName from sys_uptown_house a " +
             "inner join sys_uptown_unit b on b.unit_id = a.unit_id " +
+            "inner join sys_uptown e on b.uptown_id = e.uptown_id " +
             "inner join sys_owner c on c.uptown_id = b.uptown_id " +
             "inner join sys_user_role d on d.property_id = c.owner_id and d.role_id = 2 " +
-            "GROUP BY d.user_id " +
+            "GROUP BY d.user_id,e.uptown_name " +
             "union all " +
-            "select DISTINCT count(*) as num,e.user_id as userId from ms_report a " +
+            "select DISTINCT count(*) as num,e.user_id as userId,'' as uptownName from ms_report a " +
             "inner join sys_uptown_house b on a.house_id = b.house_id " +
             "inner join sys_uptown_unit c on c.unit_id = b.unit_id " +
             "inner join sys_owner d on d.uptown_id = c.uptown_id " +
@@ -57,7 +58,7 @@ public interface RbMapper extends BaseMapper<sysUptownUnit> {
             "where a.report_status = 1  and a.report_date = #{reportDate} " +
             "GROUP BY e.user_id " +
             "union all " +
-            "select DISTINCT count(*) as num,e.user_id as userId from ms_report a " +
+            "select DISTINCT count(*) as num,e.user_id as userId,'' as uptownName from ms_report a " +
             "inner join sys_uptown_house b on a.house_id = b.house_id " +
             "inner join sys_uptown_unit c on c.unit_id = b.unit_id " +
             "inner join sys_owner d on d.uptown_id = c.uptown_id " +

+ 3 - 0
whepi-web/src/main/java/com/bofeng/entity/MsSuspected.java

@@ -136,4 +136,7 @@ public class MsSuspected {
 
     @TableField(exist = false)
     private Long userId;
+
+    @TableField(exist = false)
+    private String uptownName;
 }

+ 3 - 3
whepi-web/src/main/resources/application-dev.yml

@@ -63,9 +63,9 @@ spring:
     #driverClassName: com.mysql.jdbc.Driver
     #url: jdbc:mysql://localhost:3306/bofeng_test?autoReconnect=true&useUnicode=true&characterEncoding=utf-8&zeroDateTimeBehavior=convertToNull&useSSL=false
     driverClassName: net.sf.log4jdbc.DriverSpy
-    url: jdbc:log4jdbc:mysql://39.99.148.1:3306/whepi_test?autoReconnect=true&useUnicode=true&characterEncoding=utf-8&zeroDateTimeBehavior=convertToNull&useSSL=false
-    username: whepi_test
-    password: 123456
+    url: jdbc:log4jdbc:mysql://localhost:3306/whepi_test?autoReconnect=true&useUnicode=true&characterEncoding=utf-8&zeroDateTimeBehavior=convertToNull&useSSL=false
+    username: root
+    password:
 
   redis:
     database: 4