Enable the toggleSelect extension in multi-select dropdowns
The toggleSelect extension for Select2 makes possible to unselect items in a multi-select dropdown by clicking on them; this behaviour should be enabled in all the multi-select dropdowns used in the server. Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
This commit is contained in:
parent
bf4913acb9
commit
3a660a1b89
|
@ -93,6 +93,7 @@ function addSelect2 ($elements, userListLimit) {
|
||||||
placeholder: t('files_external', 'All users. Type to select user or group.'),
|
placeholder: t('files_external', 'All users. Type to select user or group.'),
|
||||||
allowClear: true,
|
allowClear: true,
|
||||||
multiple: true,
|
multiple: true,
|
||||||
|
toggleSelect: true,
|
||||||
dropdownCssClass: 'files-external-select2',
|
dropdownCssClass: 'files-external-select2',
|
||||||
//minimumInputLength: 1,
|
//minimumInputLength: 1,
|
||||||
ajax: {
|
ajax: {
|
||||||
|
|
|
@ -88,6 +88,7 @@
|
||||||
placeholder: t('systemtags', 'Select tags to filter by'),
|
placeholder: t('systemtags', 'Select tags to filter by'),
|
||||||
allowClear: false,
|
allowClear: false,
|
||||||
multiple: true,
|
multiple: true,
|
||||||
|
toggleSelect: true,
|
||||||
separator: ',',
|
separator: ',',
|
||||||
query: _.bind(this._queryTagsAutocomplete, this),
|
query: _.bind(this._queryTagsAutocomplete, this),
|
||||||
|
|
||||||
|
|
|
@ -30,6 +30,7 @@ OC.Settings = _.extend(OC.Settings, {
|
||||||
placeholder: t('core', 'Groups'),
|
placeholder: t('core', 'Groups'),
|
||||||
allowClear: true,
|
allowClear: true,
|
||||||
multiple: true,
|
multiple: true,
|
||||||
|
toggleSelect: true,
|
||||||
separator: '|',
|
separator: '|',
|
||||||
query: _.debounce(function(query) {
|
query: _.debounce(function(query) {
|
||||||
var queryData = {};
|
var queryData = {};
|
||||||
|
|
Loading…
Reference in New Issue