Author:   Lars Michelsen <[email protected]>
Date:     Sun Sep  2 11:34:11 2012 +0200
Committer:   Lars Michelsen <[email protected]>
Commit-Date: Sun Sep  2 11:34:11 2012 +0200

Bugfix: Fixed PHP error in main config edit dialog with newer PHP
versions

---

 ChangeLog                                        |    3 +++
 share/server/core/classes/WuiViewEditMainCfg.php |   13 +++----------
 2 files changed, 6 insertions(+), 10 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index c3a9640..0eee694 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,6 @@
+1.6.7
+  * Bugfix: Fixed PHP error in main config edit dialog with newer PHP versions
+
 1.6.6
 Frontend
   * Bugfix: Fixed JS error in template object management dialog
diff --git a/share/server/core/classes/WuiViewEditMainCfg.php 
b/share/server/core/classes/WuiViewEditMainCfg.php
index c922921..ef07ce5 100644
--- a/share/server/core/classes/WuiViewEditMainCfg.php
+++ b/share/server/core/classes/WuiViewEditMainCfg.php
@@ -56,7 +56,6 @@ class WuiViewEditMainCfg {
      *
      * @return Array Html
      * @author         Lars Michelsen <[email protected]>
-     * FIXME: Recode to have all the HTML code in the template
      */
     function getFields() {
         global $CORE;
@@ -123,7 +122,9 @@ class WuiViewEditMainCfg {
                             $ret .= '<td class="tdfield"></td>';
                         } else {
                             $ret .= '<td class="tdfield">';
-                            $ret .= "<img style=\"cursor:help\" 
src=\"./images/help_icon.png\" onclick=\"javascript:alert('".l($propname)." 
(".l('defaultValue').": ".$arr[$propname]['default'].")')\" />";
+                            $default_str = 
is_array($arr[$propname]['default']) ? implode(',', $arr[$propname]['default']) 
: $arr[$propname]['default'];
+                            $ret .= "<img style=\"cursor:help\" 
src=\"./images/help_icon.png\" "
+                                   
."onclick=\"javascript:alert('".l($propname)." (".l('defaultValue').": 
".$default_str.")')\" />";
                             $ret .= '</td>';
                         }
 
@@ -143,14 +144,6 @@ class WuiViewEditMainCfg {
                                     case 'headertemplate':
                                         $arrOpts = 
$CORE->getAvailableHeaderTemplates();
                                     break;
-                                    case 'autoupdatefreq':
-                                        $arrOpts = 
Array(Array('value'=>'0','label'=>l('disabled')),
-                                                         
Array('value'=>'2','label'=>'2'),
-                                                         
Array('value'=>'5','label'=>'5'),
-                                                         
Array('value'=>'10','label'=>'10'),
-                                                         
Array('value'=>'25','label'=>'25'),
-                                                         
Array('value'=>'50','label'=>'50'));
-                                    break;
                                 }
 
                                 $ret .= '<select id="'.$cat.'_'.$propname.'" 
name="'.$cat.'_'.$propname.'" onBlur="validateMainConfigFieldValue(this, 0)">';


------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
Nagvis-checkins mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/nagvis-checkins

Reply via email to