diff options
author | Luke Shumaker <LukeShu@sbcglobal.net> | 2012-12-12 17:18:41 -0500 |
---|---|---|
committer | Luke Shumaker <LukeShu@sbcglobal.net> | 2012-12-12 17:18:41 -0500 |
commit | c0d6f0711c4760f08a6beb99818d075d7c993e2e (patch) | |
tree | e4a580d7b70181e9d5e36a8c438c63d0d7b63450 /templates/packages | |
parent | f286e9560e63a776397494899673b103f92f3198 (diff) | |
parent | 6ee65265a051933ee154c42490fdc509b9994202 (diff) |
Merge tag 'release_2012-03-12'
Signature stuff and template tweaks
Conflicts:
templates/public/index.html
Diffstat (limited to 'templates/packages')
-rw-r--r-- | templates/packages/search.html | 51 | ||||
-rw-r--r-- | templates/packages/search_paginator.html | 27 |
2 files changed, 30 insertions, 48 deletions
diff --git a/templates/packages/search.html b/templates/packages/search.html index 5bb90a52..e4de5bb6 100644 --- a/templates/packages/search.html +++ b/templates/packages/search.html @@ -6,6 +6,7 @@ {% block navbarclass %}anb-packages{% endblock %} {% block head %} +{% if is_paginated and page_obj.number > 1 %}<meta name="robots" content="noindex, nofollow"/>{% endif %} <link rel="stylesheet" type="text/css" href="{% admin_media_prefix %}css/widgets.css" /> {% endblock %} @@ -51,31 +52,7 @@ {% if package_list %} <div id="pkglist-results" class="box"> - - {% if paginator %} - <div id="pkglist-stats-top"> - - <p>{{paginator.count}} packages found. - Page {{page_obj.number}} of {{paginator.num_pages}}.</p> - - <p class="pkglist-nav"> - {% if page_obj.has_previous %} - <a class="prev" href="/packages/{{page_obj.previous_page_number}}/?{{current_query}}" - title="Go to previous page">< Prev</a> - {% else %} - <span class="prev">< Prev</span> - {% endif %} - {% if page_obj.has_next %} - <a class="next" href="/packages/{{page_obj.next_page_number}}/?{{current_query}}" - title="Go to next page">Next ></a> - {% else %} - <span class="next">Next ></span> - {% endif %} - </p> - - </div> - {% endif %} - + {% include "packages/search_paginator.html" %} <form id="pkglist-results-form" method="post" action="/packages/update/">{% csrf_token %} <table class="results"> @@ -120,29 +97,7 @@ {% endfor %} </tbody> </table> - - {% if paginator %} - <div id="pkglist-stats-bottom"> - - <p>{{paginator.count}} packages found. Page {{page_obj.number}} of {{paginator.num_pages}}.</p> - - <p class="pkglist-nav"> - {% if page_obj.has_previous %} - <a class="prev" href="/packages/{{page_obj.previous_page_number}}/?{{current_query}}" - title="Go to previous page">< Prev</a> - {% else %} - <span class="prev">< Prev</span> - {% endif %} - {% if page_obj.has_next %} - <a class="next" href="/packages/{{page_obj.next_page_number}}/?{{current_query}}" - title="Go to next page">Next ></a> - {% else %} - <span class="next">Next ></span> - {% endif %} - </p> - - </div> - {% endif %} + {% include "packages/search_paginator.html" %} {% if perms.main.change_package %} <p><input title="Adopt selected packages" type="submit" id="adopt-btn" diff --git a/templates/packages/search_paginator.html b/templates/packages/search_paginator.html new file mode 100644 index 00000000..362b7cb3 --- /dev/null +++ b/templates/packages/search_paginator.html @@ -0,0 +1,27 @@ +<div class="pkglist-stats"> + {% if is_paginated %} + <p>{{paginator.count}} packages found. + Page {{page_obj.number}} of {{paginator.num_pages}}.</p> + + <div class="pkglist-nav"> + <span class="prev"> + {% if page_obj.has_previous %} + <a href="/packages/{{page_obj.previous_page_number}}/?{{current_query}}" + title="Go to previous page">< Prev</a> + {% else %} + < Prev + {% endif %} + </span> + <span class="next"> + {% if page_obj.has_next %} + <a href="/packages/{{page_obj.next_page_number}}/?{{current_query}}" + title="Go to next page">Next ></a> + {% else %} + Next > + {% endif %} + </span> + </div> + {% else %} + <p>{{ package_list.count }} packages found.</p> + {% endif %} +</div> |