diff --git a/app/resources/routes/api/ventas/reservations.php b/app/resources/routes/api/ventas/reservations.php new file mode 100644 index 0000000..7e2e194 --- /dev/null +++ b/app/resources/routes/api/ventas/reservations.php @@ -0,0 +1,12 @@ +group('/reservations', function($app) { + $app->post('/add[/]', [Reservations::class, 'add']); + $app->get('[/]', Reservations::class); +}); +$app->group('/reservation/{reservation_id}', function($app) { + $app->post('/edit[/]', [Reservations::class, 'edit']); + $app->delete('[/]', [Reservations::class, 'delete']); + $app->get('[/]', [Reservations::class, 'get']); +}); diff --git a/app/src/Controller/API/Ventas/Reservation.php b/app/src/Controller/API/Ventas/Reservations.php similarity index 99% rename from app/src/Controller/API/Ventas/Reservation.php rename to app/src/Controller/API/Ventas/Reservations.php index 42cec23..01c65db 100644 --- a/app/src/Controller/API/Ventas/Reservation.php +++ b/app/src/Controller/API/Ventas/Reservations.php @@ -7,7 +7,7 @@ use Incoviba\Controller\API\withJson; use Incoviba\Exception\ServiceAction; use Incoviba\Service; -class Reservation +class Reservations { use withJson;