Remove debug messages. Add TODO task for front-end. #744
This commit is contained in:
parent
e9f18ed184
commit
fa514ef26c
2 changed files with 4 additions and 8 deletions
|
|
@ -268,8 +268,6 @@ class InvoiceManager
|
|||
}
|
||||
|
||||
$promo = null;
|
||||
error_log('mogol compute items ' . count($items));
|
||||
|
||||
foreach ($items as $item)
|
||||
{
|
||||
$title = $item['title'];
|
||||
|
|
@ -293,8 +291,6 @@ class InvoiceManager
|
|||
];
|
||||
}
|
||||
|
||||
error_log('mogol compute invoice items ' . count($invoice_items));
|
||||
|
||||
// also need to return the total and the promo
|
||||
$data[] = [
|
||||
'promo' => $promo,
|
||||
|
|
@ -393,8 +389,6 @@ class InvoiceManager
|
|||
if (isset($data['promo']))
|
||||
$promo = $data['promo'];
|
||||
|
||||
error_log('mogol ' . count($invoice_items));
|
||||
|
||||
foreach ($invoice_items as $item)
|
||||
{
|
||||
$invoice_item = new InvoiceItem();
|
||||
|
|
@ -416,8 +410,6 @@ class InvoiceManager
|
|||
->setDiscount($total['discount'])
|
||||
->setTradeIn($total['ti_rate'])
|
||||
->setStatus(InvoiceStatus::DRAFT);
|
||||
|
||||
error_log('mogol total ' . $invoice->getTotalPrice());
|
||||
}
|
||||
|
||||
return $invoice;
|
||||
|
|
|
|||
|
|
@ -1714,6 +1714,8 @@ $(function() {
|
|||
}
|
||||
|
||||
// add to invoice array
|
||||
// TODO: need to figure out how to push battery and tradein separately
|
||||
// right now, battery and trade in is one entry. Need to separate that into two entries
|
||||
invoiceItems.push({
|
||||
battery: battery,
|
||||
quantity: qty,
|
||||
|
|
@ -1752,6 +1754,8 @@ $(function() {
|
|||
var stype = $("#service_type").val();
|
||||
var cvid = $("#customer-vehicle").val();
|
||||
|
||||
console.log(JSON.stringify(invoiceItems));
|
||||
|
||||
// generate invoice values
|
||||
$.ajax({
|
||||
method: "POST",
|
||||
|
|
|
|||
Loading…
Reference in a new issue