Merge inclusive tax fix

This commit is contained in:
Hillel Coren 2017-03-24 14:58:23 +03:00
parent b8c0375b3e
commit 4ce76ef138

View File

@ -289,10 +289,11 @@ class InvoiceController extends BaseController
$taxRateOptions = $account->present()->taxRateOptions; $taxRateOptions = $account->present()->taxRateOptions;
if ($invoice->exists) { if ($invoice->exists) {
foreach ($invoice->getTaxes() as $key => $rate) { foreach ($invoice->getTaxes() as $key => $rate) {
$key = '0 ' . $key;
if (isset($taxRateOptions[$key])) { if (isset($taxRateOptions[$key])) {
continue; continue;
} }
$taxRateOptions['0 ' . $key] = $rate['name'] . ' ' . $rate['rate'] . '%'; $taxRateOptions[$key] = $rate['name'] . ' ' . $rate['rate'] . '%';
} }
} }