<div class="content_wrapper">
    <div class="container-fluid">
        <aside>
            <header><i class="fa fa-fw fa-file"></i>版本分布</header>
            <section>
                <div class="container-fluid">
                    <div class="row">
                        <div class="col-sm-12">
                            <a style="margin:5px;" class="btn btn-primary active" href="#statistics/versionDistributed" role="button">总用户版本分布</a>
                            <a style="margin:5px;" class="btn btn-primary " href="#statistics/versionDistributed/1" role="button">今日登陆分布</a>
                            <a style="margin:5px;" class="btn btn-primary " href="#statistics/versionDistributed/2" role="button">版本曲线</a>
                        </div>
                    </div>
                </div>
            </section>
        </aside>
        <div class="row">
            <div class="col-sm-12">
                <aside>
                    <header><i class="fa fa-fw fa-file"></i>查询</header>
                    <section>
                        <div class="container-fluid">
                            <div class="row">
                                <div class="col-sm-12">
                                    <form class="form-inline" role="form" method="POST" action="#statistics/versionDistributed" name="stanpform">
                                        <input type="hidden" name="fromsta_np" value="1">
                                        <span class="gap"></span>
                                        <div class="form-group">
                                                <label>开始时间</label>
                                                <input type="text" class="form-control datetimepicker" value="<?php if($stime) echo $stime;?>" placeholder="开始时间" name="sta_np_stime" />
                                        </div>
                                        <span class="gap"></span>
                                        <div class="form-group">
                                                <label>结束时间</label>
                                                <input type="text" class="form-control datetimepicker" value="<?php if($etime) echo $etime;?>" placeholder="结束时间" name="sta_np_etime" />
                                        </div>
                                        <button type="submit" class="btn btn-primary">查询</button>
                                    </form>
                                </div>
                            </div>
                        </div>
                    </section>
                </aside>
            </div>
        </div>
        <div class="row">
            <div class="col-sm-12">
                <aside>
                    <header><i class="fa fa-fw fa-file"></i>安卓分布</header>
                    <section>
                        <div class="container-fluid">
                            <div class="row">
                                <div id="Android" style="min-width: 310px; height: 500px; margin: 0 auto"></div>
                            </div>
                        </div>
                    </section>
                </aside>
            </div>
            <div class="col-sm-12">
                <aside>
                    <header><i class="fa fa-fw fa-file"></i>IOS分布</header>
                    <section>
                        <div class="container-fluid">
                            <div class="row">
                                <div id="IOS" style="min-width: 310px; height: 500px; margin: 0 auto"></div>
                            </div>
                        </div>
                    </section>
                </aside>
            </div>
        </div>
    </div>
</div>
</div>
<script type="text/javascript" src="<?php echo base_url();?>public/js/highcharts/highcharts.js"></script>
<script type="text/javascript" src="<?php echo base_url();?>public/js/highcharts/modules/exporting.js"></script>
<script type="text/javascript">
Highcharts.chart('Android', {
    chart: {
        type: 'column'
    },
    title: {
        text: '安卓分布'
    },
    subtitle: {
        text: ''
    },
    xAxis: {
        categories: [<?php echo "'".implode("','", $name['Android'])."'";?>]
    },
    yAxis: {
        title: {
            text: '版本'
        }
    },
    plotOptions: {
        line: {
            dataLabels: {
                enabled: true
            },
            enableMouseTracking: false
        }
    },
    series: [{
        name: 'Android',
        data: [<?php echo implode(",",$value['Android']);?>]
    }]
});

Highcharts.chart('IOS', {
    chart: {
        type: 'column'
    },
    title: {
        text: 'IOS分布'
    },
    subtitle: {
        text: ''
    },
    xAxis: {
        categories: [<?php echo "'".implode("','", $name['IOS'])."'";?>]
    },
    yAxis: {
        title: {
            text: '版本'
        }
    },
    plotOptions: {
        line: {
            dataLabels: {
                enabled: true
            },
            enableMouseTracking: false
        }
    },
    series: [{
        name: 'IOS',
        data: [<?php echo implode(",",$value['IOS']);?>]
    }]
});

//选择日期
$('.datetimepicker').datepicker({
    language:'zh-CN',
    format:'yyyy-mm-dd',
    zIndexOffset:906  //控制z-index
});

</script>