Author: Lars Michelsen <[email protected]>
Date: Wed Nov 23 20:12:16 2011 +0100
Committer: Lars Michelsen <[email protected]>
Commit-Date: Wed Nov 23 20:12:16 2011 +0100
Bugfix: Not adding default_params parameter to all maps after editing
the global map configuration using the web frontend
---
ChangeLog | 2 ++
TODO | 3 ++-
etc/maps/demo-germany.cfg | 1 -
etc/maps/demo-muc-srv1.cfg | 1 -
etc/maps/demo-overview.cfg | 1 -
share/server/core/classes/WuiViewMapAddModify.php | 5 ++++-
share/server/core/mapcfg/default.php | 7 ++++---
7 files changed, 12 insertions(+), 8 deletions(-)
diff --git a/ChangeLog b/ChangeLog
index 99bdecd..f866320 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -8,6 +8,8 @@ Core
Frontend
* Sorting maps by alias in header menu now
+ * Bugfix: Not adding default_params parameter to all maps after editing the
+ global map configuration using the web frontend
1.6rc4
Core
diff --git a/TODO b/TODO
index 4660c42..6ab6776 100644
--- a/TODO
+++ b/TODO
@@ -10,8 +10,9 @@ Relative Koordinaten:
- Beim Config Parsen Fehlermeldung erzeugen
- Sidebar Folder auf/zu klappbar
- label_text Default bei Services soll auf [service_description] stehen
-- default_params wird bei allen maps hinzugefügt
- Objekt klonen neu implementieren
+- 660 bei neuen Dateien
+ - Eventuell auch eine Standard umask setzen
-------------------------------------------------------------------------------
diff --git a/etc/maps/demo-germany.cfg b/etc/maps/demo-germany.cfg
index 2a7c996..0c4c742 100644
--- a/etc/maps/demo-germany.cfg
+++ b/etc/maps/demo-germany.cfg
@@ -3,7 +3,6 @@ object_id=0
map_image=demo-germany.png
iconset=std_medium
background_color=#e8e8e8
-default_params=&childLayers=2
backend_id=demo
alias=Demo: 0 Overview Germany
parent_map=demo-overview
diff --git a/etc/maps/demo-muc-srv1.cfg b/etc/maps/demo-muc-srv1.cfg
index 522b8dd..87d2b9a 100644
--- a/etc/maps/demo-muc-srv1.cfg
+++ b/etc/maps/demo-muc-srv1.cfg
@@ -6,7 +6,6 @@ map_image=demo-host.png
background_color=#e8e8e8
parent_map=demo-overview
alias=Demo: 3 Server - muc-srv1
-default_params=&childLayers=2
}
define textbox {
diff --git a/etc/maps/demo-overview.cfg b/etc/maps/demo-overview.cfg
index f585ba3..498540e 100644
--- a/etc/maps/demo-overview.cfg
+++ b/etc/maps/demo-overview.cfg
@@ -8,7 +8,6 @@ object_id=0
label_style=font-size:16px;font-weight:bold;color:#ffffff
map_image=demo-overview.png
background_color=#e8e8e8
-default_params=childLayers=-1&renderMode=undirected2&width=500&height=500
label_x=+46
label_y=+3
}
diff --git a/share/server/core/classes/WuiViewMapAddModify.php
b/share/server/core/classes/WuiViewMapAddModify.php
index 8916b75..e8b5450 100644
--- a/share/server/core/classes/WuiViewMapAddModify.php
+++ b/share/server/core/classes/WuiViewMapAddModify.php
@@ -144,8 +144,11 @@ class WuiViewMapAddModify {
list($inherited, $value) = $this->getAttr($typeDefaults, $update,
$objId, $propname, $prop['must']);
unset($this->hiddenAttrs[$propname]);
+ // Only add the fields of type hidden which have values
if($fieldType === 'hidden') {
- $ret .= '<input id="'.$propname.'" type="hidden"
name="'.$propname.'" value="'.$value.'" />';
+ if($value != '') {
+ $ret .= '<input id="'.$propname.'" type="hidden"
name="'.$propname.'" value="'.$value.'" />';
+ }
continue;
}
diff --git a/share/server/core/mapcfg/default.php
b/share/server/core/mapcfg/default.php
index 137d87c..8d48971 100644
--- a/share/server/core/mapcfg/default.php
+++ b/share/server/core/mapcfg/default.php
@@ -189,9 +189,10 @@ $mapConfigVars = Array(
'match' => MATCH_COLOR),
'default_params' => Array(
'must' => 0,
- 'default' => cfg('automap', 'defaultparams'),
- 'match' => MATCH_STRING_URL,
- 'field_type' => 'hidden'),
+ 'default' => '',
+ 'match' => MATCH_STRING_URL_EMPTY,
+ 'field_type' => 'hidden',
+ ),
'parent_map' => Array(
'must' => 0,
'default' => '',
------------------------------------------------------------------------------
All the data continuously generated in your IT infrastructure
contains a definitive record of customers, application performance,
security threats, fraudulent activity, and more. Splunk takes this
data and makes sense of it. IT sense. And common sense.
http://p.sf.net/sfu/splunk-novd2d
_______________________________________________
Nagvis-checkins mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/nagvis-checkins