доработка компоненты вывода клиентов: обновлена строка фильров
This commit is contained in:
parent
1dfd1570a4
commit
403e009ad0
@ -1,17 +1,69 @@
|
|||||||
<?php
|
<?php
|
||||||
use Modules\Main\Models\Deal\DealStatus;
|
use Modules\Main\Models\Deal\DealStatus;
|
||||||
?>
|
?>
|
||||||
<div class="d-flex gap-2 flex-column flex-lg-row">
|
<div>
|
||||||
<div class="d-flex flex-row col-12 col-lg-auto border rounded-3 border-1 p-0 bg-white" style="">
|
<div class="input-group mb-3 d-none">
|
||||||
|
<button class="btn btn-outline-secondary dropdown-toggle" type="button" data-bs-toggle="dropdown"
|
||||||
|
aria-expanded="false">
|
||||||
|
{{ (array_key_exists('status', $filter)) ? __('deal.' . $filter['status']) : 'Статус' }}
|
||||||
|
</button>
|
||||||
|
<ul class="dropdown-menu p-2">
|
||||||
|
<li>
|
||||||
<input wire:model.live="filter.status" type="radio" class="btn-check" name="status"
|
<input wire:model.live="filter.status" type="radio" class="btn-check" name="status"
|
||||||
value="{{ DealStatus::MODERATION }}" id="option5" autocomplete="off" {{ (array_key_exists('status', $filter) && $filter['status'] == DealStatus::MODERATION) ? 'checked' : '' }}>
|
value="{{ DealStatus::MODERATION }}" id="option5" autocomplete="off" {{ (array_key_exists('status', $filter) && $filter['status'] == DealStatus::MODERATION) ? 'checked' : '' }}>
|
||||||
<label class="btn p-2 fs-5 text-truncate" for="option5">На проверке</label>
|
<label class="" for="option5">На проверке</label>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
<input wire:model.live="filter.status" type="radio" class="btn-check" name="status"
|
<input wire:model.live="filter.status" type="radio" class="btn-check" name="status"
|
||||||
value="{{ DealStatus::UNIQUE }}" id="option6" autocomplete="off" {{ (array_key_exists('status', $filter) && $filter['status'] == DealStatus::UNIQUE) ? 'checked' : '' }}>
|
value="{{ DealStatus::UNIQUE }}" id="option6" autocomplete="off" {{ (array_key_exists('status', $filter) && $filter['status'] == DealStatus::UNIQUE) ? 'checked' : '' }}>
|
||||||
<label class="btn p-2 fs-5 text-truncate" for="option6">Уникальные</label>
|
<label class="" for="option6">Уникальные</label>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
<input wire:model.live="filter.status" type="radio" class="btn-check" name="status"
|
<input wire:model.live="filter.status" type="radio" class="btn-check" name="status"
|
||||||
value="{{ DealStatus::NOT_UNIQUE }}" id="option7" autocomplete="off" {{ (array_key_exists('status', $filter) && $filter['status'] == DealStatus::NOT_UNIQUE) ? 'checked' : '' }}>
|
value="{{ DealStatus::NOT_UNIQUE }}" id="option7" autocomplete="off" {{ (array_key_exists('status', $filter) && $filter['status'] == DealStatus::NOT_UNIQUE) ? 'checked' : '' }}>
|
||||||
<label class="btn p-2 fs-5 text-truncate" for="option7">Не уникальные</label>
|
<label class="" for="option7">Не уникальные</label>
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
|
<button class="btn btn-outline-secondary dropdown-toggle" type="button" data-bs-toggle="dropdown"
|
||||||
|
aria-expanded="false">
|
||||||
|
@if(array_key_exists('complexes', $filter))
|
||||||
|
<span class="text-truncate">{{ $filter['complexes'][0]['name'] }}</span>
|
||||||
|
@if(count($filter['complexes']) > 1)
|
||||||
|
<span>
|
||||||
|
+ <span class="d-inline-block bg-secondary rounded-circle fs-6 text-light"
|
||||||
|
style="width:1.3rem;height:1.3rem">{{ count($filter['complexes']) - 1 }}</span>
|
||||||
|
</span>
|
||||||
|
@endif
|
||||||
|
@else
|
||||||
|
Жилой комплекс
|
||||||
|
@endif
|
||||||
|
</button>
|
||||||
|
<ul class="dropdown-menu">
|
||||||
|
@foreach ($complexes as $complex)
|
||||||
|
<li>
|
||||||
|
<div class="dropdown-item">
|
||||||
|
<input wire:change="toggleComplex({{ $complex['id'] }})" class="form-check-input" type="checkbox"
|
||||||
|
id="complex_selector_{{ $complex['id'] }}">
|
||||||
|
<label class="form-check-label" for="complex_selector_{{ $complex['id'] }}">
|
||||||
|
{{ $complex['name'] }}
|
||||||
|
</label>
|
||||||
|
</div>
|
||||||
|
</li>
|
||||||
|
@endforeach
|
||||||
|
</ul>
|
||||||
|
<input type="text" class="form-control" aria-label="Text input with dropdown button">
|
||||||
|
</div>
|
||||||
|
<div class="d-flex gap-2 flex-column flex-lg-row">
|
||||||
|
<div class="d-flex flex-row col-12 col-lg-auto p-0" style="">
|
||||||
|
<input wire:model.live="filter.status" type="radio" class="btn-check" name="status"
|
||||||
|
value="{{ DealStatus::MODERATION }}" id="option5" autocomplete="off" {{ (array_key_exists('status', $filter) && $filter['status'] == DealStatus::MODERATION) ? 'checked' : '' }}>
|
||||||
|
<label class="btn btn-secondary py-2 px-1 rounded-0 rounded-start fs-5 text-truncate" for="option5">На проверке</label>
|
||||||
|
<input wire:model.live="filter.status" type="radio" class="btn-check" name="status"
|
||||||
|
value="{{ DealStatus::UNIQUE }}" id="option6" autocomplete="off" {{ (array_key_exists('status', $filter) && $filter['status'] == DealStatus::UNIQUE) ? 'checked' : '' }}>
|
||||||
|
<label class="btn btn-secondary py-2 px-1 rounded-0 fs-5 text-truncate" for="option6">Уникальные</label>
|
||||||
|
<input wire:model.live="filter.status" type="radio" class="btn-check" name="status"
|
||||||
|
value="{{ DealStatus::NOT_UNIQUE }}" id="option7" autocomplete="off" {{ (array_key_exists('status', $filter) && $filter['status'] == DealStatus::NOT_UNIQUE) ? 'checked' : '' }}>
|
||||||
|
<label class="btn btn-secondary py-2 px-1 rounded-0 rounded-end fs-5 text-truncate" for="option7">Не уникальные</label>
|
||||||
</div>
|
</div>
|
||||||
<div class="input-group flex-fill">
|
<div class="input-group flex-fill">
|
||||||
<span class="input-group-text" id="basic-addon1">
|
<span class="input-group-text" id="basic-addon1">
|
||||||
@ -22,11 +74,13 @@
|
|||||||
</path>
|
</path>
|
||||||
</svg>
|
</svg>
|
||||||
</span>
|
</span>
|
||||||
<input wire:model.live="filter.search" type="text" class="form-control form-control-lg" placeholder="Поиск по имени, телефону, электронной почте">
|
<input wire:model.live="filter.search" type="text" class="form-control form-control-lg"
|
||||||
|
placeholder="Поиск по имени, телефону, электронной почте">
|
||||||
</div>
|
</div>
|
||||||
<!-- Выбор ЖК-->
|
<!-- Выбор ЖК-->
|
||||||
<div class="btn-group bg-light d-flex rounded-4 ">
|
<div class="btn-group bg-light d-flex rounded-4 ">
|
||||||
<button type="button" class="p-0 btn bg-light text-primary border overflow-hidden w-100 rounded-start-3 pe-0"
|
<button type="button"
|
||||||
|
class="p-0 btn bg-light text-primary border overflow-hidden w-100 rounded-start-3 pe-0"
|
||||||
style="mask-image: linear-gradient(to right, black, black 90%, transparent);">
|
style="mask-image: linear-gradient(to right, black, black 90%, transparent);">
|
||||||
<div class="mx-1 text-truncate fs-5">
|
<div class="mx-1 text-truncate fs-5">
|
||||||
@if(array_key_exists('complexes', $filter))
|
@if(array_key_exists('complexes', $filter))
|
||||||
@ -39,22 +93,22 @@
|
|||||||
</span>
|
</span>
|
||||||
@endif
|
@endif
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@else
|
@else
|
||||||
<div class="m-2">ЖК</div>
|
<div class="m-2">ЖК</div>
|
||||||
@endif
|
@endif
|
||||||
</div>
|
</div>
|
||||||
</button>
|
</button>
|
||||||
<button type="button" style="width:30px" class="btn btn-secondary dropdown-toggle dropdown-toggle-split show"
|
<button type="button" style="width:30px"
|
||||||
data-bs-toggle="dropdown" aria-expanded="true" data-bs-reference="parent">
|
class="btn btn-secondary dropdown-toggle dropdown-toggle-split show" data-bs-toggle="dropdown"
|
||||||
|
aria-expanded="true" data-bs-reference="parent">
|
||||||
<span class="visually-hidden">Toggle Dropdown</span>
|
<span class="visually-hidden">Toggle Dropdown</span>
|
||||||
</button>
|
</button>
|
||||||
<ul class="dropdown-menu dropdown-menu-end">
|
<ul class="dropdown-menu dropdown-menu-end">
|
||||||
@foreach ($complexes as $complex)
|
@foreach ($complexes as $complex)
|
||||||
<li>
|
<li>
|
||||||
<div class="dropdown-item">
|
<div class="dropdown-item">
|
||||||
<input wire:change="toggleComplex({{ $complex['id'] }})" class="form-check-input" type="checkbox"
|
<input wire:change="toggleComplex({{ $complex['id'] }})" class="form-check-input"
|
||||||
id="complex_selector_{{ $complex['id'] }}">
|
type="checkbox" id="complex_selector_{{ $complex['id'] }}">
|
||||||
<label class="form-check-label" for="complex_selector_{{ $complex['id'] }}">
|
<label class="form-check-label" for="complex_selector_{{ $complex['id'] }}">
|
||||||
{{ $complex['name'] }}
|
{{ $complex['name'] }}
|
||||||
</label>
|
</label>
|
||||||
@ -68,18 +122,5 @@
|
|||||||
@endif
|
@endif
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
<style>
|
</div>
|
||||||
.form-search__container {
|
|
||||||
position: relative;
|
|
||||||
}
|
|
||||||
|
|
||||||
.form-search__container::before {
|
|
||||||
content: '';
|
|
||||||
position: absolute;
|
|
||||||
left: 0;
|
|
||||||
height: 3rem;
|
|
||||||
width: 3rem;
|
|
||||||
background-image: ""
|
|
||||||
}
|
|
||||||
</style>
|
|
||||||
</div>
|
</div>
|
||||||
7
lang/ru/deal.php
Normal file
7
lang/ru/deal.php
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
<?php
|
||||||
|
return [
|
||||||
|
'NEW' => 'Новый',
|
||||||
|
'MODERATION' => 'На проверке',
|
||||||
|
'UNIQUE' => 'Уникальный',
|
||||||
|
'NOT UNIQUE' => 'Не уникальный',
|
||||||
|
];
|
||||||
@ -7,8 +7,8 @@
|
|||||||
<div class="w-100">
|
<div class="w-100">
|
||||||
@livewire('clients.search.input')
|
@livewire('clients.search.input')
|
||||||
</div>
|
</div>
|
||||||
<div class="ms-auto py-1 d-none d-md-block">
|
<div class="ms-auto p-0 d-none d-md-block">
|
||||||
<button type="button" class="btn btn-primary py-2 px-3 fs-5" data-bs-toggle="modal"
|
<button type="button" class="btn btn-primary h-100 py-2 px-3 fs-5" data-bs-toggle="modal"
|
||||||
data-bs-target="#createClientModal">
|
data-bs-target="#createClientModal">
|
||||||
<i class="bi bi-person-plus"></i> <span class="d-inline d-none">Добавить клиента</span>
|
<i class="bi bi-person-plus"></i> <span class="d-inline d-none">Добавить клиента</span>
|
||||||
</button>
|
</button>
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user