From 667d7dbddbd5d1ea244b4d99a032f7dcf4db2354 Mon Sep 17 00:00:00 2001 From: nat Date: Tue, 19 Apr 2022 17:24:59 -0300 Subject: [PATCH] Endpoint crea vista transpuesta en la que los productos son las filas y los barrios son las columnas --- app/Http/Controllers/Api/PedidoController.php | 22 ++++++++++ .../2022_04_13_140901_create_pedidos_view.php | 43 +++++++++++++++++++ routes/api.php | 4 ++ 3 files changed, 69 insertions(+) create mode 100644 app/Http/Controllers/Api/PedidoController.php create mode 100644 database/migrations/2022_04_13_140901_create_pedidos_view.php diff --git a/app/Http/Controllers/Api/PedidoController.php b/app/Http/Controllers/Api/PedidoController.php new file mode 100644 index 0000000..b61b3e2 --- /dev/null +++ b/app/Http/Controllers/Api/PedidoController.php @@ -0,0 +1,22 @@ +group(function () { }); }); + Route::prefix('pedidos')->group(function () { + Route::get('/generar_tablas','Api\PedidoController@generarTablas'); + }); + Route::prefix('subpedidos')->group(function () { Route::get('/','Api\SubpedidoController@index'); Route::get('{subpedido}','Api\SubpedidoController@show');