Index: openacs-4/packages/calendar/www/view-list-display.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/calendar/www/view-list-display.tcl,v diff -u -r1.25.2.2 -r1.25.2.3 --- openacs-4/packages/calendar/www/view-list-display.tcl 16 Aug 2006 17:20:33 -0000 1.25.2.2 +++ openacs-4/packages/calendar/www/view-list-display.tcl 20 Nov 2006 20:00:15 -0000 1.25.2.3 @@ -1,3 +1,13 @@ +if { ![info exists period_days] } { + ad_page_contract { + Some documentation. + @author Sven Schmitt (s.lrn@gmx.net) + @cvs-id $Id$ + } { + {period_days:integer {[parameter::get -parameter DefaultPeriodDays -default 31]}} + } +} + if {[info exists url_stub_callback]} { # This parameter is only set if this file is called from .LRN. # This way I make sure that for the time being this adp/tcl @@ -47,11 +57,7 @@ set calendars_clause [db_map dbqd.calendar.www.views.openacs_calendar] } -if { ![info exists period_days] } { - set period_days [parameter::get -parameter ListView_DefaultPeriodDays -default 31] -} else { - set end_date [clock format [clock scan "+${period_days} days" -base [clock scan $start_date]] -format "%Y-%m-%d 00:00"] -} +set end_date [clock format [clock scan "+${period_days} days" -base [clock scan $start_date]] -format "%Y-%m-%d 00:00"] set package_id [ad_conn package_id] set user_id [ad_conn user_id]