I have found some nice scripts I would like to use:

But it does not feel right to decide that for each user.

So what do you think about a "add-ons" folder where I can put javascripts (with a description) in and a user can decide for itself to enable or disable such an add-on.

So I can disable the second column and my colleague is able to let it enabled.


Article Comments

I don't think we would implement such a feature soon, but here is a trick that can work:

Each user can select the refresh interval of the web interface (default is 30 seconds). Now you could add a custom script that enables/disables your desired scripts when the interval is set to 29 or 31 seconds. This will make not much of a difference in the usage, but enables you to define custom scripts.

Please find the file

customerscripts.js

in the

/website/javascript

folder, open it in a text editor, paste the following code into it, and save the file:

$(document).ready(function() 
{

	if (autoRefreshInterval==31) // do not show graphs on groups/probes/devices
	{
		$('#tab-1[loadurl*="groupoverview"] td.col2').remove();
	};

	if (autoRefreshInterval==32) // do not show graphs on groups/probes/devices AND hide help
	{
		$('#tab-1[loadurl*="groupoverview"] td.col2').remove();
		$("#openclosehandle").hide();
		$("#helpcontainer").hide();
	};

	if (autoRefreshInterval==33) // hide help
	{
		$("#openclosehandle").hide();
		$("#helpcontainer").hide();
	};

});

Now let your users select their refresh interval to be 30, 31, 32 or 33 seconds.


Jan, 2012 - Permalink