<?php /* Smarty version 2.6.2, created on 2012-10-22 08:35:59
         compiled from listrcb.tpl */ ?>
<?php require_once(SMARTY_DIR . 'core' . DIRECTORY_SEPARATOR . 'core.load_plugins.php');
smarty_core_load_plugins(array('plugins' => array(array('modifier', 'encurl', 'listrcb.tpl', 4, false),array('modifier', 'intval', 'listrcb.tpl', 19, false),array('modifier', 'number_format', 'listrcb.tpl', 27, false),array('function', 'cycle', 'listrcb.tpl', 52, false),array('function', 'paginator', 'listrcb.tpl', 68, false),)), $this); ?>
<?php $_smarty_tpl_vars = $this->_tpl_vars;
$this->_smarty_include(array('smarty_include_tpl_file' => "header.tpl", 'smarty_include_vars' => array()));
$this->_tpl_vars = $_smarty_tpl_vars;
unset($_smarty_tpl_vars);
 ?>

<script type="text/javascript">
url = '<?php echo ((is_array($_tmp="?a=listrcb&p=")) ? $this->_run_mod_handler('encurl', true, $_tmp) : smarty_modifier_encurl($_tmp)); ?>
';
<?php echo '
function go(p) {
  document.location = url+p+\'/\';
}
'; ?>

</script>


<h3>RCB Requests</h3>

<div class="details">
<table class="form">
<tr>
 <th>Active Requests</th>
 <td><?php echo ((is_array($_tmp=$this->_tpl_vars['totals']['active'])) ? $this->_run_mod_handler('intval', true, $_tmp) : intval($_tmp)); ?>
</td>
</tr>
<tr>
 <th>Processed Requests</th>
 <td><?php echo ((is_array($_tmp=$this->_tpl_vars['totals']['processed'])) ? $this->_run_mod_handler('intval', true, $_tmp) : intval($_tmp)); ?>
</td>
</tr>
<tr>
 <th>RCB Received</th>
 <td>$<?php echo ((is_array($_tmp=$this->_tpl_vars['totals']['received'])) ? $this->_run_mod_handler('number_format', true, $_tmp, 2) : number_format($_tmp, 2)); ?>
</td>
</tr>
<tr>
 <th>RCB Pending</th>
 <td>$<?php echo ((is_array($_tmp=$this->_tpl_vars['totals']['pending'])) ? $this->_run_mod_handler('number_format', true, $_tmp, 2) : number_format($_tmp, 2)); ?>
</td>
</tr>
</table>
<br>

<?php if ($this->_tpl_vars['refbacks']): ?>
<table class="list">
<?php if (isset($this->_sections['s'])) unset($this->_sections['s']);
$this->_sections['s']['name'] = 's';
$this->_sections['s']['loop'] = is_array($_loop=$this->_tpl_vars['refbacks']) ? count($_loop) : max(0, (int)$_loop); unset($_loop);
$this->_sections['s']['show'] = true;
$this->_sections['s']['max'] = $this->_sections['s']['loop'];
$this->_sections['s']['step'] = 1;
$this->_sections['s']['start'] = $this->_sections['s']['step'] > 0 ? 0 : $this->_sections['s']['loop']-1;
if ($this->_sections['s']['show']) {
    $this->_sections['s']['total'] = $this->_sections['s']['loop'];
    if ($this->_sections['s']['total'] == 0)
        $this->_sections['s']['show'] = false;
} else
    $this->_sections['s']['total'] = 0;
if ($this->_sections['s']['show']):

            for ($this->_sections['s']['index'] = $this->_sections['s']['start'], $this->_sections['s']['iteration'] = 1;
                 $this->_sections['s']['iteration'] <= $this->_sections['s']['total'];
                 $this->_sections['s']['index'] += $this->_sections['s']['step'], $this->_sections['s']['iteration']++):
$this->_sections['s']['rownum'] = $this->_sections['s']['iteration'];
$this->_sections['s']['index_prev'] = $this->_sections['s']['index'] - $this->_sections['s']['step'];
$this->_sections['s']['index_next'] = $this->_sections['s']['index'] + $this->_sections['s']['step'];
$this->_sections['s']['first']      = ($this->_sections['s']['iteration'] == 1);
$this->_sections['s']['last']       = ($this->_sections['s']['iteration'] == $this->_sections['s']['total']);
 if ($this->_tpl_vars['refbacks'][$this->_sections['s']['index']]['type'] == 'date'): ?>
<tr>
 <td class="title" colspan=6><?php echo $this->_tpl_vars['refbacks'][$this->_sections['s']['index']]['date']; ?>
</td>
</tr>
<tr>
 <th>Status</th>
 <th>Time</th>
 <th>Program</th>
 <th>Deposit/RCB</th>
 <th>Username</th>
 <th>EC No</th>
</tr>
<?php else: ?>
<tr class="<?php echo smarty_function_cycle(array('values' => "row1,row2"), $this);?>
">
  <td><?php if ($this->_tpl_vars['refbacks'][$this->_sections['s']['index']]['status'] == 1): ?><b class="profit">Paid</b><?php else: ?><b class="spend">Pending</b><?php endif; ?></td>
  <td><?php echo $this->_tpl_vars['refbacks'][$this->_sections['s']['index']]['time_added']; ?>
</td>
  <td><a href="<?php echo ((is_array($_tmp="?a=details&lid=".($this->_tpl_vars['refbacks'][$this->_sections['s']['index']]['listing_id']))) ? $this->_run_mod_handler('encurl', true, $_tmp) : smarty_modifier_encurl($_tmp)); ?>
" target="_blank"><?php echo $this->_tpl_vars['refbacks'][$this->_sections['s']['index']]['program_name']; ?>
</a></td>
  <td>$<?php echo $this->_tpl_vars['refbacks'][$this->_sections['s']['index']]['inv_amount'];  if ($this->_tpl_vars['refbacks'][$this->_sections['s']['index']]['rcb_amount']): ?> / $<?php echo $this->_tpl_vars['refbacks'][$this->_sections['s']['index']]['rcb_amount'];  endif; ?></td>
  <td><?php echo $this->_tpl_vars['refbacks'][$this->_sections['s']['index']]['username']; ?>
</td>
  <td><img src="<?php echo ((is_array($_tmp=($this->_tpl_vars['theme'])."images/".($this->_tpl_vars['refbacks'][$this->_sections['s']['index']]['paysystem']).".gif")) ? $this->_run_mod_handler('encurl', true, $_tmp) : smarty_modifier_encurl($_tmp)); ?>
" alt="<?php echo $this->_tpl_vars['refbacks'][$this->_sections['s']['index']]['paysystem']; ?>
"> <?php echo $this->_tpl_vars['refbacks'][$this->_sections['s']['index']]['psaccount']; ?>
</td>
</tr>
<?php endif;  endfor; endif; ?>
</table>
<?php else: ?>
 <div class="message">No Refback Requests</div>
<?php endif; ?>
</div>

<?php echo smarty_function_paginator(array('col' => $this->_tpl_vars['pages']['col'],'cur' => $this->_tpl_vars['pages']['cur'],'url' => "javascript:go('%s')"), $this);?>


<?php $_smarty_tpl_vars = $this->_tpl_vars;
$this->_smarty_include(array('smarty_include_tpl_file' => "footer.tpl", 'smarty_include_vars' => array()));
$this->_tpl_vars = $_smarty_tpl_vars;
unset($_smarty_tpl_vars);
 ?>