查看/发票/ View.ctp
<?php
if ( $payments == NULL ) {
echo '<tr><td> -- No Payments Are Associated With This Invoice -- </td>
<td></td>
<td></td></tr>';
}
?>
<? foreach ($payments as $payment): ?>
<tr id="payment_row_<?= $payment['id'] ?>">
<td class="responsive_cell"><?php echo $payment['method']?></td>
<td class="date_cell responsive_cell"><?php echo $payment['date']?></td>
<td class="right responsive_cell"><?php echo number_format($payment['amount'], 2, '.', ',')?></td>
</tr>
<?php $paymentsTotal += $payment['amount'] ?>
<? endforeach; ?>
查看/发票/ email.ctp
$bedrag = $settings['Setting']['currency'].$thisInvoice['Payment'];
EMail.ctp和View.ctp中的这个回声的数组显示了正确的金额。
如何在Email.ctp中获得正确的金额?