bloodhound-trac / trac / ticket / templates / report_list.html

Full commit
<!DOCTYPE html
    PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
<html xmlns=""
  <xi:include href="layout.html" />
    <title>Available Reports</title>
    <script type="text/javascript" src="${chrome.htdocs_location}js/folding.js"></script>
    <script type="text/javascript">
        $("#trac-toggle-description").click(function() {
          if ($(this).checked())

    <div id="content" class="report">

      <h1>Available Reports</h1>

      <form id="prefs" method="get" action="">
          <input id="trac-toggle-description" type="checkbox" />
          <label for="trac-toggle-description">Show Descriptions</label>

      <div id="description" />

      <div py:choose="" class="reports">
        <div py:if="saved_query_href">
          <form method="get" action="${}">
            <div class="inlinebuttons">
              <input type="hidden" name="action" value="clear" />
              <input type="submit" class="inlinebutton" title="Forget last query" value="${_('Clear')}" />
          <h2><a href="$saved_query_href"><em>Return to Last Query</em></a></h2>
          <span class="foldable" />
          <div class="description">
            <p>Continue browsing through the current list of results,
              from the last selected report or custom query.</p>

        <div py:if="query_href">
          <h2><a href="$query_href"><em>Custom Query</em></a></h2>
          <span class="foldable" />
          <div class="description">
            <p>Compose a new ticket query by selecting filters and columns to display.</p>

        <py:when test="reports">
          <h2>SQL reports and saved custom queries
            <span id="trac-sort-order" py:with="report_asc = asc if sort == 'report' else None;
                                                title_asc = asc if sort == 'title' else None">
              Sort by:
              <a href="${'report', asc='0' if report_asc else '1')}"
                 class="${('desc', 'asc')[report_asc] if report_asc is not None else None}">
              <a href="${'title', asc='0' if title_asc else '1')}"
                 class="${('desc', 'asc')[title_asc] if title_asc is not None else None}">

          <div py:for="id, title, description, can_edit, can_delete in reports">
            <form py:if="can_delete" method="get" action="${}">
              <div class="inlinebuttons">
                <input type="hidden" name="action" value="delete" />
                <input type="submit" class="inlinebutton" title="Delete report" value="${_('Delete')}" />
            <form py:if="can_edit" method="get" action="${}">
              <div class="inlinebuttons">
                <input type="hidden" name="action" value="edit" />
                <input type="submit" class="inlinebutton" title="Edit report" value="${_('Edit')}" />
            <h2><a title="View report" href="${}">{$id} <em>$title</em></a></h2>
            <span class="foldable" />
            <div py:if="description" class="description" xml:space="preserve">
              ${wiki_to_html(context, description)}
        <p py:otherwise="">No reports available.</p>

      <div py:if="'REPORT_CREATE' in perm" class="buttons">
        <form action="" method="get" id="create_report">
            <input type="hidden" name="action" value="new" />
            <input type="submit" value="${_('Create new report')}" />

      <div id="help" i18n:msg="">
        See <a href="${'TracReports')}">TracReports</a> for help on using and creating reports.