aboutsummaryrefslogtreecommitdiffstats
path: root/apps/user_ldap/js/wizard/wizardTabGeneric.js
diff options
context:
space:
mode:
Diffstat (limited to 'apps/user_ldap/js/wizard/wizardTabGeneric.js')
-rw-r--r--apps/user_ldap/js/wizard/wizardTabGeneric.js33
1 files changed, 17 insertions, 16 deletions
diff --git a/apps/user_ldap/js/wizard/wizardTabGeneric.js b/apps/user_ldap/js/wizard/wizardTabGeneric.js
index 9997d6e1b04..3496dee5009 100644
--- a/apps/user_ldap/js/wizard/wizardTabGeneric.js
+++ b/apps/user_ldap/js/wizard/wizardTabGeneric.js
@@ -1,8 +1,7 @@
-
/**
- * Copyright (c) 2015, Arthur Schiwon <blizzz@owncloud.com>
- * This file is licensed under the Affero General Public License version 3 or later.
- * See the COPYING-README file.
+ * SPDX-FileCopyrightText: 2017-2024 Nextcloud GmbH and Nextcloud contributors
+ * SPDX-FileCopyrightText: 2015-2016 ownCloud, Inc.
+ * SPDX-License-Identifier: AGPL-3.0-or-later
*/
OCA = OCA || {};
@@ -29,7 +28,7 @@ OCA = OCA || {};
bjQuiButtonClass: 'ui-button',
/**
- * @property {bool} - indicates whether a filter mode toggle operation
+ * @property {boolean} - indicates whether a filter mode toggle operation
* is still in progress
*/
isToggling: false,
@@ -147,8 +146,8 @@ OCA = OCA || {};
/**
* displays server error messages.
*
- * @param view
- * @param payload
+ * @param {any} view -
+ * @param {any} payload -
*/
onServerError: function(view, payload) {
if ( !_.isUndefined(view.managedItems[payload.relatedKey])) {
@@ -228,10 +227,12 @@ OCA = OCA || {};
* @param {Array} options
*/
equipMultiSelect: function($element, options) {
- $element.empty();
- for (var i in options) {
- var name = options[i];
- $element.append($('<option>').val(name).text(name).attr('title', name));
+ if($element.find('option').length === 0) {
+ $element.empty();
+ for (var i in options) {
+ var name = options[i];
+ $element.append($('<option>').val(name).text(name).attr('title', name));
+ }
}
if(!$element.hasClass('ldapGroupList')) {
$element.multiselect('refresh');
@@ -390,9 +391,9 @@ OCA = OCA || {};
/**
* @typedef {object} viewSaveInfo
- * @property {function} val
- * @property {function} attr
- * @property {function} is
+ * @property {Function} val
+ * @property {Function} attr
+ * @property {Function} is
*/
/**
@@ -454,7 +455,7 @@ OCA = OCA || {};
* sets the filter mode initially and resets the "isToggling" marker.
* This method is called after a save operation against the mode key.
*
- * @param mode
+ * @param {any} mode -
*/
setFilterModeOnce: function(mode) {
this.isToggling = false;
@@ -551,7 +552,7 @@ OCA = OCA || {};
) {
toggleFnc(true);
} else {
- OCdialogs.confirm(
+ OC.dialogs.confirm(
t('user_ldap', 'Switching the mode will enable automatic LDAP queries. Depending on your LDAP size they may take a while. Do you still want to switch the mode?'),
t('user_ldap', 'Mode switch'),
toggleFnc