Index: openacs-4/packages/xowiki/tcl/adp-generator-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/xowiki/tcl/adp-generator-procs.tcl,v diff -u -r1.23 -r1.24 --- openacs-4/packages/xowiki/tcl/adp-generator-procs.tcl 14 Sep 2008 08:56:53 -0000 1.23 +++ openacs-4/packages/xowiki/tcl/adp-generator-procs.tcl 14 Sep 2008 17:19:54 -0000 1.24 @@ -191,7 +191,7 @@
+ summary="0" noparens="0"> Index: openacs-4/packages/xowiki/www/oacs-view.adp =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/xowiki/www/oacs-view.adp,v diff -u -r1.50 -r1.51 --- openacs-4/packages/xowiki/www/oacs-view.adp 14 Sep 2008 08:56:54 -0000 1.50 +++ openacs-4/packages/xowiki/www/oacs-view.adp 14 Sep 2008 17:19:54 -0000 1.51 @@ -1,4 +1,4 @@ - + @title;noquote@ @context;noquote@ Index: openacs-4/packages/xowiki/www/oacs-view2.adp =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/xowiki/www/oacs-view2.adp,v diff -u -r1.29 -r1.30 --- openacs-4/packages/xowiki/www/oacs-view2.adp 14 Sep 2008 08:56:54 -0000 1.29 +++ openacs-4/packages/xowiki/www/oacs-view2.adp 14 Sep 2008 17:19:54 -0000 1.30 @@ -1,4 +1,4 @@ - + @title;noquote@ @context;noquote@ @@ -100,7 +100,7 @@
+ summary="0" noparens="0"> Index: openacs-4/packages/xowiki/www/oacs-view3.adp =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/xowiki/www/oacs-view3.adp,v diff -u -r1.24 -r1.25 --- openacs-4/packages/xowiki/www/oacs-view3.adp 14 Sep 2008 08:56:54 -0000 1.24 +++ openacs-4/packages/xowiki/www/oacs-view3.adp 14 Sep 2008 17:19:54 -0000 1.25 @@ -1,4 +1,4 @@ - + @title;noquote@ @context;noquote@ Index: openacs-4/packages/xowiki/www/view-book-no-ajax.adp =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/xowiki/www/view-book-no-ajax.adp,v diff -u -r1.6 -r1.7 --- openacs-4/packages/xowiki/www/view-book-no-ajax.adp 14 Sep 2008 08:56:54 -0000 1.6 +++ openacs-4/packages/xowiki/www/view-book-no-ajax.adp 14 Sep 2008 17:19:54 -0000 1.7 @@ -1,4 +1,4 @@ - + @title;noquote@ @context;noquote@ Index: openacs-4/packages/xowiki/www/view-book.adp =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/xowiki/www/view-book.adp,v diff -u -r1.17 -r1.18 --- openacs-4/packages/xowiki/www/view-book.adp 14 Sep 2008 08:56:54 -0000 1.17 +++ openacs-4/packages/xowiki/www/view-book.adp 14 Sep 2008 17:19:54 -0000 1.18 @@ -1,4 +1,4 @@ - + @title;noquote@ @context;noquote@ Index: openacs-4/packages/xowiki/www/view-default.adp =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/xowiki/www/view-default.adp,v diff -u -r1.46 -r1.47 --- openacs-4/packages/xowiki/www/view-default.adp 14 Sep 2008 08:56:54 -0000 1.46 +++ openacs-4/packages/xowiki/www/view-default.adp 14 Sep 2008 17:19:54 -0000 1.47 @@ -1,4 +1,4 @@ - + @title;noquote@ @context;noquote@ Index: openacs-4/packages/xowiki/www/view-links.adp =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/xowiki/www/view-links.adp,v diff -u -r1.36 -r1.37 --- openacs-4/packages/xowiki/www/view-links.adp 14 Sep 2008 08:56:54 -0000 1.36 +++ openacs-4/packages/xowiki/www/view-links.adp 14 Sep 2008 17:19:54 -0000 1.37 @@ -1,4 +1,4 @@ - +
Index: openacs-4/packages/xowiki/www/view-plain.adp =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/xowiki/www/view-plain.adp,v diff -u -r1.32 -r1.33 --- openacs-4/packages/xowiki/www/view-plain.adp 14 Sep 2008 08:56:54 -0000 1.32 +++ openacs-4/packages/xowiki/www/view-plain.adp 14 Sep 2008 17:19:54 -0000 1.33 @@ -1,4 +1,4 @@ - +
Index: openacs-4/packages/xowiki/www/portlets/weblog-mini-calendar.adp =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/xowiki/www/portlets/weblog-mini-calendar.adp,v diff -u -r1.2 -r1.3 --- openacs-4/packages/xowiki/www/portlets/weblog-mini-calendar.adp 14 Sep 2008 08:59:17 -0000 1.2 +++ openacs-4/packages/xowiki/www/portlets/weblog-mini-calendar.adp 14 Sep 2008 17:19:54 -0000 1.3 @@ -1,4 +1,4 @@ - +
Index: openacs-4/packages/xowiki/www/portlets/weblog-mini-calendar.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/xowiki/www/portlets/weblog-mini-calendar.tcl,v diff -u -r1.12 -r1.13 --- openacs-4/packages/xowiki/www/portlets/weblog-mini-calendar.tcl 14 Sep 2008 15:40:15 -0000 1.12 +++ openacs-4/packages/xowiki/www/portlets/weblog-mini-calendar.tcl 14 Sep 2008 17:19:54 -0000 1.13 @@ -1,11 +1,3 @@ -# -# The following time range specifies the dates between the navigation -# arrows of the weblog mini calendar should be. Without a limitation, -# crawler will iterate over this pages until they reach infinite past -# or infinite future. -# -set earliest_date "2006-01-1" -set latest_date "1 year" ::xo::Page requireCSS "/resources/calendar/calendar.css" set package_id [::xo::cc package_id] @@ -50,39 +42,57 @@ set curr_month_idx [expr {[dt_trim_leading_zeros [clock format $now -format "%m"]]-1}] set curr_month [lindex $months_list $curr_month_idx ] -if {$prev_mon < [clock scan $earliest_date]} { - set prev_month_url "" -} else { - set prev_month [clock format $prev_mon -format "%Y-%m-%d"] - set prev_month_url [export_vars -base $base_url {{date $prev_month} page_num summary}] -} -if {$next_mon > [clock scan $latest_date]} { - set next_month_url "" -} else { - set next_month [clock format $next_mon -format "%Y-%m-%d"] - set next_month_url [export_vars -base $base_url {{date $next_month} page_num summary}] -} - set first_day_of_week [lc_get firstdayofweek] set week_days [lc_get abday] multirow create days_of_week day_short for {set i 0} {$i < 7} {incr i} { multirow append days_of_week [lindex $week_days [expr {($i + $first_day_of_week) % 7}]] } -db_foreach entries_this_month "select count(ci.item_id) as c, - [::xo::db::sql date_trunc day p.publish_date] as d \ - from xowiki_pagei p, cr_items ci \ +set innersql "from xowiki_pagei p, cr_items ci \ where ci.parent_id = $folder_id \ and ci.item_id = p.item_id and ci.live_revision = p.page_id \ - and ci.content_type not in ('::xowiki::PageTemplate') \ + and ci.content_type not in ('::xowiki::PageTemplate', '::xowiki::Form') \ and ci.item_id != $including_item_id \ - and ci.publish_status <> 'production' \ + and ci.publish_status <> 'production' " + +db_foreach entries_this_month "select count(ci.item_id) as c, + [::xo::db::sql date_trunc day p.publish_date] as d \ + $innersql and [::xo::db::sql date_trunc_expression month p.publish_date $year-$month-01] \ group by [::xo::db::sql date_trunc day p.publish_date]" { set entries([lindex $d 0]) $c } +# +# The following time range specifies the dates between the navigation +# arrows of the weblog mini calendar should be. Without a limitation, +# crawler will iterate over this pages until they reach infinite past +# or infinite future. +# +#set earliest_date "2006-01-1" +#set latest_date "1 year" +# +# Compute the available time range +# +set dates [db_list_of_lists get_dates "select min([::xo::db::sql date_trunc day p.publish_date]),max([::xo::db::sql date_trunc day p.publish_date]) $innersql"] +set earliest_date [::xo::db::tcl_date [lindex $dates 0 0] _] +set latest_date [::xo::db::::tcl_date [lindex $dates 0 end] _] + +if {$prev_mon < [clock scan $earliest_date]} { + set prev_month_url "" +} else { + set prev_month [clock format $prev_mon -format "%Y-%m-%d"] + set prev_month_url [export_vars -base $base_url {{date $prev_month} page_num summary}] +} +if {$next_mon > [clock scan $latest_date]} { + set next_month_url "" +} else { + set next_month [clock format $next_mon -format "%Y-%m-%d"] + set next_month_url [export_vars -base $base_url {{date $next_month} page_num summary}] +} + + multirow create days day_number beginning_of_week_p end_of_week_p today_p active_p url count class set day_of_week 1 @@ -134,7 +144,7 @@ # ns_log notice "--D julian_date = $julian_date [dt_julian_to_ansi $julian_date] //$ansi_date" set count [expr {[info exists entries($ansi_date)] ? - ([info exists noparens] ? $entries($ansi_date) : "($entries($ansi_date))") + ([info exists noparens] && $noparens ? $entries($ansi_date) : "($entries($ansi_date))") : ""}] if {$today_p} { set class today Index: openacs-4/packages/xowiki/www/resources/xowiki.css =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/xowiki/www/resources/xowiki.css,v diff -u -r1.31 -r1.32 --- openacs-4/packages/xowiki/www/resources/xowiki.css 10 Sep 2008 08:42:33 -0000 1.31 +++ openacs-4/packages/xowiki/www/resources/xowiki.css 14 Sep 2008 17:19:54 -0000 1.32 @@ -197,4 +197,21 @@ */ div.xowiki-content .margin-form .form-button, .margin-form div.form-help-text { color: #7A7A78; +} + +/* Make the weblog-mini-calendar slightly nicer by alignig its columns + and extending the width as it was with styles before zen. +*/ +.weblog-mini-calendar {width: 100%;} +.weblog-mini-calendar table {width: 100%;} +/* header of the calendar */ +.weblog-mini-calendar .back { text-align: left; } +.weblog-mini-calendar .current_view { text-align: center; } +.weblog-mini-calendar .forward { text-align: right; } +.weblog-mini-calendar .forward, .weblog-mini-calendar .back { + width: 20px; +} +/* the body-part of the calendar */ +.weblog-mini-calendar #at-a-glance td { + text-align: right; } \ No newline at end of file