Index: openacs-4/packages/ecommerce/lib/pagination-bar.adp
===================================================================
RCS file: /usr/local/cvsroot/openacs-4/packages/ecommerce/lib/pagination-bar.adp,v
diff -u
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ openacs-4/packages/ecommerce/lib/pagination-bar.adp 22 Dec 2008 12:33:24 -0000 1.1
@@ -0,0 +1 @@
+@prev_bar;noquote@ @current_bar@ @next_bar;noquote@
\ No newline at end of file
Index: openacs-4/packages/ecommerce/lib/pagination-bar.tcl
===================================================================
RCS file: /usr/local/cvsroot/openacs-4/packages/ecommerce/lib/pagination-bar.tcl,v
diff -u
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ openacs-4/packages/ecommerce/lib/pagination-bar.tcl 22 Dec 2008 12:33:24 -0000 1.1
@@ -0,0 +1,31 @@
+# generate list of lists for code in ecommerce/lib
+
+# @param base_url is url for page (required)
+# @param item_count (required)
+# @param items_per_page (required)
+# @param this_start_row (required) the start row for this page
+# @param separator is html used between page numbers, defaults to
+
+if { ![info exists separator] } {
+ set separator " "
+}
+
+set bar_list_set [ecds_pagination_by_items $item_count $items_per_page $this_start_row]
+set prev_bar $separator
+set next_bar $separator
+
+
+set prev_bar_list [lindex $bar_list_set 0]
+foreach {page_num start_row} $prev_bar_list {
+ lappend prev_bar " ${page_num} "
+}
+set prev_bar [join $prev_bar $separator]
+
+set current_bar_list [lindex $bar_list_set 1]
+set current_bar "[lindex $current_bar_list 0]"
+
+set next_bar_list [lindex $bar_list_set 2]
+foreach {page_num start_row} $next_bar_list {
+ append next_bar " ${page_num} "
+}
+set next_bar [join $next_bar $separator]