|
1 | 1 | <div class="card-body">
|
2 | 2 | <!-- View toggle button -->
|
3 |
| - <div class="mb-3"> |
4 |
| - <button class="btn btn-primary" wire:click="changeView('table')"> |
5 |
| - <i class="fas fa-table mr-1"></i> Table |
6 |
| - </button> |
7 |
| - <button class="btn btn-secondary" wire:click="changeView('cards')"> |
8 |
| - <i class="fas fa-th-large mr-1"></i> Cards |
9 |
| - </button> |
| 3 | + <div class="row"> |
| 4 | + <!-- View toggle button --> |
| 5 | + <div class="col-2"> |
| 6 | + <button class="btn btn-primary" wire:click="changeView('table')"> |
| 7 | + <i class="fas fa-table mr-1"></i> Table |
| 8 | + </button> |
| 9 | + <button class="btn btn-secondary" wire:click="changeView('cards')"> |
| 10 | + <i class="fas fa-th-large mr-1"></i> Cards |
| 11 | + </button> |
| 12 | + </div> |
| 13 | + <div class="col-6"> |
| 14 | + @include('include.search-card') |
| 15 | + </div> |
| 16 | + <div class="col-2"> |
| 17 | + <div class="form-group"> |
| 18 | + <div class="input-group"> |
| 19 | + <div class="input-group-prepend"> |
| 20 | + <span class="input-group-text"><i class="fas fa-list"></i></span> |
| 21 | + </div> |
| 22 | + <select class="form-control" name="searchIdPriority" id="searchIdPriority" wire:model.live="searchIdPriority"> |
| 23 | + <option value="" selected>{{ __('general_content.select_statu_trans_key') }}</option> |
| 24 | + <option value="1">{{ __('general_content.burning_trans_key') }}</option> |
| 25 | + <option value="2">{{ __('general_content.hot_trans_key') }}</option> |
| 26 | + <option value="3">{{ __('general_content.lukewarm_trans_key') }}</option> |
| 27 | + <option value="4">{{ __('general_content.cold_trans_key') }}</option> |
| 28 | + </select> |
| 29 | + </div> |
| 30 | + </div> |
| 31 | + </div> |
| 32 | + <div class="col-2"> |
| 33 | + <button type="button" class="btn btn-success float-sm-right" data-toggle="modal" data-target="#ModalLead"> |
| 34 | + {{ __('general_content.new_leads_trans_key')}} |
| 35 | + </button> |
| 36 | + </div> |
10 | 37 | </div>
|
11 | 38 |
|
12 | 39 | <!-- Modal -->
|
|
158 | 185 | </div>
|
159 | 186 | <!-- End Modal -->
|
160 | 187 | @if($viewType === 'table')
|
161 |
| - <div class="card"> |
162 |
| - <div class="table-responsive p-0"> |
163 |
| - <table class="table table-hover"> |
164 |
| - <thead> |
165 |
| - <tr> |
166 |
| - <th></th> |
167 |
| - <th>{{__('general_content.customer_trans_key') }}</th> |
168 |
| - <th>{{ __('general_content.contact_name_trans_key') }}</th> |
169 |
| - <th>{{ __('general_content.adress_name_trans_key') }}</th> |
170 |
| - <th>{{ __('general_content.user_trans_key') }}</th> |
171 |
| - <th>{{ __('general_content.source_trans_key') }}</th> |
172 |
| - <th>{{ __('general_content.priority_trans_key') }}</th> |
173 |
| - <th>{{ __('general_content.campaign_trans_key') }}</th> |
174 |
| - <th> |
175 |
| - <a class="btn btn-secondary" wire:click.prevent="sortBy('statu')" role="button" href="#">{{ __('general_content.status_trans_key') }} @include('include.sort-icon', ['field' => 'statu'])</a> |
176 |
| - </th> |
177 |
| - <th>{{__('general_content.action_trans_key') }}</th> |
178 |
| - </tr> |
179 |
| - </thead> |
180 |
| - <tbody> |
181 |
| - @forelse ($Leadslist as $Lead) |
182 |
| - <tr> |
183 |
| - <td>#{{ $Lead->id }}</td> |
184 |
| - <td><x-CompanieButton id="{{ $Lead->companies_id }}" label="{{ $Lead->companie['label'] }}" /></td> |
185 |
| - <td>{{ $Lead->companie['first_name'] }} {{ $Lead->contact['name'] }}</td> |
186 |
| - <td>{{ $Lead->adresse['adress'] }} {{ $Lead->adresse['zipcode'] }} {{ $Lead->adresse['city'] }}</td> |
187 |
| - <td><img src="{{ Avatar::create($Lead->UserManagement['name'])->toBase64() }}" /></td> |
188 |
| - <td>{{ $Lead->source }}</td> |
189 |
| - <td> |
190 |
| - @if(1 == $Lead->priority ) <span class="badge badge-danger">{{ __('general_content.burning_trans_key') }}</span>@endif |
191 |
| - @if(2 == $Lead->priority ) <span class="badge badge-warning">{{ __('general_content.hot_trans_key') }}</span>@endif |
192 |
| - @if(3 == $Lead->priority ) <span class="badge badge-primary">{{ __('general_content.lukewarm_trans_key') }}</span>@endif |
193 |
| - @if(4 == $Lead->priority ) <span class="badge badge-success">{{ __('general_content.cold_trans_key') }}</span>@endif |
194 |
| - </td> |
195 |
| - <td>{{ $Lead->campaign }}</td> |
196 |
| - <td> |
197 |
| - @if(1 == $Lead->statu ) <span class="badge badge-info">{{ __('general_content.new_trans_key') }}</span>@endif |
198 |
| - @if(2 == $Lead->statu ) <span class="badge badge-warning">{{ __('general_content.assigned_trans_key') }}</span>@endif |
199 |
| - @if(3 == $Lead->statu ) <span class="badge badge-primary">{{ __('general_content.in_progress_trans_key') }}</span>@endif |
200 |
| - @if(4 == $Lead->statu ) <span class="badge badge-success">{{ __('general_content.converted_trans_key') }}</span>@endif |
201 |
| - @if(5 == $Lead->statu ) <span class="badge badge-danger">{{ __('general_content.lost_trans_key') }}</span>@endif |
202 |
| - </td> |
203 |
| - <td> |
204 |
| - <x-ButtonTextView route="{{ route('leads.show', ['id' => $Lead->id])}}" /> |
205 |
| - </td> |
206 |
| - </tr> |
207 |
| - @empty |
208 |
| - <x-EmptyDataLine col="10" text=" {{ __('general_content.no_data_trans_key') }}" /> |
209 |
| - @endforelse |
210 |
| - </tbody> |
211 |
| - <tfoot> |
212 |
| - <tr> |
213 |
| - <th></th> |
214 |
| - <th>{{__('general_content.customer_trans_key') }}</th> |
215 |
| - <th>{{ __('general_content.contact_name_trans_key') }}</th> |
216 |
| - <th>{{ __('general_content.adress_name_trans_key') }}</th> |
217 |
| - <th>{{ __('general_content.user_trans_key') }}</th> |
218 |
| - <th>{{ __('general_content.source_trans_key') }}</th> |
219 |
| - <th>{{ __('general_content.priority_trans_key') }}</th> |
220 |
| - <th>{{ __('general_content.campaign_trans_key') }}</th> |
221 |
| - <th>{{__('general_content.status_trans_key') }}</th> |
222 |
| - <th>{{__('general_content.action_trans_key') }}</th> |
223 |
| - </tr> |
224 |
| - </tfoot> |
225 |
| - </table> |
226 |
| - <!-- /.row --> |
| 188 | + <div class="card"> |
| 189 | + <div class="table-responsive p-0"> |
| 190 | + <table class="table table-hover"> |
| 191 | + <thead> |
| 192 | + <tr> |
| 193 | + <th></th> |
| 194 | + <th>{{__('general_content.customer_trans_key') }}</th> |
| 195 | + <th>{{ __('general_content.contact_name_trans_key') }}</th> |
| 196 | + <th>{{ __('general_content.adress_name_trans_key') }}</th> |
| 197 | + <th>{{ __('general_content.user_trans_key') }}</th> |
| 198 | + <th>{{ __('general_content.source_trans_key') }}</th> |
| 199 | + <th> |
| 200 | + <a class="btn btn-secondary" wire:click.prevent="sortBy('priority')" role="button" href="#">{{ __('general_content.priority_trans_key') }} @include('include.sort-icon', ['field' => 'priority'])</a> |
| 201 | + </th> |
| 202 | + <th>{{ __('general_content.campaign_trans_key') }}</th> |
| 203 | + <th> |
| 204 | + <a class="btn btn-secondary" wire:click.prevent="sortBy('statu')" role="button" href="#">{{ __('general_content.status_trans_key') }} @include('include.sort-icon', ['field' => 'statu'])</a> |
| 205 | + </th> |
| 206 | + <th> |
| 207 | + <a class="btn btn-secondary" wire:click.prevent="sortBy('created_at')" role="button" href="#">{{__('general_content.created_at_trans_key') }}@include('include.sort-icon', ['field' => 'created_at'])</a> |
| 208 | + </th> |
| 209 | + <th>{{__('general_content.action_trans_key') }}</th> |
| 210 | + </tr> |
| 211 | + </thead> |
| 212 | + <tbody> |
| 213 | + @forelse ($Leadslist as $Lead) |
| 214 | + <tr> |
| 215 | + <td>#{{ $Lead->id }}</td> |
| 216 | + <td><x-CompanieButton id="{{ $Lead->companies_id }}" label="{{ $Lead->companie['label'] }}" /></td> |
| 217 | + <td>{{ $Lead->companie['first_name'] }} {{ $Lead->contact['name'] }}</td> |
| 218 | + <td>{{ $Lead->adresse['adress'] }} {{ $Lead->adresse['zipcode'] }} {{ $Lead->adresse['city'] }}</td> |
| 219 | + <td><img src="{{ Avatar::create($Lead->UserManagement['name'])->toBase64() }}" /></td> |
| 220 | + <td>{{ $Lead->source }}</td> |
| 221 | + <td> |
| 222 | + @if(1 == $Lead->priority ) <span class="badge badge-danger">{{ __('general_content.burning_trans_key') }}</span>@endif |
| 223 | + @if(2 == $Lead->priority ) <span class="badge badge-warning">{{ __('general_content.hot_trans_key') }}</span>@endif |
| 224 | + @if(3 == $Lead->priority ) <span class="badge badge-primary">{{ __('general_content.lukewarm_trans_key') }}</span>@endif |
| 225 | + @if(4 == $Lead->priority ) <span class="badge badge-success">{{ __('general_content.cold_trans_key') }}</span>@endif |
| 226 | + </td> |
| 227 | + <td>{{ $Lead->campaign }}</td> |
| 228 | + <td> |
| 229 | + @if(1 == $Lead->statu ) <span class="badge badge-info">{{ __('general_content.new_trans_key') }}</span>@endif |
| 230 | + @if(2 == $Lead->statu ) <span class="badge badge-warning">{{ __('general_content.assigned_trans_key') }}</span>@endif |
| 231 | + @if(3 == $Lead->statu ) <span class="badge badge-primary">{{ __('general_content.in_progress_trans_key') }}</span>@endif |
| 232 | + @if(4 == $Lead->statu ) <span class="badge badge-success">{{ __('general_content.converted_trans_key') }}</span>@endif |
| 233 | + @if(5 == $Lead->statu ) <span class="badge badge-danger">{{ __('general_content.lost_trans_key') }}</span>@endif |
| 234 | + </td> |
| 235 | + <td>{{ $Lead->GetPrettyCreatedAttribute() }}</td> |
| 236 | + <td> |
| 237 | + <x-ButtonTextView route="{{ route('leads.show', ['id' => $Lead->id])}}" /> |
| 238 | + </td> |
| 239 | + </tr> |
| 240 | + @empty |
| 241 | + <x-EmptyDataLine col="10" text=" {{ __('general_content.no_data_trans_key') }}" /> |
| 242 | + @endforelse |
| 243 | + </tbody> |
| 244 | + <tfoot> |
| 245 | + <tr> |
| 246 | + <th></th> |
| 247 | + <th>{{__('general_content.customer_trans_key') }}</th> |
| 248 | + <th>{{ __('general_content.contact_name_trans_key') }}</th> |
| 249 | + <th>{{ __('general_content.adress_name_trans_key') }}</th> |
| 250 | + <th>{{ __('general_content.user_trans_key') }}</th> |
| 251 | + <th>{{ __('general_content.source_trans_key') }}</th> |
| 252 | + <th>{{ __('general_content.priority_trans_key') }}</th> |
| 253 | + <th>{{ __('general_content.campaign_trans_key') }}</th> |
| 254 | + <th>{{__('general_content.status_trans_key') }}</th> |
| 255 | + <th>{{__('general_content.created_at_trans_key') }}</th> |
| 256 | + <th>{{__('general_content.action_trans_key') }}</th> |
| 257 | + </tr> |
| 258 | + </tfoot> |
| 259 | + </table> |
| 260 | + <!-- /.row --> |
| 261 | + </div> |
| 262 | + <!-- /.card --> |
227 | 263 | </div>
|
228 |
| - <!-- /.card --> |
229 |
| - </div> |
230 | 264 | @else
|
231 | 265 | <!-- Vue en cartes -->
|
232 | 266 | <div class="row">
|
|
0 commit comments