From bc37347c30c748f186c7b0be4914453b0e31e755 Mon Sep 17 00:00:00 2001 From: ale Date: Wed, 27 Aug 2025 20:41:37 -0300 Subject: [PATCH] =?UTF-8?q?Agregado=20m=C3=A9todo=20para=20crear=20pedido?= =?UTF-8?q?=20de=20faltantes=20y=20sobrantes=20de=20un=20barrio?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../FaltantesYSobrantesController.php | 27 +++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 app/Http/Controllers/FaltantesYSobrantesController.php diff --git a/app/Http/Controllers/FaltantesYSobrantesController.php b/app/Http/Controllers/FaltantesYSobrantesController.php new file mode 100644 index 0000000..ea4918c --- /dev/null +++ b/app/Http/Controllers/FaltantesYSobrantesController.php @@ -0,0 +1,27 @@ + 'faltantes_y_sobrantes']); + $pedido = $gdc->subpedidos()->firstOrCreate([ + 'nombre' => 'Faltantes y Sobrantes de ' . $gdc->nombre, + 'tipo_pedido_id' => $tipoFaltantesYSobrantes->id, + ]); + return response()->json(new PedidoFaltantesYSobrantesResource($pedido)); + } +}