diff --git a/helpdesk/static/helpdesk/helpdesk-extend.css b/helpdesk/static/helpdesk/helpdesk-extend.css
index b1085b8d..ddc23fcb 100644
--- a/helpdesk/static/helpdesk/helpdesk-extend.css
+++ b/helpdesk/static/helpdesk/helpdesk-extend.css
@@ -29,11 +29,14 @@ Bootstrap overrides
#searchtabs {margin-bottom: 20px;}
-.row_tablehead {background-color: #dbd5d9;}
+.row_tablehead, table.table caption {background-color: #dbd5d9;}
+table.table caption {height: 2em; line-height: 2em; font-weight: bold;}
+table.ticket-stats caption {color: #fbff00; font-style: italic;}
+table.ticket-stats tbody th, table.ticket-stats tbody tr {padding-left: 20px}
-.errorlist {list-style: none; }
+.errorlist {list-style: none;}
.errorlist {padding: 0;}
-.has-error .input-group input, .has-error .input-group select, .has-error .input-group textarea {border-color: #b94a48}
+.has-error .input-group input, .has-error .input-group select, .has-error .input-group textarea {border-color: #b94a48}
#helpdesk-nav-collapse #searchform {
padding-top: 0;
diff --git a/helpdesk/static/helpdesk/hover.js b/helpdesk/static/helpdesk/hover.js
deleted file mode 100644
index 7b5b412a..00000000
--- a/helpdesk/static/helpdesk/hover.js
+++ /dev/null
@@ -1,7 +0,0 @@
-$(document).ready(function() {
- $("tr.row_hover").mouseover(function() {
- $(this).addClass("hover");
- }).mouseout(function() {
- $(this).removeClass("hover");
- });
-});
diff --git a/helpdesk/templates/helpdesk/dashboard.html b/helpdesk/templates/helpdesk/dashboard.html
index 2810c013..df65d793 100644
--- a/helpdesk/templates/helpdesk/dashboard.html
+++ b/helpdesk/templates/helpdesk/dashboard.html
@@ -1,141 +1,30 @@
-{% extends "helpdesk/base.html" %}{% load i18n humanize %}{% load url from future %}
+{% extends "helpdesk/base.html" %}{% load i18n %}
{% block helpdesk_title %}{% trans "Helpdesk Dashboard" %}{% endblock %}
-{% block helpdesk_head %}
-
-{% endblock %}
+
{% block helpdesk_body %}
{% trans "Welcome to your Helpdesk Dashboard! From here you can quickly see tickets submitted by you, tickets you are working on, and those tickets that have no owner." %}
-
-
-
-
-
-
-
-
-
-{% trans "Current Ticket Stats" %} |
-- {% trans "Average number of days until ticket is closed (all tickets): " %}{{ basic_ticket_stats.average_nbr_days_until_ticket_closed }}. |
-- {% trans "Average number of days until ticket is closed (tickets opened in last 60 days): " %}{{ basic_ticket_stats.average_nbr_days_until_ticket_closed_last_60_days }}.
-{% trans "Click" %} here {% trans "for detailed average by month." %} |
-- {% trans "Distribution of open tickets, grouped by time period:" %} |
-{% trans "Days since opened" %} | {% trans "Number of open tickets" %} |
-
-
-{% for entry in basic_ticket_stats.open_ticket_stats %}
-
-{{ entry.0 }} |
-{% if entry.1 > 0 %}{{ entry.1 }}{% else %}{{ entry.1 }}{% endif %} |
-
-{% endfor %}
-
-
+{% include 'helpdesk/include/summary.html' %}
+{% include 'helpdesk/include/stats.html' %}
{% if all_tickets_reported_by_current_user %}
-
-
-{% trans "All Tickets submitted by you" %} |
-# | {% trans "Pr" %} | {% trans "Title" %} | {% trans "Queue" %} | {% trans "Status" %} | {% trans "Last Update" %} |
-
-
-{% for ticket in all_tickets_reported_by_current_user %}
-
-{{ ticket.ticket }} |
-{{ ticket.get_priority_span }} |
-{{ ticket.title }} |
-{{ ticket.queue }} |
-{{ ticket.get_status }} |
-{{ ticket.modified|naturaltime }} |
-
-{% endfor %}
-
-
+{% trans "All Tickets submitted by you" as ticket_list_caption %}
+{% include 'helpdesk/include/tickets.html' with ticket_list=all_tickets_reported_by_current_user ticket_list_empty_message="" %}
{% endif %}
-
-
-{% trans "Open Tickets assigned to you (you are working on this ticket)" %} |
-# | {% trans "Pr" %} | {% trans "Title" %} | {% trans "Queue" %} | {% trans "Status" %} | {% trans "Last Update" %} |
-
-
-{% for ticket in user_tickets %}
-
-{{ ticket.ticket }} |
-{{ ticket.get_priority_span }} |
-{{ ticket.title }} |
-{{ ticket.queue }} |
-{{ ticket.get_status }} |
-{{ ticket.modified|naturaltime }} |
-
-{% endfor %}
-{% if not user_tickets %}
-{% trans "You have no tickets assigned to you." %} |
-{% endif %}
-
-
-
-
-
-{% trans "Unassigned Tickets" %} {% trans "(pick up a ticket if you start to work on it)" %} |
-# | {% trans "Pr" %} | {% trans "Title" %} | {% trans "Queue" %} | {% trans "Created" %} | |
-
-
-{% for ticket in unassigned_tickets %}
-
-{{ ticket.ticket }} |
-{{ ticket.get_priority_span }} |
-{{ ticket.title }} |
-{{ ticket.queue }} |
-{{ ticket.created|naturaltime }} |
-{% trans "Take" %} | {% trans "Delete" %} |
-
-{% endfor %}
-{% if not unassigned_tickets %}
-{% trans "There are no unassigned tickets." %} |
-{% endif %}
-
-
+{% trans "Open Tickets assigned to you (you are working on this ticket)" as ticket_list_caption %}
+{% trans "You have no tickets assigned to you." as no_assigned_tickets %}
+{% include 'helpdesk/include/tickets.html' with ticket_list=user_tickets ticket_list_empty_message=no_assigned_tickets %}
+{% include 'helpdesk/include/unassigned.html' %}
{% if user_tickets_closed_resolved %}
-
-
-{% trans "Closed & resolved Tickets you used to work on" %} |
-# | {% trans "Pr" %} | {% trans "Title" %} | {% trans "Queue" %} | {% trans "Status" %} | {% trans "Last Update" %} |
-
-
-{% for ticket in user_tickets_closed_resolved %}
-
-{{ ticket.ticket }} |
-{{ ticket.get_priority_span }} |
-{{ ticket.title }} |
-{{ ticket.queue }} |
-{{ ticket.get_status }} |
-{{ ticket.modified|naturaltime }} |
-
-{% endfor %}
-
-
+{% trans "Closed & resolved Tickets you used to work on" as ticket_list_caption %}
+{% include 'helpdesk/include/tickets.html' with ticket_list=user_tickets_closed_resolved ticket_list_empty_message="" %}
{% endif %}
{% endblock %}
diff --git a/helpdesk/templates/helpdesk/email_ignore_list.html b/helpdesk/templates/helpdesk/email_ignore_list.html
index 2451e082..80d30c1d 100644
--- a/helpdesk/templates/helpdesk/email_ignore_list.html
+++ b/helpdesk/templates/helpdesk/email_ignore_list.html
@@ -8,9 +8,9 @@
The following e-mail addresses are currently being ignored by the incoming e-mail processor. You can add a new e-mail address to the list or delete any of the items below as required.
{% endblocktrans %}
+{% trans "Ignored E-Mail Addresses" %}
-{% trans "Ignored E-Mail Addresses" %} |
-{% trans "Name" %} | {% trans "E-Mail Address" %} | {% trans "Date Added" %} | {% trans "Queues" %} | {% trans "Keep in mailbox?" %} | {% trans "Delete" %} |
+{% trans "Name" %} | {% trans "E-Mail Address" %} | {% trans "Date Added" %} | {% trans "Queues" %} | {% trans "Keep in mailbox?" %} | {% trans "Delete" %} |
{% for ignore in ignore_list %}
@@ -18,7 +18,7 @@
{{ ignore.name }} |
{{ ignore.email_address }} |
{{ ignore.date }} |
- {% for queue in ignore.queues.all %}{{ queue.slug }}{% if not forloop.last %}, {% endif %}{% endfor %}{% if not ignore.queues.all %}{% trans "All" %}{% endif %} |
+ {% for queue in ignore.queues.all %}{{ queue.slug }}{% if not forloop.last %}, {% endif %}{% empty %}{% trans "All" %}{% endfor %} |
{% if ignore.keep_in_mailbox %}{% trans "Keep" %}{% endif %} |
{% trans "Delete" %} |
diff --git a/helpdesk/templates/helpdesk/include/stats.html b/helpdesk/templates/helpdesk/include/stats.html
new file mode 100644
index 00000000..40af217b
--- /dev/null
+++ b/helpdesk/templates/helpdesk/include/stats.html
@@ -0,0 +1,19 @@
+{% load i18n %}{% load url from future %}
+
+{% trans "Current Ticket Stats" %}
+
+- {% trans "Average number of days until ticket is closed (all tickets): " %}{{ basic_ticket_stats.average_nbr_days_until_ticket_closed }}. |
+- {% trans "Average number of days until ticket is closed (tickets opened in last 60 days): " %}{{ basic_ticket_stats.average_nbr_days_until_ticket_closed_last_60_days }}.
+{% trans "Click" %} here {% trans "for detailed average by month." %} |
+- {% trans "Distribution of open tickets, grouped by time period:" %} |
+{% trans "Days since opened" %} | {% trans "Number of open tickets" %} |
+
+
+{% for entry in basic_ticket_stats.open_ticket_stats %}
+
+{{ entry.0 }} |
+{% if entry.1 > 0 %}{{ entry.1 }}{% else %}{{ entry.1 }}{% endif %} |
+
+{% endfor %}
+
+
\ No newline at end of file
diff --git a/helpdesk/templates/helpdesk/include/summary.html b/helpdesk/templates/helpdesk/include/summary.html
new file mode 100644
index 00000000..8f1d308b
--- /dev/null
+++ b/helpdesk/templates/helpdesk/include/summary.html
@@ -0,0 +1,17 @@
+{% load i18n %}
+
\ No newline at end of file
diff --git a/helpdesk/templates/helpdesk/include/tickets.html b/helpdesk/templates/helpdesk/include/tickets.html
new file mode 100644
index 00000000..410711ea
--- /dev/null
+++ b/helpdesk/templates/helpdesk/include/tickets.html
@@ -0,0 +1,21 @@
+{% load i18n humanize %}{% load url from future %}
+{% if ticket_list_caption %}
+{{ ticket_list_caption }}{% endif %}
+
+# | {% trans "Pr" %} | {% trans "Title" %} | {% trans "Queue" %} | {% trans "Status" %} | {% trans "Last Update" %} |
+
+
+{% for ticket in ticket_list %}
+
+{{ ticket.ticket }} |
+{{ ticket.get_priority_span }} |
+{{ ticket.title }} |
+{{ ticket.queue }} |
+{{ ticket.get_status }} |
+{{ ticket.modified|naturaltime }} |
+
+{% empty %}{% if ticket_list_empty_message %}
+{{ ticket_list_empty_message }} |
+{% endif %}{% endfor %}
+
+
\ No newline at end of file
diff --git a/helpdesk/templates/helpdesk/include/unassigned.html b/helpdesk/templates/helpdesk/include/unassigned.html
new file mode 100644
index 00000000..3053e31b
--- /dev/null
+++ b/helpdesk/templates/helpdesk/include/unassigned.html
@@ -0,0 +1,21 @@
+{% load i18n humanize %}{% load url from future %}
+
+{% trans "Unassigned Tickets" %} {% trans "(pick up a ticket if you start to work on it)" %}
+
+# | {% trans "Pr" %} | {% trans "Title" %} | {% trans "Queue" %} | {% trans "Created" %} | |
+
+
+{% for ticket in unassigned_tickets %}
+
+{{ ticket.ticket }} |
+{{ ticket.get_priority_span }} |
+{{ ticket.title }} |
+{{ ticket.queue }} |
+{{ ticket.created|naturaltime }} |
+{% trans "Take" %} | {% trans "Delete" %} |
+
+{% empty %}
+{% trans "There are no unassigned tickets." %} |
+{% endfor %}
+
+
\ No newline at end of file
diff --git a/helpdesk/templates/helpdesk/kb_category.html b/helpdesk/templates/helpdesk/kb_category.html
index 583d8680..d304f5ad 100644
--- a/helpdesk/templates/helpdesk/kb_category.html
+++ b/helpdesk/templates/helpdesk/kb_category.html
@@ -7,15 +7,15 @@
{{ category.description }}
-
+
+{% blocktrans with category.title as kbcat %}Knowledgebase Category: {{ kbcat }}{% endblocktrans %}
-{% blocktrans with category.title as kbcat %}Knowledgebase Category: {{ kbcat }}{% endblocktrans %} |
-{% trans "Article" %} |
+{% trans "Article" %} |
{% for item in items %}
-{{ item.title }} | Rating: {{ item.score }} | Last Update: {{ item.last_updated|naturaltime }} |
-{{ item.question }} |
+{{ item.title }} | Rating: {{ item.score }} | Last Update: {{ item.last_updated|naturaltime }} |
+{{ item.question }} |
{% endfor %}
diff --git a/helpdesk/templates/helpdesk/kb_index.html b/helpdesk/templates/helpdesk/kb_index.html
index 30f1143b..8143d91f 100644
--- a/helpdesk/templates/helpdesk/kb_index.html
+++ b/helpdesk/templates/helpdesk/kb_index.html
@@ -5,15 +5,15 @@
{% trans "We have listed a number of knowledgebase articles for your perusal in the following categories. Please check to see if any of these articles address your problem prior to opening a support ticket." %}
-
+
+{% trans "Knowledgebase Categories" %}
-{% trans "Knowledgebase Categories" %} |
-{% trans "Category" %} |
+{% trans "Category" %} |
{% for category in kb_categories %}
-{{ category.title }} |
-{{ category.description }} |
+{{ category.title }} |
+{{ category.description }} |
{% endfor %}
diff --git a/helpdesk/templates/helpdesk/kb_item.html b/helpdesk/templates/helpdesk/kb_item.html
index b44c3169..57552bcf 100644
--- a/helpdesk/templates/helpdesk/kb_item.html
+++ b/helpdesk/templates/helpdesk/kb_item.html
@@ -3,13 +3,11 @@
{% block helpdesk_body %}
{% blocktrans with item.title as item %}Knowledgebase: {{ item }}{% endblocktrans %}
-