Browse Source

统计分析功能

zhangyanfang 6 years ago
parent
commit
4054615c86

+ 86 - 7
app/statistics/html/comprehensive-analysis.html

@ -13,6 +13,56 @@
        <link rel="stylesheet" type="text/css" href="../../../css/style.min.css"/>
        <link rel="stylesheet" type="text/css" href="../../../css/cross.css"/>
        <link rel="stylesheet" type="text/css" href="../css/common.css"/>
        <style>
            .tip{
                vertical-align: inherit;
                margin-left: 5px;
            }
            .health-count{
                margin-left: 26.156px;
            }
            .black{
                color: #323232;
            }
            .health-title{
                margin-left: 14px;
            }
            .visible-xs-inline-block{
                display: inline-block;
            }
            .flex-box {
        display: -webkit-box;
        display: -ms-flexbox;
        display: flex;
        -webkit-box-pack: center;
        -ms-flex-pack: center;
        justify-content: space-between;
        -webkit-box-align: center;
        -ms-flex-align: center;
        align-items: baseline;
    }
    .c-w-33{
        height: 191.6px;
    }
    .shadow{
        position: absolute;
        left: 103%;
        top:27px;
       background-color: rgba(50, 50, 50, 0.701961);
       border-color: rgb(51, 51, 51);
       color: rgb(255, 255, 255);
       font-size: 14px;
       font-family: sans-serif;
    border-radius: 4px;
    padding: 5px;
    visibility: hidden;
    min-width: 242px;
    z-index: 99999;
    }
    .shadowr{
        left: -197%;
    }
        </style>
    </head>
    <body>
        <div id="main" class="c-hide">
@ -66,18 +116,47 @@
            <div v-show="index=='5'" class="mt20 c-border bgc-fff">
                <div class="c-border-b plr10 ptb10 c-f16 c-333">全市概况</div>
                <div class="ui-grid ui-grid-middle ptb10">
                    <div class="ui-col-0 c-t-center c-ffc800 plr10 c-w-33">
                        <div class="c-f20 wz-num">{{topDatas['index_83']}}</div>
                        <div class="c-f12">健康文章推送量</div>
                    <div class="ui-col-0 c-t-center c-ffc800 plr15 c-w-33">
                        <!-- <div class="c-f20 wz-num">{{topDatas['index_83']}}</div>
                        <div class="c-f12">健康文章推送量</div> -->
                        <div class="c-f14 health-title" style="padding-bottom: 10px;">健康文章</div>
                        <div class="flex-box" style="margin-top: 47px;">
                            <div style="position: relative;">
                                <div class="c-f16 black">{{topDatas['index_83']}}</div>
                                <div class="c-f12 visible-xs-inline-block health-count black"style="margin-top: 5px;">触达人数</div><img @mouseenter="jumpTip(1)" @mouseleave="leaveTip(1)"class="tip"width="12" src="../../../images/icon_wenhao.png" alt="">
                                <div class="shadow" id="shadow1">以微信绑定账号+家庭成员为统计口径</div>
                            </div>
                            <div style="position: relative;">
                                <div class="c-f16 black">{{topDatas['index_103']}}</div>
                                <div class="visible-xs-inline-block c-f12 health-count black" style="margin-bottom: 33px;margin-top: 5px;">推送人数</div><img @mouseenter="jumpTip(2)" @mouseleave="leaveTip(2)" class="tip"width="12" src="../../../images/icon_wenhao.png" alt="">
                                <div class="shadow" id="shadow2">以微信绑定账号为统计口径</div>
                            </div>
                        </div>
                    </div>
                    <div class="ui-col-1 c-position-r c-t-center">
                        <div class="position-center-text c-f14">推送情况</div>
                        <div class="position-center-text c-f12">推送情况</div>
                        <div id="pieChart" style="width: 100%; height:100px;"></div>
                    </div>
                    <div class="ui-col-0 c-t-center c-17b3ec plr10 c-w-33">
                        <div class="c-f20 zd-num">{{topDatas['index_5']}}</div>
                        <div class="c-f12">健康指导推送量</div>
                    <div class="ui-col-0 c-t-center c-17b3ec plr15 c-w-33">
                        <!-- <div class="c-f20 zd-num">{{topDatas['index_5']}}</div>
                        <div class="c-f12">健康指导推送量</div> -->
                        <div class="c-f14 health-title" style="padding-bottom: 10px;">健康指导</div>
                        <div class="flex-box" style="margin-top: 47px;">
                            <div style="position: relative;">
                                <div class="c-f16 black">{{topDatas['index_5']}}</div>
                                <div class="visible-xs-inline-block c-f12 health-count black" style="margin-top: 5px;">触达人数</div><img @mouseenter="jumpTip(3)" @mouseleave="leaveTip(3)"class="tip"width="12" src="../../../images/icon_wenhao.png" alt="">
                                <div class="shadow" id="shadow3">以微信绑定账号+家庭成员为统计口径</div>
                            </div>
                            <div style="position: relative;">
                                <div class="c-f16 black">{{topDatas['index_106']}}</div>
                                <div class="visible-xs-inline-block c-f12 health-count black" style="margin-bottom: 33px;margin-top: 5px;">推送人数</div><img @mouseenter="jumpTip(4)" @mouseleave="leaveTip(4)"class="tip"width="12" src="../../../images/icon_wenhao.png" alt="">
                                <div class="shadow shadowr" id="shadow4">以微信绑定账号为统计口径</div>
                            </div>
                        </div>
                    </div>
                    
                </div>
            </div>
            <!-- 微信绑定统计 -->

+ 12 - 3
app/statistics/js/comprehensive-analysis.js

@ -27,6 +27,8 @@ new Vue({
            index_4: 0,
            index_5: 0,
            index_83: 0,
            index_103:0,
            index_106:0,
            index_20: 0,
            index_21: 0,
            index_27: 0
@ -61,6 +63,13 @@ new Vue({
            this.selectedDateType = arg.dateType;
            loadData([1], this);
        },
        jumpTip:function(tab){
            $('#shadow'+tab).attr("style","visibility:visible")
        },
        leaveTip:function(tab){
            $('#shadow'+tab).attr("style","visibility:hidden")
        },
        getAreaData: function(arg){
            //如果level改变,则需要重新加载整个页面的数据,否则只需加载底部区域数据
            if(arg.level == this.level){
@ -267,7 +276,7 @@ function initReqParams(vm){
function getTopReqParams(index1, vm){
    var url = "statistics/total",
        data = {
            index: index1 == '5' ? '5,83' : index1,
            index: index1 == '5' ? '5,83,103,106' : index1,
            level: vm.level, 
            area: vm.area, 
            year: vm.chooseYear,
@ -388,7 +397,7 @@ function handleSecondPanelData(data, vm){
        yDatas = [],
        names = [],
        colors = ['#12b7f5', '#cd67fd'],
        labels = {'3': '咨询量新增趋势', '4': '随访量新增趋势', '5': '推送量新增趋势', '20': '绑定设备新增趋势', '21': '绑定微信新增趋势', '27': '代预约量新增趋势'}
        labels = {'3': '咨询量新增趋势', '4': '随访量新增趋势', '5': '触达人数新增趋势', '20': '绑定设备新增趋势', '21': '绑定微信新增趋势', '27': '代预约量新增趋势'}
        index_names = {'index_3': '咨询量', 'index_4': '随访量', 'index_5': '健康指导','index_27':'代预约量','index_21': '绑定微信','index_20': '绑定设备', 'index_83': "健康文章"};
    for(var p in data){
        names.push(index_names[p]);
@ -459,7 +468,7 @@ function listHandle(data, vm){
        var headers = {
            '3': ["排名", "咨询量", "未回复"],
            '4': ["排名", "随访量"],
            '5': ["排名", "总推送量", "阅读量", "阅读率"],
            '5': ["排名", "总触达人数", "阅读量", "阅读率"],
            '20': ["排名", "绑定设备"],
            '21': ["排名", "绑定率", "已缴费", "未缴费"],
            "27": ["排名", "代预约量"]

BIN
images/icon_wenhao.png