<link rel="stylesheet" href="<?php echo base_url();?>public/js/vendor/bootstrap-datepicker/css/bootstrap-datepicker.standalone.min.css">
<script src="<?php echo base_url();?>public/js/vendor/bootstrap-datepicker/js/bootstrap-datepicker.min.js"></script>
<script src="<?php echo base_url();?>public/js/vendor/bootstrap-datepicker/locales/bootstrap-datepicker.zh-CN.min.js"></script>
<div class="content_wrapper">
    <div class="container-fluid">
        
        <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/cardSourceSta">
                                        <span class="gap"></span>
                                        
                                        <div class="form-group">
                                            <label>查询玩家:</label>
                                            
                                            <input type="text" class="form-control" value="<?php if($uid) echo $uid;?>" placeholder="uid" name="uid" />
                                        </div>
                                        <span class="gap"></span>
                                        <button type="submit" class="btn btn-primary">查询</button>
                                        <span class="gap"></span>
                                        <a href="#statistics/cardSourceSta/1" class="btn btn-primary">全部</a>
                                    </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 class="col-sm-12">
                                    <div class="table-responsive">
                                        <table id="example" class="table table-striped table-bordered table-hover" cellspacing="0" width="100%">
                                            <thead>
                                            <tr>
                                                <th>卡片名称</th>
                                                <th>获得时间</th>
                                                <th>来源</th>
                                            </tr>
                                            </thead>
                                            <tbody>
                                            <?php foreach($data as $k => $v){ ?>
                                            <tr>
                                                <td><?php echo $v['cardName']; ?></td>
                                                <td><?php echo $v['time']; ?></td>
                                                <td><?php echo $type[$v['from']]; ?></td>
                                            </tr>
                                            <?php } ?>
                                            </tbody>
                                        </table>
                                    </div>
                                    
                                </div>
                            </div>
                        </div>

                           
                        
                    </section>
                </aside>
            </div>
        </div>
    </div>

</div>

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