diff --git a/app/Classes/General/Eloquent/Filters/Receiver.php b/app/Classes/General/Eloquent/Filters/Receiver.php new file mode 100644 index 00000000..a0ecd6eb --- /dev/null +++ b/app/Classes/General/Eloquent/Filters/Receiver.php @@ -0,0 +1,20 @@ +where('receiver', '=', $value); + } + +} diff --git a/app/Classes/Modules/Companies/ControllersLogic/ListCompanyModuleInvoicesLogic.php b/app/Classes/Modules/Companies/ControllersLogic/ListCompanyModuleInvoicesLogic.php new file mode 100644 index 00000000..f8545a4b --- /dev/null +++ b/app/Classes/Modules/Companies/ControllersLogic/ListCompanyModuleInvoicesLogic.php @@ -0,0 +1,66 @@ + 'Retrieved Company Module Invoices', + 'message' => 'You have successfully retrieved a list of Invoices' + ]; + } + + /** @var ListsTransactions */ + private $listsTransactions; + + /** + * ListCompanyModuleInvoicesLogic constructor. + * @param ListsTransactions $listsTransactions + */ + public function __construct(ListsTransactions $listsTransactions) + { + $this->listsTransactions = $listsTransactions; + } + + + /** + * @param Request $request + * @return JsonResponse + * @throws \App\Classes\Exceptions\AccessForbiddenException + * @throws \App\Classes\Exceptions\MalformedRequestException + * @throws \App\Classes\Exceptions\RequestValidationException + */ + public function logic(Request $request): JsonResponse + { + $filterArray = [ + "per_page" => 10, + "order_by" => (object)[ + "column" => 'id', + "DESC" => true, + ], + "status_in" => [2], + "receiver" => intval($request->route('company_module_id')), + "type" => TransactionType::SHIPPING_INVOICE + ]; + + // $this->canListTransactions->passes(); + + $query = $this->listsTransactions->execute($filterArray); + + return $this->collectionResponse(TransactionResource::collection($query)); + } +} diff --git a/app/Http/Controllers/Companies/ListCompanyModuleInvoicesController.php b/app/Http/Controllers/Companies/ListCompanyModuleInvoicesController.php new file mode 100644 index 00000000..86b1f6a8 --- /dev/null +++ b/app/Http/Controllers/Companies/ListCompanyModuleInvoicesController.php @@ -0,0 +1,20 @@ +execute($request); + } + +} \ No newline at end of file diff --git a/resources/assets/vue/components/companies/sections/CustomerPaymentBillingSectionComponent.vue b/resources/assets/vue/components/companies/sections/CustomerPaymentBillingSectionComponent.vue new file mode 100644 index 00000000..b375eafd --- /dev/null +++ b/resources/assets/vue/components/companies/sections/CustomerPaymentBillingSectionComponent.vue @@ -0,0 +1,153 @@ + + diff --git a/resources/assets/vue/components/paymentsBilling/elements/PaymentsBillingComponents.vue b/resources/assets/vue/components/paymentsBilling/elements/PaymentsBillingComponents.vue index 86535a80..590a78ca 100644 --- a/resources/assets/vue/components/paymentsBilling/elements/PaymentsBillingComponents.vue +++ b/resources/assets/vue/components/paymentsBilling/elements/PaymentsBillingComponents.vue @@ -4,110 +4,36 @@
-
+
-
{{item.country.id}}05052021
+
{{ item.bill_no }}
-
Invoice Date Invoice Date
+
{{ item.created_at }}
Status
-
Amount
+
MYR {{ item.amount.toFixed(2) }}
-
- -
-
-
-
-
-
-
-
-
-
- -
-
-
-
Carrier Tracking Number
-
-
-
-
-
#1zbr06tw403742920
-
-
-
-
-
-
-
Due Date
-
-
-
-
-
11.04.2021
-
-
-
-
-
-
-
Outstanding
-
-
-
-
-
RM0.00
-
-
+
+
+ + +
-
-
-
-
-
- -
-
-
-
This package was delivered by
-
-
-
-
-
#1zbr06tw403742920
-
-
-
-
-
-
-
Date Paid
-
-
-
-
-
21.01.2021
-
-
-
-
-
- Invoice Detail -
+
+
@@ -120,10 +46,33 @@