<?php echo mymps_admin_tpl_global_head();
$admindir = getcwdOL();
?>
<script type='text/javascript' src='js/calendar.js'></script>
<div id="<?=MPS_SOFTNAME?>">
<table border="0" cellspacing="0" cellpadding="0" class="vbm">
  <tr class="firstr">
  	<td colspan="2">详细搜索</td>
  </tr>
  <tr bgcolor="#ffffff">
    <td id="menu_tip">
    	<form action="payrecord.php" method="get">
        <input name="url" value="<?php echo GetUrl();?>" type="hidden" />
		时间从<input name="starttime" type="text" class="txt" style="width:70px;" onclick="popUpCalendar(this, this, &quot;yyyy-mm-dd&quot;)" value="<?php echo $starttime; ?>"> - <input name="endtime" class="txt" type="text" style="width:70px;" onclick="popUpCalendar(this, this, &quot;yyyy-mm-dd&quot;)" value="<?php echo $endtime; ?>"> 
		关键字 <input name="keywords" type="text" class="text" value="<?php echo $keywords; ?>">    
        <select name="action" id="action">
            <option value="1" <?php if($action == '1') echo 'selected'; ?>>订单号</option>
            <option value="2" <?php if($action == '2') echo 'selected'; ?>>汇款者</option>
            <option value="3" <?php if($action == '3') echo 'selected'; ?>>汇款IP</option>
			<option value="4" <?php if($action == '4') echo 'selected'; ?>>备注</option>
          </select> 
		<input type="submit" value="搜索" class="gray mini">
         </form>
    </td>
  </tr>
</table>
</div>
<div class="clear"></div>
<div id="<?=MPS_SOFTNAME?>" style="padding-bottom:0">
    <div class="mpstopic-category">
        <div class="panel-tab">
            <ul class="clearfix tab-list">
            	<li><a href="?status=1" <?php if($status == 1){?>class="current"<?php }?>>全部订单</a></li>
                <li><a href="?status=2" <?php if($status == 2){?>class="current"<?php }?>>已完成</a></li>
                <li><a href="?status=3" <?php if($status == 3){?>class="current"<?php }?>>未完成</a></li>
            </ul>
        </div>
    </div>
</div>
<form action="?part=list" method="post">
<input name="url" type="hidden" value="<?=GetUrl()?>">
<div id="<?=MPS_SOFTNAME?>">
<table border="0" cellspacing="0" cellpadding="0" class="vbm">
    <tr style="font-weight:bold; background-color:#dff6ff">
    <td><input class="checkbox" name="checkall" type="checkbox" id="checkall" onClick="CheckAll(this.form)"/> 删?</td>
      <td>订单号</td>
      <td>汇款者</td>
      <td>金额</td>
      <td>汇款时间</td>
      <td>汇款IP</td>
      <td>备注</td>
      <td>接口</td>
    </tr>
    <?php
	$fee = array();
	foreach($list as $list){
	if($list['paybz'] == '支付完成' || $list['paybz'] == '支付成功')$fee[$list[id]]=$list[money];
	?>
    <tr bgcolor="white">
        <td><input type='checkbox' name='delids[]' value='<?=$list[id]?>' class='checkbox' id="<?=$list[id]?>"></td>
        <td><?=$list[orderid]?></td>
        <td><a href="javascript:void(0);" onclick="setbg('<?=MPS_SOFTNAME?>会员中心',400,110,'../box.php?part=member&userid=<?=$list[userid]?>&admindir=<?=$admindir?>')"><?=$list[userid]?></a></td>
        <td><em><font color="red"><?php echo (int)($list[money]/$mymps_global['cfg_coin_fee']); ?>元</font></em></td>
        <td><?=GetTime($list[posttime])?></td>
        <td align="left"><?=$list[payip]?></td>
        <td align="left"><?=$list[paybz]?></td>
        <td align="left"><?=$list[type]?></td>
    </tr>
    <?php }?>

</table>
</div>
<center><input type="submit" value="提 交" class="mymps large" name="<?php echo CURSCRIPT; ?>_submit"/><div class="clear"></div><div style="color:#888;">合计 <font color="red"><?php echo (int)(array_sum($fee)/$mymps_global['cfg_coin_fee']);?></font> <?php echo $moneytype; ?> </div></center>
</form>
<div class="pagination"><?=page2()?></div>
<?php mymps_admin_tpl_global_foot();?>