summaryrefslogtreecommitdiffstats
path: root/webui_templates/repo_list.tmpl
diff options
context:
space:
mode:
authorMichael DeHaan <mdehaan@redhat.com>2007-10-31 14:47:08 -0400
committerMichael DeHaan <mdehaan@redhat.com>2007-10-31 14:47:08 -0400
commitf187e7b9532ff6ad17091800161b19799f53f9cd (patch)
tree4c64d3cfbba9ca81f6573ac3965a033905b2c3a9 /webui_templates/repo_list.tmpl
parentca10be47466fb93f0d2db90975b51f6a0bd8162b (diff)
downloadthird_party-cobbler-f187e7b9532ff6ad17091800161b19799f53f9cd.tar.gz
third_party-cobbler-f187e7b9532ff6ad17091800161b19799f53f9cd.tar.xz
third_party-cobbler-f187e7b9532ff6ad17091800161b19799f53f9cd.zip
Add pagination HTML to all cobbler objects. Note that this really should be made modular
so we don't have to repeat this template code.
Diffstat (limited to 'webui_templates/repo_list.tmpl')
-rw-r--r--webui_templates/repo_list.tmpl31
1 files changed, 31 insertions, 0 deletions
diff --git a/webui_templates/repo_list.tmpl b/webui_templates/repo_list.tmpl
index 0aff65c..e363138 100644
--- a/webui_templates/repo_list.tmpl
+++ b/webui_templates/repo_list.tmpl
@@ -2,6 +2,37 @@
#attr $title = "Cobbler: List of Repositories"
#block body
+
+ ## ==== BEGIN PAGE NAVIGATION ====
+ #set what="repo"
+ Page:&nbsp;
+ #if $page != 0
+ #set $previous_page = $page - 1
+ <A HREF="${base_url}/${what}_list?page=${previous_page}&limit=${results_per_page}">&lt;</A>&nbsp;
+ #else
+ [
+ #end if
+
+ #for $this_page in range(0,$pages+1)
+ #if $this_page != $page
+ <A HREF="${base_url}/${what}_list?page=${this_page}&limit=${results_per_page}">${this_page}</A>&nbsp;
+ #else
+ ${this_page}
+ #end if
+ #end for
+
+ #if $page != $pages
+ #set $next_page = $page + 1
+ <A HREF="${base_url}/${what}_list?page=${next_page}&limit=${results_per_page}">&gt;</A>
+ #else
+ ]
+ #end if
+
+ <br/>
+ <br/>
+ ## ==== END PAGE NAVIGATION ====
+
+
<table class="sortable">
<thead>
<caption>Cobbler Repos</caption>