[eGroupWare-svn] r56134 - /trunk/egroupware/api/js/etemplate/et2_extension_nextmatch.js

[email protected] Wed, 11 May 2016 19:56:06 -0000
Newsgroups gmane.comp.web.egroupware.cvs
Message-ID <[email protected]>
Author: nathangray
Date: Wed May 11 21:56:06 2016
New Revision: 56134

URL: http://svn.stylite.de/viewvc/egroupware?rev=56134&view=rev
Log:
If there are 2 or less options for a filterheader, disable multiple toggle

Modified:
    trunk/egroupware/api/js/etemplate/et2_extension_nextmatch.js

Modified: trunk/egroupware/api/js/etemplate/et2_extension_nextmatch.js
URL: http://svn.stylite.de/viewvc/egroupware/trunk/egroupware/api/js/etemplate/et2_extension_nextmatch.js?rev=56134&r1=56133&r2=56134&view=diff
==============================================================================
--- trunk/egroupware/api/js/etemplate/et2_extension_nextmatch.js (original)
+++ trunk/egroupware/api/js/etemplate/et2_extension_nextmatch.js Wed May 11 21:56:06 2016
@@ -3293,6 +3293,19 @@
 	},
 
 	/**
+	 * Disable toggle if there are 2 or less options
+	 * @param {Object[]} options
+	 */
+	set_select_options: function(options)
+	{
+		if(options && options.length <= 2 && this.options.multiple == 'toggle')
+		{
+			this.set_multiple(false)
+		}
+		this._super.apply(this, arguments);
+	},
+
+	/**
 	 * Set nextmatch is the function which has to be implemented for the
 	 * et2_INextmatchHeader interface.
 	 *


------------------------------------------------------------------------------
Mobile security can be enabling, not merely restricting. Employees who
bring their own devices (BYOD) to work are irked by the imposition of MDM
restrictions. Mobile Device Manager Plus allows you to control only the
apps on BYO-devices by containerizing them, leaving personal data untouched!
https://ad.doubleclick.net/ddm/clk/304595813;131938128;j