cmc-sales/views/elements/quote_table.ctp
Karl Cordes a02a8e8985 WOOOOT
2011-05-24 20:15:21 +10:00

46 lines
1.3 KiB
PHP
Executable file

<?php if (!empty($quotes)):?>
<table cellpadding = "0" cellspacing = "0" class="quotetable">
<tr>
<th><?php __('Revision'); ?></th>
<th><?php __('Sale Currency'); ?></th>
<th><?php __('Date / Time Created'); ?></th>
<th class="actions"><?php __('Actions');?></th>
</tr>
<?php
$i = 0;
foreach ($quotes as $quote):
$class = null;
if ($i % 2 == 0) {
$class = ' class="altrow"';
}
if($i == 0) {
$class = ' class="mostrecent"';
}
$i++;
?>
<tr<?php echo $class;?>>
<td><?php echo $quote['Quote']['revision'];?></td>
<td><?php echo $quote['Currency']['iso4217'];?></td>
<td><?php echo $time->nice($quote['Quote']['created']);?></td>
<td class="actions">
<?php echo $html->link(__('View', true), array('controller'=> 'documents', 'action'=>'view', $quote['Quote']['document_id'])); ?>
<?php //echo $html->link(__('Revise', true), array('controller'=>'quotes', 'action'=>'revise', $quote['Quote']['id']));
?>
</td>
</tr>
<?php endforeach; ?>
</table>
<?php endif; ?>
<div class="actions">
<ul>
<li><?php echo $html->link(__('New Quote', true), array('controller'=> 'documents', 'action'=>'newQuote',$enquiry['Enquiry']['id']));?> </li>
</ul>
</div>