Merge branch '713-tapi-changes' into 'master'
Resolve "TAPI Changes" Closes #713 See merge request jankstudio/resq!828
This commit is contained in:
commit
337b98f655
2 changed files with 7 additions and 7 deletions
|
|
@ -377,11 +377,11 @@ class JobOrderController extends APIController
|
||||||
|
|
||||||
// make invoice json data
|
// make invoice json data
|
||||||
$invoice_data = [
|
$invoice_data = [
|
||||||
'total_price' => $invoice->getTotalPrice(),
|
'total_price' => number_format($invoice->getTotalPrice(), 2, '.', ''),
|
||||||
'vat_ex_price' => (float) $invoice->getVATExclusivePrice(),
|
'vat_ex_price' => number_format($invoice->getVATExclusivePrice(), 2, '.', ''),
|
||||||
'vat' => $invoice->getVAT(),
|
'vat' => number_format($invoice->getVAT(), 2, '.', ''),
|
||||||
'discount' => $invoice->getDiscount(),
|
'discount' => number_format($invoice->getDiscount(), 2, '.', ''),
|
||||||
'trade_in' => $invoice->getTradeIn(),
|
'trade_in' => number_format($invoice->getTradeIn(), 2, '.', ''),
|
||||||
];
|
];
|
||||||
$items = $invoice->getItems();
|
$items = $invoice->getItems();
|
||||||
$items_data = [];
|
$items_data = [];
|
||||||
|
|
@ -390,7 +390,7 @@ class JobOrderController extends APIController
|
||||||
$items_data[] = [
|
$items_data[] = [
|
||||||
'title' => $item->getTitle(),
|
'title' => $item->getTitle(),
|
||||||
'qty' => $item->getQuantity() + 0,
|
'qty' => $item->getQuantity() + 0,
|
||||||
'price' => $item->getPrice() + 0.0,
|
'price' => number_format($item->getPrice() + 0.0, 2, '.', '')
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
$invoice_data['items'] = $items_data;
|
$invoice_data['items'] = $items_data;
|
||||||
|
|
|
||||||
|
|
@ -84,7 +84,7 @@ class ResqInvoiceGenerator implements InvoiceGeneratorInterface
|
||||||
break;
|
break;
|
||||||
case ServiceType::JUMPSTART_WARRANTY:
|
case ServiceType::JUMPSTART_WARRANTY:
|
||||||
$this->processJumpstartWarranty($total, $invoice);
|
$this->processJumpstartWarranty($total, $invoice);
|
||||||
|
break;
|
||||||
case ServiceType::BATTERY_REPLACEMENT_NEW:
|
case ServiceType::BATTERY_REPLACEMENT_NEW:
|
||||||
$this->processEntries($total, $criteria, $invoice);
|
$this->processEntries($total, $criteria, $invoice);
|
||||||
/*
|
/*
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue