 <?php  include("../template/usertop.php");?>
<body style="padding:0px;">
<?php  include("../template/menu.php");?> 
<div class="main_top_1">
<div class="mt" style="position:relative;">
<?php  include("../template/user_left.php");?> 
<div class="user_zx_right">
<div class="box">
<div class="tagMenu">
<ul class="menu">
<li><a href="/mobile/user/promotion_links.php">推广链接</a></li>
<li><a href="/mobile/user/promotion_record.php">推广记录</a></li>
<li class="current"><a href="/user/offline_record.php">下线分成</a></li>
</ul>
<div class="hite"> <span id="account"></span> </div>
</div>
</div>
<?php
	$username  = $userConfig['username'];
	$sql_ok = "select sum(amount) as ok from  {$db_prefix}member_cashback where username =  '{$username}' and status = 1";
	$rsok = $db->get_one($sql_ok);		//充值抽成成功
?>
<div class="myinfo" style="padding: 20px; margin-bottom: 15px;background:#fff;">
<p style="margin:15px 0px;">尊敬的<?php echo configW('webname'); ?>会员，以下是您在<?php echo configW('webname'); ?>的推广分成记录，敬请审阅！</p>
<p>截止 <?php echo toData(time()); ?>  您的下线投资抽成成功： <span style="color:#2a5fa3; font-size:14px;">￥<?php echo $rsok['ok']?$rsok['ok']:0; ?></span>。</p>


<div class="container-fluid">
    <div class="row-fluid">
        <table class="table table-striped table-bordered table-hover datatable">
            <thead>
                <tr>
                    <th>分成时间</th>
                    <th>下线会员账号</th>
                    <th>投资金额</th>
                    <th>抽成金额</th>
                    <!-- <th>类型</th> -->
                    <th>状态</th>
                </tr>
            </thead>
            <tbody>

				<?php
					$username = $_SESSION["glo_username"];
					$sql="select * from {$db_prefix}member_cashback where username = '{$username}'";
					$rs = $db->query($sql);
					if(mysql_num_rows($rs) <1 ){  ?>
						<tr>
							<td width="90%" colspan="5">暂无记录</td>
						</tr>
				<?php }else{ 
					while ($rs2=$db->fetch_array($rs)){  ?>
                <tr class="odd gradeX">
                    <td><?php echo toData($rs2['posttime']); ?></td>
                    <td><?php echo $rs2['xxusername']; ?></td>
                    <td><?php echo $rs2['amount']; ?></td>
                    <td><?php echo $rs2['preamount']; ?></td>
                    <!-- <td><?php echo $rs2['type']; ?></td> -->
                    <td><?php echo $rs2['status']?'成功':'失败'; ?></td>
                </tr>
                <?php  }}  ?>
            </tbody>
        </table>
    </div>
</div>

</div>
</div>
</div>
</div>
 <?php  include("../template/foot.php");?> 
 <?php  include("../template/page.php");?> 
 </body></html>