From 591200dab6feb2a5f9f42292fc92e778591a8a38 Mon Sep 17 00:00:00 2001 From: Tim Laszlo Date: Thu, 14 Jun 2012 11:20:25 -0500 Subject: web_reports: Make reasons clickable in entry listings --- src/lib/Bcfg2/Server/Reports/reports/models.py | 2 ++ src/lib/Bcfg2/Server/Reports/reports/templates/config_items/common.html | 2 +- .../Bcfg2/Server/Reports/reports/templates/config_items/listing.html | 2 +- 3 files changed, 4 insertions(+), 2 deletions(-) (limited to 'src/lib/Bcfg2/Server/Reports') diff --git a/src/lib/Bcfg2/Server/Reports/reports/models.py b/src/lib/Bcfg2/Server/Reports/reports/models.py index 3bce17a30..2ddaba02a 100644 --- a/src/lib/Bcfg2/Server/Reports/reports/models.py +++ b/src/lib/Bcfg2/Server/Reports/reports/models.py @@ -283,6 +283,8 @@ class Reason(models.Model): rv.append("Incorrect data") if self.unpruned: rv.append("Directory has extra files") + if len(rv) == 0: + rv.append("Exists") return rv @staticmethod diff --git a/src/lib/Bcfg2/Server/Reports/reports/templates/config_items/common.html b/src/lib/Bcfg2/Server/Reports/reports/templates/config_items/common.html index 02e53cff5..570ad645b 100644 --- a/src/lib/Bcfg2/Server/Reports/reports/templates/config_items/common.html +++ b/src/lib/Bcfg2/Server/Reports/reports/templates/config_items/common.html @@ -30,7 +30,7 @@ {{ entry.kind }} {{ entry.name }} {{ interaction|length }} - {{ reason.short_list|join:"," }} + {{ reason.short_list|join:"," }} {% endfor %} diff --git a/src/lib/Bcfg2/Server/Reports/reports/templates/config_items/listing.html b/src/lib/Bcfg2/Server/Reports/reports/templates/config_items/listing.html index f81325054..bc883098d 100644 --- a/src/lib/Bcfg2/Server/Reports/reports/templates/config_items/listing.html +++ b/src/lib/Bcfg2/Server/Reports/reports/templates/config_items/listing.html @@ -23,7 +23,7 @@ {{entry.name}} {{ eis|length }} - {{ reason.short_list|join:"," }} + {{ reason.short_list|join:"," }} {% endfor %} -- cgit v1.2.3-1-g7c22