2013-03-28 23:58:00 -07:00
|
|
|
<?
|
|
|
|
|
|
2013-03-29 00:20:00 -07:00
|
|
|
App::import('Vendor','pagecounter');
|
|
|
|
|
$pagecounter = new PageCounter();
|
2013-03-28 23:58:00 -07:00
|
|
|
?>
|
|
|
|
|
|
2011-06-15 01:26:22 -07:00
|
|
|
<p>Dear <?=$enquiry['Contact']['first_name']?>,</p>
|
|
|
|
|
|
|
|
|
|
<p>Thank you for your enquiry. The following quotation is for:</p>
|
|
|
|
|
<table>
|
2013-03-29 00:20:00 -07:00
|
|
|
<tr>
|
2011-06-15 01:26:22 -07:00
|
|
|
<td width="10%"><u><b>Item</b></u></td>
|
|
|
|
|
<td width="80%"><u><b>Description</b></u></td>
|
|
|
|
|
<td width="10%"><u><b>Quantity</b></u></td>
|
2013-03-29 00:20:00 -07:00
|
|
|
</tr>
|
|
|
|
|
<? foreach($document['LineItem'] as $li):?>
|
|
|
|
|
<tr>
|
2011-06-15 01:26:22 -07:00
|
|
|
<td valign="top" width="10%"><? if($li['option'] == 1) {
|
2013-03-29 00:20:00 -07:00
|
|
|
echo 'Option<br>';
|
|
|
|
|
}
|
|
|
|
|
?><?=$li['item_number']?></td>
|
2011-06-15 01:26:22 -07:00
|
|
|
<td width="80%"><?=$li['title'];?></td>
|
2011-06-19 18:20:44 -07:00
|
|
|
<td valign="top" width="10%"><?=$decimal->formatDecimal($li['quantity']);?></td>
|
2013-03-29 00:20:00 -07:00
|
|
|
</tr>
|
|
|
|
|
<? endforeach;?>
|
2011-06-15 01:26:22 -07:00
|
|
|
</table>
|
2013-03-29 00:20:00 -07:00
|
|
|
<p></p>
|
|
|
|
|
<p>If you have any further queries, please contact us at our office for assistance.</p>
|
|
|
|
|
<p>We look forward to your reply.</p>
|
2011-06-15 01:26:22 -07:00
|
|
|
|
2013-03-29 00:20:00 -07:00
|
|
|
<p>Regards,</p>
|
|
|
|
|
<?=$enquiry['User']['first_name'].' '.$enquiry['User']['last_name'];?><br />
|
|
|
|
|
<?=$enquiry['User']['job_title'];?><br />
|
|
|
|
|
<br />
|
|
|
|
|
<u><b>Attachments:</b></u><br />
|
|
|
|
|
CMC Technologies Terms & Conditions of Sale 1/7/06 (attached)<br>
|
|
|
|
|
<?php foreach($attachments as $attachment) { ?>
|
|
|
|
|
<?php
|
|
|
|
|
|
|
|
|
|
$pagecount = '';
|
|
|
|
|
|
|
|
|
|
if($attachment['Attachment']['type'] == 'application/pdf') {
|
2013-03-29 00:44:34 -07:00
|
|
|
$pagecount = '('.$pagecounter->count($attachment['Attachment']['file']).' pages)';
|
2013-03-29 00:20:00 -07:00
|
|
|
}
|
|
|
|
|
?>
|
|
|
|
|
<?= $attachment['Attachment']['name']; ?> <?= $pagecount ?><br>
|
|
|
|
|
<?php
|
|
|
|
|
} ?>
|