Module: check_mk
Branch: master
Commit: 18c3e74f06e329c5cd06fbfd6683892e23fc02e9
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=18c3e74f06e329…
Author: Mathias Kettner <mk(a)mathias-kettner.de>
Date: Thu Jul 30 11:51:39 2015 +0200
#2491 Allow clickable URLs in comments and downtime texts
When you in include an URL like <tt>http://www.mysite.de/...</tt> into the
comment of a downtime or an acknowledgment then this URL will now be replaced
with a clickable icon pointing to that link.
---
.werks/2491 | 11 +++++++++++
ChangeLog | 1 +
web/plugins/views/painters.py | 4 ++--
3 files changed, 14 insertions(+), 2 deletions(-)
diff --git a/.werks/2491 b/.werks/2491
new file mode 100644
index 0000000..938294c
--- /dev/null
+++ b/.werks/2491
@@ -0,0 +1,11 @@
+Title: Allow clickable URLs in comments and downtime texts
+Level: 2
+Component: multisite
+Compatible: compat
+Version: 1.2.7i3
+Date: 1438249800
+Class: feature
+
+When you in include an URL like <tt>http://www.mysite.de/...</tt> into the
+comment of a downtime or an acknowledgment then this URL will now be replaced
+with a clickable icon pointing to that link.
diff --git a/ChangeLog b/ChangeLog
index baaf9dc..a77a1be 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -106,6 +106,7 @@
* 2471 User IDs are now allowed to contain special characters (like German
umlauts)...
* 2484 Virtual Host Tree now allows adding levels of WATO folders...
* 2501 Implemented new crash report handling...
+ * 2491 Allow clickable URLs in comments and downtime texts...
* 2314 FIX: Availability: fixed exception when grouping by host or service group
* 2361 FIX: Fix exception for missing key 'title' in certain cases of older
customized views
* 2379 FIX: Plugin-Output: Fixed handling of URLs within output of check_http...
diff --git a/web/plugins/views/painters.py b/web/plugins/views/painters.py
index e1ff050..fc9f0b9 100644
--- a/web/plugins/views/painters.py
+++ b/web/plugins/views/painters.py
@@ -1751,7 +1751,7 @@ multisite_painters["comment_author"] = {
multisite_painters["comment_comment"] = {
"title" : _("Comment text"),
"columns" : ["comment_comment"],
- "paint" : lambda row: (None,
html.attrencode(row["comment_comment"])),
+ "paint" : lambda row: (None,
format_plugin_output(row["comment_comment"])),
}
multisite_painters["comment_what"] = {
@@ -1837,7 +1837,7 @@ multisite_painters["downtime_comment"] = {
"title" : _("Downtime comment"),
"short" : _("Comment"),
"columns" : ["downtime_comment"],
- "paint" : lambda row: (None,
html.attrencode(row["downtime_comment"])),
+ "paint" : lambda row: (None,
format_plugin_output(row["downtime_comment"])),
}
multisite_painters["downtime_fixed"] = {