<?php /* Smarty version 2.6.2, created on 2012-06-03 14:20:25
         compiled from view_statistics.tpl */ ?>
<br><div class="list_text"><div align="center"><img src="images/t1.gif" align="absMiddle"> <a class="list_menu">Payout Statistics</a>
<hr size=1 noshade="noshade" style="border:1px #cccccc dotted"></div>
<div align=left>
<table cellspacing=1 cellpadding=2 border=0 width=100%>
<tr>
 <td colspan=4>Payout Statistics for <b><?php echo $this->_tpl_vars['listing']['name']; ?>
</b></td>
</tr>
<tr>
 <td colspan=4>Payouts Ratio: <b><?php echo $this->_tpl_vars['ratio']; ?>
 <?php if ($this->_tpl_vars['ratio'] >= 1): ?><font color=red>in profit</font><?php endif; ?></b></td>
</tr>
<tr>
 <td colspan=4>Payouts Found: <b><?php echo $this->_tpl_vars['payouts']; ?>
</b></td>
</tr>
</table></div>

<table cellspacing=1 cellpadding=2 border=0 width=100%>
<tr>
 <th class=title_box>Date</th>
 <th class=title_box>Amount</th>
 <th class=title_box>Comment</th>
</tr>
<?php if ($this->_tpl_vars['stats']):  if (isset($this->_sections['s'])) unset($this->_sections['s']);
$this->_sections['s']['name'] = 's';
$this->_sections['s']['loop'] = is_array($_loop=$this->_tpl_vars['stats']) ? 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']);
?>
<tr bgcolor=<?php if ($this->_sections['s']['rownum'] % 2 != 0): ?>#f2f2f2<?php else: ?>#ffffff<?php endif; ?>>
 <td><?php echo $this->_tpl_vars['stats'][$this->_sections['s']['index']]['fdate']; ?>
</td>
 <td>$<?php echo $this->_tpl_vars['stats'][$this->_sections['s']['index']]['amount']; ?>
</td>
 <td align=center><?php echo $this->_tpl_vars['stats'][$this->_sections['s']['index']]['comment']; ?>
</td>
</tr>
<?php endfor; endif;  else: ?>
<tr>
 <td colspan=4 align=center>No Payouts.</td>
</tr>
<?php endif; ?>
</table>