mirror of
https://gitlab.com/CIEFWorldwideSdnBhd/exchange-2.0.git
synced 2026-09-01 10:54:00 +00:00
E-Invoice - Update the conditions for generating Sales Invoice Report with business logic update on generating invoice
This commit is contained in:
@@ -67,7 +67,12 @@ class ApprovePurchaseOrderLogic extends AbstractControllerLogic
|
||||
|
||||
$this->updatesTransactionStatus->execute($purchaseOrder, ApprovalStatus::APPROVED);
|
||||
|
||||
$this->createInvoiceTransactionProcessor->execute($booking);
|
||||
$this->createInvoiceTransactionProcessor->execute($booking, "", null, [
|
||||
'generateEInvoice' => false,
|
||||
'generateEInvoiceWithNormalInvoiceTemplate' => false,
|
||||
'generateEInvoiceRefund' => false,
|
||||
'bookingOriginalStatus' => $booking->status
|
||||
]);
|
||||
|
||||
return $this->response([]);
|
||||
}
|
||||
|
||||
@@ -98,6 +98,7 @@ class BookingResource extends JsonResource
|
||||
})->latest()->get())
|
||||
]),
|
||||
'einvoice' => $eInvoice,
|
||||
'is_invoice_generated' => $this->is_invoice_generated,
|
||||
];
|
||||
}
|
||||
}
|
||||
|
||||
+2
-2
@@ -6,7 +6,7 @@
|
||||
<div class="col-md col-sm-12 m-b-20">
|
||||
<div class="row" v-if="booking">
|
||||
<div class="col" v-if="showDownloadPDFButtons">
|
||||
<div class="row m-b-50" v-if="booking.status === 3 || isBookingWithAFullRefund">
|
||||
<div class="row m-b-50" v-if="(booking.status === 3 || booking.is_invoice_generated) || isBookingWithAFullRefund">
|
||||
<div class="col no-padding">
|
||||
<div class="row">
|
||||
<div class="col">
|
||||
@@ -122,7 +122,7 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row m-b-10" v-if="booking.status !== 3 && !isBookingWithAFullRefund">
|
||||
<div class="row m-b-10" v-if="booking.status !== 3 && !booking.is_invoice_generated && !isBookingWithAFullRefund">
|
||||
<div class="col">
|
||||
<div class="row text-center m-b-15">
|
||||
<div class="col">
|
||||
|
||||
Reference in New Issue
Block a user