Add attachment size
This commit is contained in:
parent
925ef2133c
commit
c6d1c7bf36
|
|
@ -4,9 +4,13 @@
|
|||
<th>Filename</th>
|
||||
<th>Name</th>
|
||||
<th>Desc</th>
|
||||
<th>Size</th>
|
||||
</thead>
|
||||
<tbody>
|
||||
<?php
|
||||
<?php
|
||||
|
||||
$totalSize = 0;
|
||||
|
||||
foreach($attachments as $index => $attachment) {
|
||||
?>
|
||||
<tr>
|
||||
|
|
@ -16,8 +20,19 @@ foreach($attachments as $index => $attachment) {
|
|||
</td>
|
||||
<td><?php echo $attachment['Attachment']['name']; ?></td>
|
||||
<td><?php echo $attachment['Attachment']['description']; ?></td>
|
||||
<td><?php echo $number->toReadableSize($attachment['Attachment']['size']); ?></td>
|
||||
<?php $totalSize += $attachment['Attachment']['size']; ?>
|
||||
</tr>
|
||||
|
||||
<?php } ?>
|
||||
|
||||
<tr class="attachment-total">
|
||||
<td></td>
|
||||
<td></td>
|
||||
<td></td>
|
||||
<td>Total size:</td>
|
||||
<td><?php echo $number->toReadableSize($totalSize); ?></td>
|
||||
</tr>
|
||||
|
||||
</tbody>
|
||||
</table>
|
||||
|
|
|
|||
|
|
@ -8,12 +8,7 @@ echo $javascript->link('document_attachments');
|
|||
?>
|
||||
<?=$this->element('pdf_created_message'); ?>
|
||||
|
||||
<?php if(!empty($smtp_errors)) { ?>
|
||||
<h2>Email error</h2>
|
||||
<pre>
|
||||
<?php print_r($smtp_errors); ?>
|
||||
</pre>
|
||||
<?php } ?>
|
||||
|
||||
<?
|
||||
echo $this->element($docTypeElement);
|
||||
?>
|
||||
|
|
@ -75,11 +70,11 @@ foreach($attachments as $index => $attachment) {
|
|||
<?php }
|
||||
?>
|
||||
|
||||
<tr>
|
||||
<td></td>
|
||||
<tr class="attachment-total">
|
||||
<td></td>
|
||||
<td></td>
|
||||
<td></td>
|
||||
<td>Total size:</td>
|
||||
<td><?php echo $number->toReadableSize($totalSize); ?></td>
|
||||
</tr>
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue