Skip to content

Commit ba1d68b

Browse files
committed
Keep search method remove translation
1 parent 5a054d9 commit ba1d68b

File tree

4 files changed

+4
-32
lines changed

4 files changed

+4
-32
lines changed

resources/views/includes/_options.blade.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,8 @@
2121
@if ($searchEnabled)
2222
<div class="col">
2323
<input
24-
@if (is_numeric($searchDebounce)&&$searchType=='debounce') wire:model.debounce.{{ $searchDebounce }}ms="search" @endif
25-
@if ($searchType=='lazy') wire:model.lazy="search" @endif
24+
@if (is_numeric($searchDebounce) && $searchUpdateMethod === 'debounce') wire:model.debounce.{{ $searchDebounce }}ms="search" @endif
25+
@if ($searchUpdateMethod === 'lazy') wire:model.lazy="search" @endif
2626
@if ($disableSearchOnLoading) wire:loading.attr="disabled" @endif
2727
class="form-control"
2828
type="text"

resources/views/includes/_pagination.blade.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
</div>
66

77
<div class="col text-right text-muted">
8-
{{ __($shownLabel.' :first '.$toLabel.' :last '.$outOfLabel.' :total '.$resultsLable, ['first' => $models->count() ? $models->firstItem() : 0, 'last' => $models->count() ? $models->lastItem() : 0, 'total' => $models->total()]) }}
8+
{{ __('Showing :first to :last out of :total results', ['first' => $models->count() ? $models->firstItem() : 0, 'last' => $models->count() ? $models->lastItem() : 0, 'total' => $models->total()]) }}
99
</div>
1010
</div>
1111
@endif

src/Traits/Pagination.php

Lines changed: 0 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -47,34 +47,6 @@ trait Pagination
4747
*/
4848
public $perPageLabel;
4949

50-
/**
51-
* The label for shown string.
52-
*
53-
* @var string
54-
*/
55-
public $shownLabel='Showing';
56-
57-
/**
58-
* The label for results string.
59-
*
60-
* @var string
61-
*/
62-
public $resultsLable='results';
63-
64-
/**
65-
* The label for out of string.
66-
*
67-
* @var string
68-
*/
69-
public $outOfLabel='out of';
70-
71-
/**
72-
* The label for to string.
73-
*
74-
* @var string
75-
*/
76-
public $toLabel='to';
77-
7850
/**
7951
* https://laravel-livewire.com/docs/pagination
8052
* Resetting Pagination After Filtering Data.

src/Traits/Search.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ trait Search
1616
* Whether search work: debounce or lazy
1717
* @var string
1818
*/
19-
public $searchType = 'debounce';
19+
public $searchUpdateMethod = 'debounce';
2020

2121
/**
2222
* Whether or not searching is enabled.

0 commit comments

Comments
 (0)