Correct input filter component and remove the clear button for other pages

This commit is contained in:
Alex Tselegidis 2022-01-07 08:56:46 +01:00
parent 7b54377f92
commit 7f4756a6df
10 changed files with 22 additions and 119 deletions

View file

@ -15,19 +15,11 @@
<form class="mb-4">
<div class="input-group">
<input type="text" class="key form-control">
<div class="input-group-addon">
<div>
<button class="filter btn btn-outline-secondary" type="submit"
data-tippy-content="<?= lang('filter') ?>">
<i class="fas fa-search"></i>
</button>
<button class="clear btn btn-outline-secondary" type="button"
data-tippy-content="<?= lang('clear') ?>">
<i class="fas fa-redo-alt"></i>
</button>
</div>
</div>
<button class="filter btn btn-outline-secondary" type="submit"
data-tippy-content="<?= lang('filter') ?>">
<i class="fas fa-search"></i>
</button>
</div>
</form>

View file

@ -17,18 +17,10 @@
<div class="input-group">
<input type="text" class="key form-control">
<div class="input-group-addon">
<div>
<button class="filter btn btn-outline-secondary" type="submit"
data-tippy-content="<?= lang('filter') ?>">
<i class="fas fa-search"></i>
</button>
<button class="clear btn btn-outline-secondary" type="button"
data-tippy-content="<?= lang('clear') ?>">
<i class="fas fa-redo-alt"></i>
</button>
</div>
</div>
<button class="filter btn btn-outline-secondary" type="submit"
data-tippy-content="<?= lang('filter') ?>">
<i class="fas fa-search"></i>
</button>
</div>
</form>

View file

@ -17,18 +17,10 @@
<div class="input-group">
<input type="text" class="key form-control">
<div class="input-group-addon">
<div>
<button class="filter btn btn-outline-secondary" type="submit"
data-tippy-content="<?= lang('filter') ?>">
<i class="fas fa-search"></i>
</button>
<button class="clear btn btn-outline-secondary" type="button"
data-tippy-content="<?= lang('clear') ?>">
<i class="fas fa-redo-alt"></i>
</button>
</div>
</div>
<button class="filter btn btn-outline-secondary" type="submit"
data-tippy-content="<?= lang('filter') ?>">
<i class="fas fa-search"></i>
</button>
</div>
</form>

View file

@ -17,18 +17,10 @@
<div class="input-group">
<input type="text" class="key form-control">
<div class="input-group-addon">
<div>
<button class="filter btn btn-outline-secondary" type="submit"
data-tippy-content="<?= lang('filter') ?>">
<i class="fas fa-search"></i>
</button>
<button class="clear btn btn-outline-secondary" type="button"
data-tippy-content="<?= lang('clear') ?>">
<i class="fas fa-redo-alt"></i>
</button>
</div>
</div>
<button class="filter btn btn-outline-secondary" type="submit"
data-tippy-content="<?= lang('filter') ?>">
<i class="fas fa-search"></i>
</button>
</div>
</form>

View file

@ -15,19 +15,11 @@
<form class="mb-4">
<div class="input-group">
<input type="text" class="key form-control">
<div class="input-group-addon">
<div>
<button class="filter btn btn-outline-secondary" type="submit"
data-tippy-content="<?= lang('filter') ?>">
<i class="fas fa-search"></i>
</button>
<button class="clear btn btn-outline-secondary" type="button"
data-tippy-content="<?= lang('clear') ?>">
<i class="fas fa-redo-alt"></i>
</button>
</div>
</div>
<button class="filter btn btn-outline-secondary" type="submit"
data-tippy-content="<?= lang('filter') ?>">
<i class="fas fa-search"></i>
</button>
</div>
</form>

View file

@ -47,19 +47,6 @@
}.bind(this)
);
/**
* Event: Clear Filter Results Button "Click"
*/
$('#admins').on(
'click',
'#filter-admins .clear',
function () {
this.filter('');
$('#filter-admins .key').val('');
this.resetForm();
}.bind(this)
);
/**
* Event: Filter Admin Row "Click"
*

View file

@ -31,15 +31,6 @@
CategoriesHelper.prototype.bindEventHandlers = function () {
var instance = this;
/**
* Event: Filter Categories Cancel Button "Click"
*/
$('#categories').on('click', '#filter-categories .clear', function () {
$('#filter-categories .key').val('');
instance.filter('');
instance.resetForm();
});
/**
* Event: Filter Categories Form "Submit"
*

View file

@ -49,19 +49,6 @@
}.bind(this)
);
/**
* Event: Clear Filter Button "Click"
*/
$('#providers').on(
'click',
'#filter-providers .clear',
function () {
this.filter('');
$('#filter-providers .key').val('');
this.resetForm();
}.bind(this)
);
/**
* Event: Filter Provider Row "Click"
*

View file

@ -49,19 +49,6 @@
}.bind(this)
);
/**
* Event: Clear Filter Results Button "Click"
*/
$('#secretaries').on(
'click',
'#filter-secretaries .clear',
function () {
this.filter('');
$('#filter-secretaries .key').val('');
this.resetForm();
}.bind(this)
);
/**
* Event: Filter Secretary Row "Click"
*

View file

@ -40,15 +40,6 @@
instance.filter(key);
});
/**
* Event: Filter Service Cancel Button "Click"
*/
$('#services').on('click', '#filter-services .clear', function () {
$('#filter-services .key').val('');
instance.filter('');
instance.resetForm();
});
/**
* Event: Filter Service Row "Click"
*