django-helpdesk/templates/helpdesk/report_index.html
Ross Poulton 2a67f37577 Issue #125: If you have no tickets, the reports throw a 500 server error. This
patch removes the report links when there's no tickets in the system.

Thanks to Kestutis Gustaitis for the bug report.
2009-12-23 11:47:50 +00:00

36 lines
863 B
HTML

{% extends "helpdesk/base.html" %}{% load i18n %}
{% block helpdesk_title %}{% trans "Reports & Statistics" %}{% endblock %}
{% block helpdesk_body %}
{% ifequal num_tickets 0 %}{% blocktrans %}
<h2>Reports &amp; Statistics</h2>
<p>You haven't created any tickets yet, so you cannot run any reports.</p>
{% endblocktrans %}
{% else %}
{% blocktrans %}
<h2>Reports &amp; Statistics</h2>
<ul>
<li>User<ul>
<li><a href='userpriority/'>by Priority</a></li>
<li><a href='userqueue/'>by Queue</a></li>
<li><a href='userstatus/'>by Status</a></li>
<li><a href='usermonth/'>by Month</a></li>
</ul></li>
<li>Queue<ul>
<li><a href='queuepriority/'>by Priority</a></li>
<li><a href='queuestatus/'>by Status</a></li>
<li><a href='queuemonth/'>by Month</a></li>
</ul></li>
</ul>
{% endblocktrans %}{% endifequal %}{% endblock %}