Module: check_mk
Branch: master
Commit: e251be4eac6a05596da462448c7666381c08a5f7
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=e251be4eac6a05…
Author: Lars Michelsen <lm(a)mathias-kettner.de>
Date: Mon Dec 2 14:08:17 2013 +0100
FIX Fixed problem with new created tag groups with "/" in title
If you used <tt>/</tt> chars in the tag group titles before, the text before
the first <tt>/</tt> was moved from the title to the topic field. This was
not
intended. This has been fixed now.
However, there is still some issue with this: If you have existing tag groups with
slashes in their title, the same problem will happen. Thist must be fixed by hand
for the moment.
---
.werks/295 | 15 +++++++++++++++
ChangeLog | 1 +
web/htdocs/wato.py | 5 +++--
3 files changed, 19 insertions(+), 2 deletions(-)
diff --git a/.werks/295 b/.werks/295
new file mode 100644
index 0000000..cfe493d
--- /dev/null
+++ b/.werks/295
@@ -0,0 +1,15 @@
+Title: Fixed problem with new created tag groups with "/" in title
+Level: 1
+Component: wato
+Version: 1.2.3i7
+Date: 1385989575
+Class: fix
+
+If you used <tt>/</tt> chars in the tag group titles before, the text before
+the first <tt>/</tt> was moved from the title to the topic field. This was
not
+intended. This has been fixed now.
+
+However, there is still some issue with this: If you have existing tag groups with
+slashes in their title, the same problem will happen. Thist must be fixed by hand
+for the moment.
+
diff --git a/ChangeLog b/ChangeLog
index 1fdb323..39f356b 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -84,6 +84,7 @@
* 0220 FIX: Added HTML escaping to several global settings attributes...
* 0234 FIX: Improved handling of interface inventory states / types...
* 0289 FIX: Renamed "Hosts & Folders" page to "Hosts"
+ * 0295 FIX: Fixed problem with new created tag groups with "/" in title...
Notifications:
* 0005 Added notification script for sending SMS via
mobilant.com...
diff --git a/web/htdocs/wato.py b/web/htdocs/wato.py
index 6a7f783..8de73ae 100644
--- a/web/htdocs/wato.py
+++ b/web/htdocs/wato.py
@@ -10071,8 +10071,9 @@ def mode_edit_hosttag(phase):
raise MKUserError("title", _("Please specify a title for
your host tag group."))
topic = forms.get_input(vs_topic, "topic")
- if topic != '':
- title = '%s/%s' % (topic, title)
+ # always put at least "/" as prefix to the title, the title
+ # will then be split by the first "/' in future
+ title = '%s/%s' % (topic, title)
new_choices = forms.get_input(vs_choices, "choices")
have_none_tag = False