Procházet zdrojové kódy

Merge remote-tracking branch 'origin/master'

# Conflicts:
#	whepi-web/src/main/java/com/bofeng/wx/controller/YeWeiHuiController.java
maoyunfeng před 5 roky
rodič
revize
7d55fa9cf6

+ 24 - 0
whepi-doc/group.sql

@@ -18,4 +18,28 @@ create table jm_buy (
 ENGINE = InnoDB
 DEFAULT CHARSET = utf8
 COMMENT = '居民团购表'
+;
+
+drop table if exists jm_tuangou;
+create table jm_tuangou (
+    jm_id           bigint(20)      NOT NULL DEFAULT 0          COMMENT '团购id',
+    user_id         bigint(20)      NOT NULL DEFAULT 0          COMMENT '用户id',
+    uptown_id       bigint(20)      NOT NULL DEFAULT 0          COMMENT '小区ID',
+    tg_title        varchar(20)     NOT NULL DEFAULT ''         COMMENT '团购标题',
+    tg_supplier     varchar(20)     NOT NULL DEFAULT ''         COMMENT '团购供应商',
+    tg_goods        varchar(50)     NOT NULL DEFAULT ''         COMMENT '团购物资(套餐)',
+    tg_price        varchar(20)     NOT NULL DEFAULT ''         COMMENT '价格',
+    tg_min_num      int(11)         NOT NULL DEFAULT 0          COMMENT '最小起订量',
+    tg_end_time     datetime(0)     NOT NULL DEFAULT CURRENT_TIMESTAMP(0) COMMENT '团购截止时间',
+    tg_deliver_time datetime(0)     NOT NULL DEFAULT CURRENT_TIMESTAMP(0) COMMENT '预计送货时间',
+    tg_phone_number varchar(20)     NOT NULL DEFAULT ''         COMMENT '联系人电话',
+    remark          varchar(100)    NOT NULL DEFAULT ''         COMMENT '增补修订',
+    tg_status       int(11)         NOT NULL DEFAULT 0          COMMENT '团购状态:1在团,2发货,3完成,4取消',
+    PRIMARY KEY (jm_id) USING BTREE,
+    INDEX user_id(user_id) USING BTREE,
+    INDEX uptown_id(uptown_id) USING BTREE
+)
+ENGINE = InnoDB
+DEFAULT CHARSET = utf8
+COMMENT = '团购表'
 ;

+ 1 - 58
whepi-ui/templates/home/frag.foot.ftl

@@ -13,61 +13,4 @@
 <script src="${s3('/jquery-weui/1.2.1/js/jquery-weui.min.js')}"></script>
 <script src="${s3('/jquery-weui/1.2.1/js/swiper.min.js')}"></script>
 <script src="${s3('/jquery-weui/1.2.1/js/city-picker.min.js')}"></script>
-<#--<script src="https://www.w3cways.com/demo/vconsole/vconsole.min.js?v=2.2.0"></script>-->
-<script>
-
-    Window.prototype.alert = function(){
-        //创建一个大盒子
-        var box = document.createElement("div");
-        //创建一个关闭按钮
-        var button = document.createElement("button");
-        //定义一个对象保存样式
-        var boxName = {
-            width:"500px",
-            height:"180px",
-            backgroundColor:"#f8f8f8",
-            border:"1px solid #ccc",
-            position:"absolute",
-            top:"50%",
-            left:"50%",
-            margin:"-90px 0 0 -250px",
-            zIndex:"999",
-            textAlign:"center",
-            lineHeight:"180px"
-        }
-        //给元素添加元素
-        for(var k in boxName){
-            box.style[k] = boxName[k];
-        }
-        //把创建的元素添加到body中
-        document.body.appendChild(box);
-        //把alert传入的内容添加到box中
-        if(arguments[0]){
-            box.innerHTML = arguments[0];
-        }
-        button.innerHTML = "关闭";
-        //定义按钮样式
-        var btnName = {
-            border:"1px solid #ccc",
-            backgroundColor:"#fff",
-            width:"70px",
-            height:"30px",
-            textAlign:"center",
-            lineHeight:"30px",
-            outline:"none",
-            position:"absolute",
-            bottom:"10px",
-            right:"20px",
-        }
-        for(var j in btnName){
-            button.style[j] = btnName[j];
-        }
-        //把按钮添加到box中
-        box.appendChild(button);
-        //给按钮添加单击事件
-        button.addEventListener("click",function(){
-            box.style.display = "none";
-        })
-    }
-
-</script>
+<#--<script src="https://www.w3cways.com/demo/vconsole/vconsole.min.js?v=2.2.0"></script>-->

+ 3 - 0
whepi-ui/templates/home/frag.head.ftl

@@ -79,6 +79,9 @@
         .qiu_zhu_weui_tab_bd_item_active {
             display: block !important;
         }
+        .tuan_gou_weui_tab_bd_item_active {
+            display: block !important;
+        }
     </style>
 </head>
 <span hidden="hidden" id="id"></span>

+ 6 - 6
whepi-ui/templates/home/home.ftl

@@ -8,8 +8,8 @@
             <#include "/home/ribao.ftl" /></div>
         <div id="tab2" class="weui-tab__bd-item">
             <#include "/home/qiuzhu.ftl" /></div>
-        <div id="tab3" class="weui-tab__bd-item">
-           <#include "/home/buy.ftl" /></div>
+        <#--<div id="tab3" class="weui-tab__bd-item">-->
+           <#--<#include "/home/buy.ftl" /></div>-->
     <#--<div id="tab4" class="weui-tab__bd-item">-->
     <#--<h1>页面四</h1> </div>-->
     </div>
@@ -22,10 +22,10 @@
             <div class="weui-tabbar__icon"><img src="/static/images/wx/customer_service.png" alt=""></div>
             <p class="weui-tabbar__label" onclick="familyClick()">家庭求助</p>
         </a>
-        <a href="#tab3" class="weui-tabbar__item">
-            <div class="weui-tabbar__icon"><img src="/static/images/wx/upload.png" alt=""></div>
-            <p class="weui-tabbar__label" onclick="buyGroup()">商品团购</p>
-        </a>
+        <#--<a href="#tab3" class="weui-tabbar__item">-->
+            <#--<div class="weui-tabbar__icon"><img src="/static/images/wx/upload.png" alt=""></div>-->
+            <#--<p class="weui-tabbar__label" onclick="buyGroup()">商品团购</p>-->
+        <#--</a>-->
     <#--<a href="#tab4" class="weui-tabbar__item">-->
     <#--<div class="weui-tabbar__icon"> <img src="./images/icon_nav_cell.png" alt=""> </div>-->
     <#--<p class="weui-tabbar__label">我</p>-->

+ 1 - 1
whepi-ui/templates/home/ribao.ftl

@@ -90,7 +90,7 @@
                         <textarea id="shuruqita" class="weui-textarea" placeholder="输入内容(300字内)" rows="5" style="border: 1px solid rgba(0,0,0,.2);box-sizing:border-box; border-radius: 5px; margin-top: 1vh;"></textarea>
                     </div>
                     <div style="display:flex; flex-direction: row; justify-content: space-between; margin-top: 1vh;">
-                        <div style="color: gray;height: 5vh; line-height: 5vh;margin-right: 2vw;width: 30%;">
+                        <div style="color: gray;height: 5vh; line-height: 5vh;margin-right: 2vw;width: 40%;">
                             <button id="ribao_score"  style="height:5vh;" class="weui-btn weui-btn_mini weui-btn_primary">健康评估</button></div>
                             <input id="js_input_score_rezult" class="weui-input" autofocus=""  readonly="readonly" style="border: 1px solid rgba(0,0,0,.2);box-sizing:border-box; border-radius: 5px; height: 5vh;" />
                              <input id="js_input_score_rezult_value" type="text" hidden="hidden" />

+ 14 - 2
whepi-ui/templates/user/changeRole.ftl

@@ -4,6 +4,8 @@
 <div class="weui-tab">
     <div class="weui-tab__bd">
         <input id="userId" type="text" hidden="hidden" value=${user_id!}/>
+        <input id="uptownId" type="text" hidden="hidden" value=${uptown_id!}/>
+        <input id="uptownName" type="text" hidden="hidden" value=${uptown_name!}/>
             <div class="weui-tab__bd-item weui-tab__bd-item--active">
                 <div class="page__bd">
                     <header class="user-header">
@@ -13,6 +15,8 @@
                         <br/>
                         <h1 class="user-title">家园抗击疫情公共服务平台</h1>
                         <br/>
+                        <h1 class="user-title"><#if uptown_name ??>${uptown_name!''}</#if></h1>
+                        <br/>
                         <h1 class="user-title"><#if user ??>${user.nickName!''}</#if>登录</h1>
                         <br/>
                         <br/>
@@ -27,7 +31,7 @@
                                     <i class="weui-icon-checked"></i>
                                 </div>
                                 <div class="weui-cell__bd">
-                                    <p>家庭用户</p>
+                                    <p id="homeName">家庭用户</p>
                                 </div>
                             </label>
                             <label class="weui-cell weui-cell_active weui-check__label" for="s12">
@@ -36,7 +40,7 @@
                                     <i class="weui-icon-checked"></i>
                                 </div>
                                 <div class="weui-cell__bd">
-                                    <p>业委会人员</p>
+                                    <p id="adminName">业委会人员</p>
                                 </div>
                             </label>
                         </div>
@@ -54,6 +58,14 @@
 </body>
 <#include "/home/frag.foot.ftl" />
 <script>
+
+    (function ($){
+      if ($("#uptownId").val() == '1238790987234') {
+          $("#adminName").text('管理员');
+          $("#homeName").text('员工');
+      }
+    })(jQuery);
+
     function login() {
         var userType = $('input:radio:checked').val();
         if (!userType) {

+ 23 - 4
whepi-ui/templates/user/home.ftl

@@ -168,7 +168,7 @@
                     </div>
                     <div class="weui-cell weui-cell_select weui-cell_select-after" id="unitMsg">
                         <div class="weui-cell__hd">
-                            <label for="" class="weui-label">栋/单元</label>
+                            <label for="" class="weui-label" id="danweiTitle">栋/单元</label>
                         </div>
                         <div class="weui-cell__bd">
                             <select class="weui-select" id="unitId" name="select4">
@@ -176,7 +176,7 @@
                         </div>
                     </div>
                     <div id="doorplateMsg">
-                        <div class="weui-cells__title">门牌号码</div>
+                        <div class="weui-cells__title" id="menpaiTitle">门牌号码</div>
                         <div class="weui-cells">
                             <div class="weui-cell">
                                 <div class="weui-cell__bd">
@@ -412,7 +412,7 @@
 
         $("#uptownId").on("change", function () {
             getUptownUnitData();
-            $("#houseId").empty();
+            $("#houseId").empty()
         })
     })
 
@@ -430,6 +430,20 @@
                     }
                     $('#uptownId').append(html);
                     $("#uptownId").val(data[0].uptownId);
+                    var uptownId = $("#uptownId").val();
+                    // console.log("uptownId:"+uptownId);
+                    if (uptownId == '1238790987234') {
+                        console.log("单位");
+                        $("#danweiTitle").text("单位");
+                        $("#menpaiTitle").text("工号");
+                        $("#doorplate").attr("placeholder", "输入工号");
+
+                    } else {
+                        console.log("小区");
+                        $("#danweiTitle").text("栋/单元");
+                        $("#menpaiTitle").text("门牌号码");
+                        $("#doorplate").attr("placeholder", "请输入门牌号码: 如 108");
+                    }
                     getUptownUnitData();
                 }
             }
@@ -447,7 +461,12 @@
                     $("#unitId").empty();
                     var html = "";
                     for (var i = 0; i < data.length; i++) {
-                        html += '<option value="' + data[i].unitId + '">'+data[i].ridgepole+'栋'+data[i].unit+'单元' + '</option>';
+                        var uptownId = $("#uptownId").val();
+                        if (uptownId == '1238790987234') {
+                            html += '<option value="' + data[i].unitId + '">'+data[i].ridgepole+data[i].unit + '</option>';
+                        } else {
+                            html += '<option value="' + data[i].unitId + '">'+data[i].ridgepole+'栋'+data[i].unit+'单元' + '</option>';
+                        }
                     }
                     $('#unitId').append(html);
                     $("#unitId").val(data[0].unitId);

+ 38 - 9
whepi-ui/templates/yeweihui/home.ftl

@@ -1,8 +1,11 @@
-<#assign title="业委会"/>
+<#assign title="管理员"/>
 <#include "/home/frag.head.ftl" />
 
 <div class="weui-tab">
     <input id="userId" type="text" hidden="hidden" value=${user_id!}/>
+    <input id="uptownId" type="text" hidden="hidden" value=${uptown_id!}/>
+    <input id="uptownName" type="text" hidden="hidden" value=${uptown_name!}/>
+
     <div class="weui-tab__bd">
         <div id="tab1" class="weui-tab__bd-item weui-tab__bd-item--active">
         <#--<#include "/yeweihui/ribaoDy.ftl" />-->
@@ -10,6 +13,9 @@
         </div>
         <div id="tab2" class="weui-tab__bd-item">
             <#include "/yeweihui/qiuzhu.ftl" /></div>
+        <#--<div id="tab3" class="weui-tab__bd-item">-->
+            <#--<#include "/yeweihui/tuangou.ftl" />-->
+        <#--</div>-->
     <#--<div id="tab3" class="weui-tab__bd-item">-->
     <#--<h1>页面三</h1> </div>-->
     <#--<div id="tab4" class="weui-tab__bd-item">-->
@@ -24,6 +30,10 @@
             <div class="weui-tabbar__icon"><img src="/static/images/wx/customer_service.png" alt=""></div>
             <p class="weui-tabbar__label">求助</p>
         </a>
+        <a id="tab3a" href="#tab3" class="weui-tabbar__item">
+            <div class="weui-tabbar__icon"><img src="/static/images/wx/customer_service.png" alt=""></div>
+            <p class="weui-tabbar__label">团购</p>
+        </a>
     <#--<a href="#tab3" class="weui-tabbar__item">-->
     <#--<div class="weui-tabbar__icon"> <img src="./images/icon_nav_article.png" alt=""> </div>-->
     <#--<p class="weui-tabbar__label">发现</p>-->
@@ -41,12 +51,13 @@
 <#include "/home/frag.foot.ftl" />
 <script>
     <#include "/yeweihui/ribao.js" />
-<#include "/yeweihui/qiuzhu.js" />
+    <#include "/yeweihui/qiuzhu.js" />
+    <#include "/yeweihui/tuangou.js" />
 
     var taskList = ${taskList!'[]'};
     var statisticsOrderList =${rbList!'[]'};
 
-    var showQZ = ${showQZ!'"-"'};
+    var show = ${show!'"-"'};
 
     (function ($) {
         $(function () {
@@ -73,19 +84,27 @@
 
         ribao_init();
         qiuzhu_init();
-
+        tuangou_init();
 
         $("#ribaohuiz").calendar({
             dateFormat: 'yyyy-mm-dd',
             inputReadOnly: false,
             onChange: function (p, values, displayValues) {
                 var reportDate = values.toString();
-                $("#exportRiBao").attr('href', "/yeweihui/exportRiBao?userId=" + $('#userId').val() + "&date=" + reportDate);
-                console.log(reportDate);
-                $("#exportRiBaoLink").val(window.location.hostname + "/yeweihui/exportRiBao?userId=" + $('#userId').val() + "&date=" + reportDate);
+
+                console.log("uptownId:"+ $('#uptownId').val());
+                if ($('#uptownId').val() == '1238790987234') {
+                    $("#exportRiBao").attr('href', "/epi/lun/exportRiBao?userId=" + $('#userId').val() + "&date=" + reportDate);
+                    $("#doorplateMsg").attr("style", "display: none");
+                } else {
+                    $("#exportRiBao").attr('href', "/epi/yeweihui/exportRiBao?userId=" + $('#userId').val() + "&date=" + reportDate);
+                    $("#doorplateMsg").attr("style", "");
+                }
+                // $("#doorplateMsg").attr("style", "");
+                $("#exportRiBaoLink").val(window.location.hostname + "/epi/yeweihui/exportRiBao?userId=" + $('#userId').val() + "&date=" + reportDate);
                 var userId = $("#userId").val();
                 $.ajax({
-                    url: '/yeweihui/ribaohuiz',
+                    url: '/epi/yeweihui/ribaohuiz',
                     data: {
                         "userCreate": userId,
                         "reportDate": reportDate,
@@ -115,9 +134,19 @@
             $("#tab2a").addClass('weui-bar__item--on');
         }
 
-        if (showQZ != '-') {
+        function selecttuangou() {
+            $("#tab1").removeClass('weui-tab__bd-item--active');
+            $("#tab1a").removeClass('weui-bar__item--on');
+            $("#tab3").addClass('weui-tab__bd-item--active');
+            $("#tab3a").addClass('weui-bar__item--on');
+        }
+
+        if (show === 'qiuzhu') {
             selectqiuzhu();
         }
+        else if (show === 'tuangou') {
+            selecttuangou();
+        }
 
     })(jQuery);
 </script>

+ 2 - 2
whepi-ui/templates/yeweihui/qiuzhuDetail.ftl

@@ -93,7 +93,7 @@
             },
             success: function (data) {
                 $.closePopup();
-                window.location.href = "/yeweihui/home.html?showQZ=true&userId=" + userId;
+                window.location.href = "/yeweihui/home.html?show=qiuzhu&userId=" + userId;
             },
             error: function () {
                 $.alert("网络异常");
@@ -102,7 +102,7 @@
     }
 
     function goback() {
-        window.location.href = "/yeweihui/home.html?showQZ=true&userId=" + userId;
+        window.location.href = "/yeweihui/home.html?show=qiuzhu&userId=" + userId;
     }
 
     function getdealdetail() {

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

@@ -29,7 +29,7 @@
     <#--<p id="btnRB" class="weui-btn weui-btn_primary" href="javascript:" type="hidden">一键通知</p>-->
         <a id="exportRiBao" class="weui-btn weui-btn_primary" href="javascript:">生成报表</a>
     </div>
-    <div id="doorplateMsg">
+    <div id="doorplateMsg" style="display: none">
         <div class="weui-cells__title">复制下面下载链接到浏览器下载</div>
         <div class="weui-cells">
             <div class="weui-cell">

+ 32 - 0
whepi-ui/templates/yeweihui/tgPublish.ftl

@@ -0,0 +1,32 @@
+<#assign title="求助详情"/>
+<#include "/home/frag.head.ftl" />
+
+<div class="weui-tab">
+    <div class="weui-btn-area" style="display: flex; flex-direction: row;">
+        <a class="weui-btn weui-btn_primary" href="javascript:goback();" style="width: 25vw; height: 6vh; line-height: 6vh;">返回</a>
+        <div style="width: 65%;"></div>
+    </div>
+
+    <div class="weui-btn-area">
+
+        <p class="weui-media-box__desc">求助标题</p>
+        <h4 class="weui-media-box__title">sss</h4>
+        <br>
+        <p class="weui-media-box__desc">求助对象</p>
+        <h4 class="weui-media-box__title">sasa</h4>
+        <br>
+        <p class="weui-media-box__desc">求助内容</p>
+        <h4 class="weui-media-box__title">fda</h4>
+        <br>
+    </div>
+</div>
+
+<#include "/home/frag.foot.ftl" />
+
+<script>
+    var userId = ${userId};
+
+    function goback() {
+        window.location.href = "/yeweihui/home.html?show=tuangou&userId=" + userId;
+    }
+</script>

+ 175 - 0
whepi-ui/templates/yeweihui/tuangou.ftl

@@ -0,0 +1,175 @@
+<div class="page__bd">
+    <header class="demos-header">
+        <h1 class="demos-title">团购</h1>
+    </header>
+    <div class="weui-tab">
+        <div class="weui-navbar">
+            <a class="weui-navbar__item weui-bar__item_on" target="#tg_nav1" module="tuan_gou">
+                组织团购
+            </a>
+            <a class="weui-navbar__item" target="#tg_nav2" module="tuan_gou">
+                我的发布
+            </a>
+        </div>
+        <div class="weui-tab__panel content">
+            <div id="tg_nav1" class="weui-tab__bd-item tuan_gou_weui_tab_bd_item_active">
+
+                <div class="weui-btn-area"  style="display: flex; flex-direction: row; justify-content: space-between;">
+                    <div style="display: flex; flex-direction: row; align-items: center; justify-content: space-between;width: 70vw;">
+                        <input id="tg_searchNum1" class="weui-input" placeholder="请输入团购标题" style="background-color: #d1d1d1; height: 5vh;" />
+                    </div>
+                    <a id="tg_btnQZ1" class="weui-btn_primary" style="border: 1px solid rgba(0,0,0,.2);box-sizing:border-box; border-radius: 10px;" href="javascript:">
+                        <div style="width: 20vw; height: 5vh;line-height:5vh; text-align: center; color: white">查询</div>
+                    </a>
+                </div>
+
+                <div class="weui-panel weui-panel_access">
+                    <div style="display: flex; flex-direction: row; color: grey; font-size: medium; line-height: 7vh;">
+                        <div style="width: 40%; text-align: center;">标题</div>
+                        <div style="width: 15%; text-align: center;">已团</div>
+                        <div style="width: 30%; text-align: center;">截止时间</div>
+                        <div style="width: 15%; text-align: center;">状态</div>
+                    </div>
+                    <div id="tg_list1" class="weui-panel__bd">
+                        <a href="javascript:void(0);" style="color: grey;">
+                            <div style="display: flex; flex-direction: row; text-align: center; font-size: small; line-height: 5vh;">
+                            <div style="width: 40%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">蔬菜套餐,猪肉牛肉金针菇等</div>
+                            <div style="width: 15%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">24/100</div>
+                            <div style="width: 30%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">02/02 14:30</div>
+                            <div style="width: 15%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">在团</div>
+                        </div>
+                        </a>
+                        <a href="javascript:void(0);" style="color: grey;">
+                            <div style="display: flex; flex-direction: row; text-align: center; font-size: small; line-height: 5vh;">
+                                <div style="width: 40%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">蔬菜套餐,猪肉牛肉金针菇等</div>
+                                <div style="width: 15%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">24/100</div>
+                                <div style="width: 30%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">02/02 14:30</div>
+                                <div style="width: 15%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">在团</div>
+                            </div>
+                        </a>
+                        <a href="javascript:void(0);" style="color: grey;">
+                            <div style="display: flex; flex-direction: row; text-align: center; font-size: small; line-height: 5vh;">
+                                <div style="width: 40%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">蔬菜套餐,猪肉牛肉金针菇等</div>
+                                <div style="width: 15%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">24/100</div>
+                                <div style="width: 30%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">02/02 14:30</div>
+                                <div style="width: 15%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">在团</div>
+                            </div>
+                        </a>
+                        <a href="javascript:void(0);" style="color: grey;">
+                            <div style="display: flex; flex-direction: row; text-align: center; font-size: small; line-height: 5vh;">
+                                <div style="width: 40%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">蔬菜套餐,猪肉牛肉金针菇等</div>
+                                <div style="width: 15%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">24/100</div>
+                                <div style="width: 30%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">02/02 14:30</div>
+                                <div style="width: 15%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">在团</div>
+                            </div>
+                        </a>
+                        <a href="javascript:void(0);" style="color: grey;">
+                            <div style="display: flex; flex-direction: row; text-align: center; font-size: small; line-height: 5vh;">
+                                <div style="width: 40%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">蔬菜套餐,猪肉牛肉金针菇等</div>
+                                <div style="width: 15%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">24/100</div>
+                                <div style="width: 30%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">02/02 14:30</div>
+                                <div style="width: 15%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">在团</div>
+                            </div>
+                        </a>
+                        <a href="javascript:void(0);" style="color: grey;">
+                            <div style="display: flex; flex-direction: row; text-align: center; font-size: small; line-height: 5vh;">
+                                <div style="width: 40%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">蔬菜套餐,猪肉牛肉金针菇等</div>
+                                <div style="width: 15%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">24/100</div>
+                                <div style="width: 30%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">02/02 14:30</div>
+                                <div style="width: 15%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">在团</div>
+                            </div>
+                        </a>
+                        <a href="javascript:void(0);" style="color: grey;">
+                            <div style="display: flex; flex-direction: row; text-align: center; font-size: small; line-height: 5vh;">
+                                <div style="width: 40%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">蔬菜套餐,猪肉牛肉金针菇等</div>
+                                <div style="width: 15%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">24/100</div>
+                                <div style="width: 30%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">02/02 14:30</div>
+                                <div style="width: 15%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">在团</div>
+                            </div>
+                        </a>
+                        <a href="javascript:void(0);" style="color: grey;">
+                            <div style="display: flex; flex-direction: row; text-align: center; font-size: small; line-height: 5vh;">
+                                <div style="width: 40%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">蔬菜套餐,猪肉牛肉金针菇等</div>
+                                <div style="width: 15%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">24/100</div>
+                                <div style="width: 30%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">02/02 14:30</div>
+                                <div style="width: 15%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">在团</div>
+                            </div>
+                        </a>
+                        <a href="javascript:void(0);" style="color: grey;">
+                            <div style="display: flex; flex-direction: row; text-align: center; font-size: small; line-height: 5vh;">
+                                <div style="width: 40%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">蔬菜套餐,猪肉牛肉金针菇等</div>
+                                <div style="width: 15%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">24/100</div>
+                                <div style="width: 30%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">02/02 14:30</div>
+                                <div style="width: 15%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">在团</div>
+                            </div>
+                        </a>
+                        <a href="javascript:void(0);" style="color: grey;">
+                            <div style="display: flex; flex-direction: row; text-align: center; font-size: small; line-height: 5vh;">
+                                <div style="width: 40%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">蔬菜套餐,猪肉牛肉金针菇等</div>
+                                <div style="width: 15%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">24/100</div>
+                                <div style="width: 30%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">02/02 14:30</div>
+                                <div style="width: 15%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">在团</div>
+                            </div>
+                        </a>
+                        <a href="javascript:void(0);" style="color: grey;">
+                            <div style="display: flex; flex-direction: row; text-align: center; font-size: small; line-height: 5vh;">
+                                <div style="width: 40%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">蔬菜套餐,猪肉牛肉金针菇等</div>
+                                <div style="width: 15%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">24/100</div>
+                                <div style="width: 30%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">02/02 14:30</div>
+                                <div style="width: 15%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">在团</div>
+                            </div>
+                        </a>
+                        <a href="javascript:void(0);" style="color: grey;">
+                            <div style="display: flex; flex-direction: row; text-align: center; font-size: small; line-height: 5vh;">
+                                <div style="width: 40%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">蔬菜套餐,猪肉牛肉金针菇等</div>
+                                <div style="width: 15%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">24/100</div>
+                                <div style="width: 30%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">02/02 14:30</div>
+                                <div style="width: 15%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">在团</div>
+                            </div>
+                        </a>
+                    </div>
+                    <div class="weui-btn-area">
+                        <a id="tg_publish" class="weui-btn weui-btn_primary">
+                            发布新团购
+                        </a>
+                    </div>
+                    <div style="line-height: 55px;">
+                        <br>
+                    </div>
+                </div>
+            </div>
+            <div id="tg_nav2" class="weui-tab__bd-item">
+
+                <div class="weui-btn-area"  style="display: flex; flex-direction: row; justify-content: space-between;">
+                    <div style="display: flex; flex-direction: row; align-items: center; justify-content: space-between;width: 70vw;">
+                        <input id="tg_searchNum2" class="weui-input" placeholder="请输入团购标题" style="background-color: #d1d1d1; height: 5vh;" />
+                    </div>
+                    <a id="tg_btnQZ2" class="weui-btn_primary" style="border: 1px solid rgba(0,0,0,.2);box-sizing:border-box; border-radius: 10px;" href="javascript:">
+                        <div style="width: 20vw; height: 5vh;line-height:5vh; text-align: center; color: white">查询</div>
+                    </a>
+                </div>
+
+                <div class="weui-panel weui-panel_access">
+                    <div id="tg_list2" class="weui-panel__bd">
+                        <a href="javascript:void(0);" style="color: grey;">
+                            <div style="display: flex; flex-direction: row; text-align: center; font-size: small; line-height: 5vh;">
+                                <div style="width: 40%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">蔬菜套餐,猪肉牛肉金针菇等</div>
+                                <div style="width: 15%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">24/100</div>
+                                <div style="width: 30%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">02/02 14:30</div>
+                                <div style="width: 15%; overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">在团</div>
+                            </div>
+                        </a>
+                    </div>
+                    <div class="weui-btn-area">
+                        <a id="tg_publish" class="weui-btn weui-btn_primary">
+                            发布新团购
+                        </a>
+                    </div>
+                    <div style="line-height: 55px;">
+                        <br>
+                    </div>
+                </div>
+            </div>
+        </div>
+    </div>
+</div>

+ 5 - 0
whepi-ui/templates/yeweihui/tuangou.js

@@ -0,0 +1,5 @@
+function tuangou_init(tt) {
+    $('#tg_publish').on('click', function () {
+        window.location.href = "/yeweihui/tgPublish.html?userId=" + $('#userId').val();
+    });
+};

+ 15 - 0
whepi-web/src/main/java/com/bofeng/dao/RbMapper.java

@@ -92,6 +92,19 @@ public interface RbMapper extends BaseMapper<sysUptownUnit> {
                     "inner join sys_uptown_unit suu on suu.unit_id = suh.unit_id and suu.uptown_id=#{uptownId} "+
                     "left join sys_uptown_home suho on suho.house_id = suh.house_id order by doorplate asc"
     )
+    List<ExcelRiBaoLY> selectExcelRiBaoLY(@Param("uptownId") Long uptownId, @Param("date") String date);
+
+    @Select(
+            "select suu.ridgepole,suu.unit,suh.doorplate,suho.linkman,suho.phone,msr.safety_num as safetyNum," +
+                    "msr.sure_num as sureNum,msr.suspected_num as suspectedNum,msr.normal_num as normalNum," +
+                    "msr.single_num as singleNum,mss.user_name as userName,mss.grender," +
+                    "mss.age,mss.family_status as familyStatus,mss.medical,mss.temperature,mss.cough,mss.muscle ,mss.dyspnea," +
+                    "mss.fatigue,mss.diarrhea,mss.single_room as singleRoom from ms_suspected mss "+
+                    "inner join ms_report msr on msr.report_id = mss.report_id and msr.report_date = #{date} "+
+                    "inner join sys_uptown_house suh on suh.house_id = msr.house_id "+
+                    "inner join sys_uptown_unit suu on suu.unit_id = suh.unit_id and suu.uptown_id=#{uptownId} "+
+                    "left join sys_uptown_home suho on suho.house_id = suh.house_id order by doorplate asc"
+    )
     List<ExcelRiBaoPrivate> selectExcelRiBaoPrivate(@Param("uptownId") Long uptownId, @Param("date") String date);
 
     @Select(
@@ -102,4 +115,6 @@ public interface RbMapper extends BaseMapper<sysUptownUnit> {
                     "where ur.role_id = 1 and ur.user_id = #{userId} "
     )
     List<Uptown> selectUptown(@Param("userId") Long userId);
+
+
 }

+ 201 - 0
whepi-web/src/main/java/com/bofeng/entity/ExcelRiBaoLY.java

@@ -0,0 +1,201 @@
+package com.bofeng.entity;
+
+import com.alibaba.excel.annotation.ExcelProperty;
+import lombok.Getter;
+import lombok.Setter;
+
+import java.math.BigDecimal;
+
+@Getter
+@Setter
+public class ExcelRiBaoLY {
+
+    private String ridgepole;
+    private String unit;
+    private String doorplate;
+    private int grender;
+    private int familyStatus;
+    private int medical;
+    private int cough;
+    private int muscle;
+    private int dyspnea;
+    private int fatigue;
+    private int diarrhea;
+    private int singleRoom;
+    private String statusDesp = "";
+    private String others = "";
+
+
+    @ExcelProperty(value = "单位", index = 0)
+    private String loudong = "";
+
+    public String getLoudong() {
+        if (loudong.length() <= 0) {
+            loudong = ridgepole + unit;
+        }
+        return loudong;
+    }
+
+    @ExcelProperty(value = "工号", index = 1)
+    private String fanghao = "";
+
+    public String getFanghao() {
+        if (fanghao.length() <= 0) {
+            fanghao = doorplate;
+        }
+        return fanghao;
+    }
+
+    @ExcelProperty(value = "联系人", index = 2)
+    private String linkman;
+
+    @ExcelProperty(value = "联系电话", index = 3)
+    private String phone;
+
+    @ExcelProperty(value = "今日居家人数", index = 4)
+    private int safetyNum;
+
+    @ExcelProperty(value = "确诊人数", index = 5)
+    private int sureNum;
+
+    @ExcelProperty(value = "隔离人数", index = 6)
+    private int singleNum;
+
+    @ExcelProperty(value = "异常观察人数", index = 7)
+    private int suspectedNum;
+
+    @ExcelProperty(value = "身体正常人数", index = 8)
+    private int normalNum;
+
+    @ExcelProperty(value = "居家人员姓名", index = 9)
+    private String userName;
+//
+//    @ExcelProperty(value = "性别", index = 10)
+//    private String grenderStr;
+
+//    public String getGrenderStr() {
+//        if (grender == 1) {
+//            grenderStr = "男";
+//        } else if (grender == 2) {
+//            grenderStr = "女";
+//        } else {
+//            grenderStr = "未知";
+//        }
+//        return grenderStr;
+//    }
+
+//    @ExcelProperty(value = "年龄", index = 11)
+//    private String age;
+
+    @ExcelProperty(value = "体温", index = 10)
+    private BigDecimal temperature;
+
+    @ExcelProperty(value = "确诊", index = 11)
+    private String medicalStr;
+    public String getMedicalStr() {
+        if (medical == 0) {
+            medicalStr = "否";
+        } else {
+            medicalStr = "是";
+        }
+        return medicalStr;
+    }
+
+    @ExcelProperty(value = "单间隔离", index = 12)
+    private String singleRoomStr;
+    public String getSingleRoomStr() {
+        if (singleRoom == 0) {
+            singleRoomStr = "否";
+        } else {
+            singleRoomStr = "是";
+        }
+        return singleRoomStr;
+    }
+
+//    @ExcelProperty(value = "身体基本情况", index = 14)
+//    private String baseDesc;
+//    public String getBaseDesc() {
+//        if (familyStatus == 0) {
+//            baseDesc = "无病史";
+//        } else if (familyStatus == 1) {
+//            baseDesc = "心血管疾病(服用ARB)";
+//        } else if (familyStatus == 2) {
+//            baseDesc = "心血管疾病(未服用ARB)";
+//        } else if (familyStatus == 3) {
+//            baseDesc = "呼吸系统病史";
+//        } else if (familyStatus == 4) {
+//            baseDesc = "肿瘤病史";
+//        } else if (familyStatus == 5) {
+//            baseDesc = "糖尿病史";
+//        } else if (familyStatus == 6) {
+//            baseDesc = "服用过激素药物";
+//        } else if (familyStatus == 7) {
+//            baseDesc = "妊娠期";
+//        } else {
+//            baseDesc = "其他";
+//        }
+//        return baseDesc;
+//    }
+//
+//    @ExcelProperty(value = "病情描述", index = 15)
+//    private String bingqingDesc = "";
+//    public String getBingqingDesc() {
+//
+//        if (medical == 1) {
+//            bingqingDesc += "已确诊、";
+//        }
+//
+//        if (singleRoom == 1) {
+//            bingqingDesc += "单间隔离、";
+//        }
+//
+//        bingqingDesc = bingqingDesc + "体温:" + temperature + "、";
+//
+//        if (cough == 1) {
+//            bingqingDesc += "偶尔短暂咳嗽、";
+//        } else if (cough == 2) {
+//            bingqingDesc += "咳嗽轻度影响生活、";
+//        } else if (cough == 3) {
+//            bingqingDesc += "咳嗽严重影响生活、";
+//        }
+//        if (muscle == 1) {
+//            bingqingDesc += "肌肉按压有酸痛、";
+//        } else if (muscle == 2) {
+//            bingqingDesc += "偶尔肌肉按压酸痛、";
+//        } else if (muscle == 3) {
+//            bingqingDesc += "肌肉按压持续酸痛、";
+//        }
+//        if (dyspnea == 1) {
+//            bingqingDesc += "呼吸急走或上坡气短、";
+//        } else if (dyspnea == 2) {
+//            bingqingDesc += "呼吸气短而走路变慢、";
+//        } else if (dyspnea == 3) {
+//            bingqingDesc += "呼吸走路数分钟后气短、";
+//        } else if (dyspnea == 4) {
+//            bingqingDesc += "呼吸气短无法离开房间、";
+//        }
+//        if (fatigue == 1) {
+//            bingqingDesc += "可体力劳动但觉得累、";
+//        } else if (fatigue == 2) {
+//            bingqingDesc += "轻体力劳动后长时间不能恢复、";
+//        } else if (fatigue == 3) {
+//            bingqingDesc += "不能正常生活、";
+//        }
+//        if (diarrhea == 1) {
+//            bingqingDesc += "轻度腹泻少于于3次、";
+//        } else if (diarrhea == 2) {
+//            bingqingDesc += "中度腹泻4-6次、";
+//        } else if (diarrhea == 3) {
+//            bingqingDesc += "重度腹泻超过6次、";
+//        }
+//
+//        if (!Strings.isNullOrEmpty(statusDesp)) {
+//            bingqingDesc += statusDesp;
+//            bingqingDesc += "、";
+//        }
+//        if (!Strings.isNullOrEmpty(others)) {
+//            bingqingDesc += others;
+//        }
+//        return bingqingDesc;
+//    }
+}

+ 80 - 0
whepi-web/src/main/java/com/bofeng/entity/JmTuangou.java

@@ -0,0 +1,80 @@
+package com.bofeng.entity;
+
+import lombok.Data;
+
+import java.io.Serializable;
+import java.util.Date;
+
+/**
+ * jm_tuangou
+ * @author 
+ */
+@Data
+public class JmTuangou implements Serializable {
+    /**
+     * 团购id
+     */
+    private Long jmId;
+
+    /**
+     * 用户id
+     */
+    private Long userId;
+
+    /**
+     * 小区ID
+     */
+    private Long uptownId;
+
+    /**
+     * 团购标题
+     */
+    private String tgTitle;
+
+    /**
+     * 团购供应商
+     */
+    private String tgSupplier;
+
+    /**
+     * 团购物资(套餐)
+     */
+    private String tgGoods;
+
+    /**
+     * 价格
+     */
+    private String tgPrice;
+
+    /**
+     * 最小起订量
+     */
+    private Integer tgMinNum;
+
+    /**
+     * 团购截止时间
+     */
+    private Date tgEndTime;
+
+    /**
+     * 预计送货时间
+     */
+    private Date tgDeliverTime;
+
+    /**
+     * 联系人电话
+     */
+    private String tgPhoneNumber;
+
+    /**
+     * 增补修订
+     */
+    private String remark;
+
+    /**
+     * 团购状态:1在团,2发货,3完成,4取消
+     */
+    private Integer tgStatus;
+
+    private static final long serialVersionUID = 1L;
+}

+ 24 - 4
whepi-web/src/main/java/com/bofeng/wx/controller/UserOpenController.java

@@ -52,6 +52,8 @@ public class UserOpenController {
     private RbService rbService;
     @Autowired
     private MsReportService msReportService;
+    @Autowired
+    private RbMapper rbMapper;
 
     @ApiOperation("登陆首页")
     @ApiImplicitParams({@ApiImplicitParam(name = "userId", value = "用户ID", required = false, dataType = "Long",paramType="query"),
@@ -62,13 +64,23 @@ public class UserOpenController {
                              @RequestParam(value = "userType", required = false,defaultValue = "0") Integer userType) throws JsonProcessingException {
         List<UserRole> list = new ArrayList<>();
         if (userId == 0) {
-           /* UserOpen userOpen = homeService.getUserOpen();
-            list = userRoleMapper.getUserRoleByUserId(userOpen.getUserId());*/
-            list = userRoleMapper.getUserRoleByUserId(1225321682867105793L);
-            UserOpen userOpen = userOpenMapper.selectByUserId(1225321682867105793L);
+            UserOpen userOpen = homeService.getUserOpen();
+            list = userRoleMapper.getUserRoleByUserId(userOpen.getUserId());
+//            list = userRoleMapper.getUserRoleByUserId(1225321682867105793L);
+//            UserOpen userOpen = userOpenMapper.selectByUserId(1225321682867105793L);
             userId = userOpen.getUserId();
             model.put("user", userOpen);
             model.put("user_id", "\""+userOpen.getUserId()+"\"");
+
+            List<Uptown> uptowns = rbMapper.selectUptown(userId);
+            if (uptowns!=null && uptowns.size()>0) {
+                Long uptown_id = uptowns.get(0).getUptownId();
+                String uptown_name = uptowns.get(0).getUptownName();
+                model.put("uptown_id", "\""+uptown_id+"\"");
+                model.put("uptown_name", uptown_name);
+            }
+
+
             if (list.size() == 0) {
                 return new ModelAndView("/user/home.ftl", model);
             }
@@ -99,6 +111,13 @@ public class UserOpenController {
                              @RequestParam(value = "userType", required = false,defaultValue = "0") Integer userType) throws JsonProcessingException {
         if (userId != 0 && userType != 0) {
             model.put("user_id", "\"" + userId + "\"");
+            List<Uptown> uptowns = rbMapper.selectUptown(userId);
+            if (uptowns!=null && uptowns.size()>0) {
+                Long uptown_id = uptowns.get(0).getUptownId();
+                String uptown_name = uptowns.get(0).getUptownName();
+                model.put("uptown_id", "\""+uptown_id+"\"");
+                model.put("uptown_name", uptown_name);
+            }
             if (userType == 1) {
                 MsReport msReport = msReportService.getReportByDateNow(userId);
                 model.put("msReport", new JsonWapper(msReport));
@@ -108,6 +127,7 @@ public class UserOpenController {
                 model.put("taskList", YvanUtil.toJsonPretty(taskList));
                 List<sysUptownUnit> rbList = rbService.selectAll(userId);
                 model.put("rbList", YvanUtil.toJsonPretty(rbList));
+
                 return new ModelAndView("/yeweihui/home.ftl", model);
             }
         }

+ 55 - 4
whepi-web/src/main/java/com/bofeng/wx/controller/YeWeiHuiController.java

@@ -1,6 +1,7 @@
 package com.bofeng.wx.controller;
 
 import com.bofeng.dao.RbMapper;
+import com.bofeng.dao.UptownMapper;
 import com.bofeng.entity.*;
 import com.bofeng.excel.ExcelUtils;
 import com.bofeng.service.HomeService;
@@ -45,10 +46,13 @@ public class YeWeiHuiController {
     private HomeService homeService;
 
     @Autowired
+    private UptownMapper uptownMapper;
+
+    @Autowired
     private RbMapper rbMapper;
 
     @GetMapping("/yeweihui/home.html")
-    public ModelAndView yeweihui(ModelMap model,@RequestParam(value = "userId") Long userId) {
+    public ModelAndView yeweihui(ModelMap model,@RequestParam(value = "userId") Long userId, @RequestParam(value = "showQZ", required = false, defaultValue = "-") String showQZ) {
 
 //        List<QzTask> taskList = qzTaskService.selectAll(1225321682867105793L);
 //        List<sysUptownUnit> rbList = rbService.selectAll(1225321682867105793L);
@@ -57,6 +61,7 @@ public class YeWeiHuiController {
         model.put("taskList", YvanUtil.toJsonPretty(taskList));
         model.put("rbList", YvanUtil.toJsonPretty(rbList));
         model.put("user_id", "\""+userId+"\"");
+        model.put("showQZ", "\""+showQZ+"\"");
 
         return new ModelAndView("/yeweihui/home.ftl", model);
     }
@@ -183,8 +188,8 @@ public class YeWeiHuiController {
     }
 
     @GetMapping("/yeweihui/ribaohuiz")
-    public Model<Map<String, Object>> yeweihuiRibaohuiz(/*Long userCreate,*/String reportDate) {
-        Long userCreate = 1226159827797225474L;
+    public Model<Map<String, Object>> yeweihuiRibaohuiz(Long userCreate,String reportDate) {
+//        Long userCreate = 1225321682867105793L;
 
         List<Uptown> uptowns = rbMapper.selectUptown(userCreate);
 
@@ -192,11 +197,12 @@ public class YeWeiHuiController {
             Long upId = uptowns.get(0).getUptownId();
             Map<String, Integer> map1 = rbMapper.selecthuiz(upId,reportDate);
             Map<String, Integer> map2 = rbMapper.selectyicahng(upId,reportDate);
+            Map<String, Integer> map3 = rbMapper.selecthuiz1(upId);
 
             Map<String, Object> reMap = Maps.newHashMap();
             reMap.put("uptownName", uptowns.get(0).getUptownName());
             List<Integer> nums = Lists.newArrayList();
-            nums.add(Conv.NI(map1.get("houseCount")));
+            nums.add(Conv.NI(map3.get("houseCount")));
             nums.add(Conv.NI(map1.get("reportCount")));
             nums.add(Conv.NI(map2.get("yichangCount")));
             nums.add(Conv.NI(map1.get("safetyNum")));
@@ -226,4 +232,49 @@ public class YeWeiHuiController {
             ExcelUtils.writeSheet(ExcelRiBao.class, list).export(resp, fileName);
         }
     }
+
+    @ApiOperation("导出家庭上报明细")
+    @GetMapping("/epi/lun/exportRiBao")
+    @SneakyThrows
+    public void lunExportRiBao(@Pd(name = "userId") Long userId,
+                            @Pd(name = "date") String date,
+                            HttpServletResponse resp) {
+
+        List<Uptown> uptowns = rbMapper.selectUptown(userId);
+
+        if (uptowns!=null && uptowns.size()>0) {
+            Long upId = uptowns.get(0).getUptownId();
+            String fileName = uptowns.get(0).getUptownName();
+            fileName += "上报信息-";
+            fileName += date;
+            List<ExcelRiBaoLY> list = rbMapper.selectExcelRiBaoLY(upId,date);
+            ExcelUtils.writeSheet(ExcelRiBaoLY.class, list).export(resp, fileName);
+        }
+    }
+
+    @ApiOperation("导出家庭上报明细")
+    @GetMapping("/epi/yeweihui/EXR")
+    @SneakyThrows
+    public void exportRiBaoByXiaoQu(@Pd(name = "xid") Long xid,
+                            @Pd(name = "d") String d,
+                            HttpServletResponse resp) {
+
+        Uptown uptown = uptownMapper.selectById(xid);
+
+        if (uptown!=null && uptown.getUptownId()>0) {
+            Long upId = uptown.getUptownId();
+            String fileName = uptown.getUptownName();
+            fileName += "上报信息-";
+            fileName += d;
+            List<ExcelRiBaoPrivate> list = rbMapper.selectExcelRiBaoPrivate(upId,d);
+            ExcelUtils.writeSheet(ExcelRiBaoPrivate.class, list).export(resp, fileName);
+        }
+    }
+
+    @GetMapping("/yeweihui/tgPublish.html")
+    public ModelAndView tuangouPublish(@Pd(name = "userId") Long userId, ModelMap model) throws JsonProcessingException {
+        model.put("userId", "\""+userId+"\"");
+
+        return new ModelAndView("/yeweihui/tgPublish.ftl", model);
+    }
 }