diff --git a/app/Classes/Modules/Segments/ControllersLogic/ListAirShipmentPriceLogic.php b/app/Classes/Modules/Segments/ControllersLogic/ListAirShipmentPriceLogic.php new file mode 100644 index 00000000..8a15dc5c --- /dev/null +++ b/app/Classes/Modules/Segments/ControllersLogic/ListAirShipmentPriceLogic.php @@ -0,0 +1,145 @@ + 'Retrieved Air Shipment Price List', + 'message' => 'You have successfully retrieved a list of Air Shipment Price' + ]; + } + + + /** @var ListsSegments */ + private $listsSegments; + + /** + * ListSegmentLogic constructor. + * @param ListsSegments $listsSegments + */ + public function __construct(ListsSegments $listsSegments) + { + $this->listsSegments = $listsSegments; + } + + /** + * @param Request $request + * @return JsonResponse + * @throws \App\Classes\Exceptions\MalformedRequestException + */ + public function logic(Request $request) : JsonResponse + { + + // $query = $this->listsSegments->execute($this->listsSegments->deserializeFilters($request->input('filters'))); + + // category - Dimension / perKg + $price = array( + + [ + 'details' => json_encode([ + 'name' => 'Sound system speakers - MINI', + 'pricePerKg' => '', + 'pricePerPcs' => '', + 'isProhibited' => '', + 'hasGram' => '', + 'hasDimensionCharges' => '', + 'tax' => '50', + ]) + ], + [ + 'details' => json_encode([ + 'name' => 'Sound system speakers - SMALL', + 'pricePerKg' => '', + 'pricePerPcs' => '', + 'isProhibited' => '', + 'hasGram' => '', + 'hasDimensionCharges' => '', + 'tax' => '200', + ]) + ], + [ + 'details' => json_encode([ + 'name' => 'Sound system speakers - LARGE', + 'pricePerKg' => '', + 'pricePerPcs' => '', + 'isProhibited' => '', + 'hasGram' => '', + 'hasDimensionCharges' => '', + 'tax' => '400', + ]) + ], + [ + 'details' => json_encode([ + 'name' => 'Washing Machine - Dimension', + 'pricePerKg' => '', + 'pricePerPcs' => '', + 'isProhibited' => '', + 'hasGram' => '', + 'hasDimensionCharges' => 'true', + 'tax' => '', + ]) + ], + [ + 'details' => json_encode([ + 'name' => 'Oven, Balnder - perPcs', + 'pricePerKg' => '', + 'pricePerPcs' => '20', + 'isProhibited' => '', + 'hasGram' => '', + 'hasDimensionCharges' => '', + 'tax' => '', + ]) + ], + [ + 'details' => json_encode([ + 'name' => 'Perfume - perKg', + 'pricePerKg' => '33', + 'pricePerPcs' => '', + 'isProhibited' => '', + 'hasGram' => '', + 'hasDimensionCharges' => '', + 'tax' => '', + ]) + ], + [ + 'details' => json_encode([ + 'name' => 'Gold - Prohibited', + 'pricePerKg' => '', + 'pricePerPcs' => '', + 'isProhibited' => 'true', + 'hasGram' => '', + 'hasDimensionCharges' => '', + 'tax' => '', + ]) + ], + [ + 'details' => json_encode([ + 'name' => 'Food - hasGram', + 'pricePerKg' => '', + 'pricePerPcs' => '', + 'isProhibited' => '', + 'hasGram' => 'true', + 'hasDimensionCharges' => '', + 'tax' => '', + ]) + ], + ); + + return $this->collectionResponse(AirShipmentItemPriceResource::collection($price)); + + } + +} \ No newline at end of file diff --git a/app/Http/Controllers/Segments/ListAirShipmentPriceController.php b/app/Http/Controllers/Segments/ListAirShipmentPriceController.php new file mode 100644 index 00000000..15c4ac2b --- /dev/null +++ b/app/Http/Controllers/Segments/ListAirShipmentPriceController.php @@ -0,0 +1,20 @@ +execute($request); + } + +} \ No newline at end of file diff --git a/app/Http/Resources/AirShipmentItemPriceResource.php b/app/Http/Resources/AirShipmentItemPriceResource.php new file mode 100644 index 00000000..7210ba05 --- /dev/null +++ b/app/Http/Resources/AirShipmentItemPriceResource.php @@ -0,0 +1,25 @@ +resource; + $detailsArray = (array)json_decode($object['details']); + + return [ + 'name' => $detailsArray['name'], + 'details' => $object['details'], + ]; + } +} diff --git a/resources/assets/vue/components/orders/sections/DeliveryOrdersSectionComponent.vue b/resources/assets/vue/components/orders/sections/DeliveryOrdersSectionComponent.vue new file mode 100644 index 00000000..a2c8bba0 --- /dev/null +++ b/resources/assets/vue/components/orders/sections/DeliveryOrdersSectionComponent.vue @@ -0,0 +1,458 @@ + + diff --git a/resources/views/pages/airShipment/quotation.blade.php b/resources/views/pages/airShipment/quotation.blade.php new file mode 100644 index 00000000..a38bb854 --- /dev/null +++ b/resources/views/pages/airShipment/quotation.blade.php @@ -0,0 +1,4 @@ +@extends('layouts.base_portal') +@section('inner_content') + +@endsection \ No newline at end of file diff --git a/routes/segment.php b/routes/segment.php index d4406d71..d5e7b3bc 100644 --- a/routes/segment.php +++ b/routes/segment.php @@ -9,6 +9,8 @@ Route::group(['prefix' => 'segment', 'as' => 'segment.', 'namespace' => 'Segment Route::put('/update/{id}', 'UpdateSegmentController@update')->name('update'); Route::get('/list', 'ListSegmentsController@list')->name('list'); + Route::get('/air-shipment/item-price/list', 'ListAirShipmentPriceController@list')->name('air_shipment.price.list'); + Route::group(['prefix' => '{id}/constant', 'as' => 'constant.'], function () { Route::put('/service/update', 'UpdateCustomServiceConstantController@update')->name('service.update'); Route::put('/update', 'UpdateConstantController@update')->name('update'); diff --git a/routes/web.php b/routes/web.php index bb23eb93..55dfe470 100644 --- a/routes/web.php +++ b/routes/web.php @@ -55,6 +55,16 @@ Route::group(['prefix'=> '/last_mile_delivery', 'as' => 'last_mile_delivery.'], }); +Route::group(['prefix'=> '/air_shipment', 'as' => 'air_shipment.'], function () { + // Route::get('/', function () { + // return view('pages.accounts.signup'); + // })->name('login'); + + Route::get('/quotation', function () { + return view('pages.airShipment.quotation'); + })->name('quotation'); +}); + Route::get('', function () { return view('pages.accounts.login'); })->name('login');