Clear "Labels" dropdown search filter after selection
This commit is contained in:
parent
b53256559f
commit
9ca1a64191
1 changed files with 6 additions and 0 deletions
|
@ -242,10 +242,16 @@ export default class LabelsSelect {
|
|||
filterable: true,
|
||||
selected: $dropdown.data('selected') || [],
|
||||
toggleLabel: function(selected, el) {
|
||||
var $dropdownParent = $dropdown.parent();
|
||||
var $dropdownInputField = $dropdownParent.find('.dropdown-input-field');
|
||||
var isSelected = el !== null ? el.hasClass('is-active') : false;
|
||||
var title = selected.title;
|
||||
var selectedLabels = this.selected;
|
||||
|
||||
if ($dropdownInputField.length && $dropdownInputField.val().length) {
|
||||
$dropdownParent.find('.dropdown-input-clear').trigger('click');
|
||||
}
|
||||
|
||||
if (selected.id === 0) {
|
||||
this.selected = [];
|
||||
return 'No Label';
|
||||
|
|
Loading…
Reference in a new issue