28 lines
1.7 KiB
PHP
28 lines
1.7 KiB
PHP
<form action="{{ request()->fullUrlWithQuery(['rst' => null]) }}">
|
|
<div class="input-group mb-3">
|
|
<label class="input-group-text" for="brandSelect">{{ __('Filter par Marque') }}</label>
|
|
<select class="form-select" id="brandSelect">
|
|
<option value="0" @if (!request()->brand) selected @endif>{{ __('Sélectionnez une marque..') }}</option>
|
|
@foreach (\App\Models\Brand::all() as $brand)
|
|
<option value="{{ $brand->id }}" @if (request()->brand == "$brand->id") selected @endif>{{ $brand->name }}</option>
|
|
@endforeach
|
|
</select>
|
|
<div class="input-group-text bg-warning text-bg-warning">🔍🠚</div>
|
|
<label class="input-group-text" for="searchField">{{ $searchFields }}</label>
|
|
<input class="form-control" id="searchField" name="search" type="search" value="{{ request()->search }}"
|
|
placeholder="Recherche.." />
|
|
<input class="d-none" name="sort_col" type="text" value="{{ request()->sort_col }}" />
|
|
<input class="d-none" name="sort_way" type="text" value="{{ request()->sort_way }}" />
|
|
@if (request()->brand)
|
|
<input class="d-none" name="brand" type="hidden" value="{{ request()->brand }}" />
|
|
@endif
|
|
<button class="btn btn-primary" data-bs-toggle="tooltip" type="submit" title="{{ __('Lancer la recherche') }}">
|
|
<i class="fas fa-search"></i>
|
|
</button>
|
|
<a class="btn btn-danger" data-bs-toggle="tooltip"
|
|
href="{{ request()->fullUrlWithQuery(['rst' => 'true', 'search' => null, 'brand' => null]) }}"
|
|
title="{{ __('Supprimer la recherche') }}">
|
|
<i class="fas fa-backspace"></i>
|
|
</a>
|
|
</div>
|
|
</form>
|