Module: nagvis Branch: nagvis-1.4 Commit: 4196e6eb156263fa9fe4aa0122eb2d062f0e4f7f URL: http://nagvis.git.sourceforge.net/git/gitweb.cgi?p=nagvis/nagvis/commit/?id=4196e6eb156263fa9fe4aa0122eb2d062f0e4f7f
Author: Lars Michelsen <[email protected]> Date: Fri Aug 14 21:53:14 2009 +0200 #67 Add scale parameter as optional gadget option --- nagvis/nagvis/includes/classes/GlobalMapCfg.php | 5 +++++ nagvis/nagvis/includes/js/NagVisService.js | 2 +- 2 files changed, 6 insertions(+), 1 deletions(-) diff --git a/nagvis/nagvis/includes/classes/GlobalMapCfg.php b/nagvis/nagvis/includes/classes/GlobalMapCfg.php index 1173093..957ba7a 100644 --- a/nagvis/nagvis/includes/classes/GlobalMapCfg.php +++ b/nagvis/nagvis/includes/classes/GlobalMapCfg.php @@ -611,6 +611,11 @@ class GlobalMapCfg { 'field_type' => 'dropdown', 'depends_on' => 'view_type', 'depends_value' => 'gadget'), + 'gadget_scale' => Array('must' => 0, + 'default' => 100, + 'match' => MATCH_INTEGER, + 'depends_on' => 'view_type', + 'depends_value' => 'gadget'), 'context_menu' => Array('must' => 0, 'match' => MATCH_BOOLEAN, diff --git a/nagvis/nagvis/includes/js/NagVisService.js b/nagvis/nagvis/includes/js/NagVisService.js index f4ea690..e83343b 100644 --- a/nagvis/nagvis/includes/js/NagVisService.js +++ b/nagvis/nagvis/includes/js/NagVisService.js @@ -53,7 +53,7 @@ var NagVisService = NagVisStatefulObject.extend({ sParams = '&'; } - sParams = sParams + 'name1=' + this.conf.name + '&name2=' + escapeUrlValues(this.conf.service_description) + '&state=' + this.conf.state + '&stateType=' + this.conf.state_type + '&perfdata=' + this.conf.perfdata.replace(/\"\;|\&\#145\;/g,'%22'); + sParams = sParams + 'name1=' + this.conf.name + '&name2=' + escapeUrlValues(this.conf.service_description) + '&scale=' + escapeUrlValues(this.conf.gadget_scale.toString()) + '&state=' + this.conf.state + '&stateType=' + this.conf.state_type + '&perfdata=' + this.conf.perfdata.replace(/\"\;|\&\#145\;/g,'%22'); var oIcon = document.createElement('img'); oIcon.setAttribute('id', this.conf.object_id+'-icon'); ------------------------------------------------------------------------------ Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day trial. Simplify your report design, integration and deployment - and focus on what you do best, core application coding. Discover what's new with Crystal Reports now. http://p.sf.net/sfu/bobj-july _______________________________________________ Nagvis-checkins mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/nagvis-checkins
