Index: openacs-4/packages/download/www/index.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/download/www/index.tcl,v diff -u -N -r1.3 -r1.4 --- openacs-4/packages/download/www/index.tcl 16 May 2001 02:28:46 -0000 1.3 +++ openacs-4/packages/download/www/index.tcl 16 May 2001 09:41:05 -0000 1.4 @@ -8,6 +8,7 @@ {archive_type_id ""} {orderby "archive_name"} {query_string ""} + {updated ""} } -properties { title:onevalue description:onevalue @@ -28,12 +29,13 @@ set help_text $repository(help_text) #select the current list of archives -set type_dimlist {{"" "All" {}}} +set type_dimlist {} db_foreach archive_type { select archive_type_id as at_id, pretty_name from download_archive_types where repository_id = :repository_id } { lappend type_dimlist [list $at_id $pretty_name [list where "da.archive_type_id = $at_id"]] } +lappend type_dimlist {"" "all" {}} set dimensional [list \ {versions "Versions" current { @@ -42,9 +44,9 @@ }} \ [list archive_type_id "Type" "" $type_dimlist] \ {updated "Updated" all { - {1d "last 24hrs" {where "dar.publish_date + 1 > [db_map date_clause]"}} - {1w "last week" {where "dar.publish_date + 7 > [db_map date_clause]"}} - {1m "last month" {where "dar.publish_date + 30 > [db_map date_clause]"}} + {1d "last 24hrs" {where "[db_map date_clause_1]"}} + {1w "last week" {where "[db_map date_clause_7]"}} + {1m "last month" {where "[db_map date_clause_30]"}} {all "all" {}} }} \ ] @@ -61,12 +63,10 @@ set approval " and dar.approved_p = 't' " } -#FIXME fix the file size thing - set table_def { {archive_name "Software Name" {lower(archive_name) $order} - {  $archive_name $version_name  ([expr [cr_file_size $file_size] / 1024]k)
$summary}} + {  $archive_name $version_name  (${file_size}k)
$summary}} {archive_type "Software Type" {} {}} {downloads "# Downloads" {} {}} }