funcion/pedido-ollas #47
2 changed files with 3 additions and 2 deletions
|
@ -8,7 +8,9 @@ class FiltroDeSubpedido extends Filtro
|
|||
{
|
||||
public function grupoDeCompra(String $valor)
|
||||
{
|
||||
if (!is_numeric($valor)) { throw new TypeError();}
|
||||
if (!is_numeric($valor))
|
||||
throw new TypeError();
|
||||
|
||||
$this->builder->where('grupo_de_compra_id', intval($valor));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -13,7 +13,6 @@ use App\Http\Resources\SubpedidoResource;
|
|||
use Illuminate\Validation\Rule;
|
||||
use Symfony\Component\HttpKernel\Exception\HttpException;
|
||||
|
||||
|
||||
class SubpedidoController extends Controller
|
||||
{
|
||||
public function index(FiltroDeSubpedido $filtros, Request $request)
|
||||
|
|
Loading…
Add table
Reference in a new issue