Index: openacs-4/packages/calendar/www/view-week-display-postgresql.xql
===================================================================
RCS file: /usr/local/cvsroot/openacs-4/packages/calendar/www/view-week-display-postgresql.xql,v
diff -u -r1.10 -r1.11
--- openacs-4/packages/calendar/www/view-week-display-postgresql.xql 10 Jan 2004 00:20:38 -0000 1.10
+++ openacs-4/packages/calendar/www/view-week-display-postgresql.xql 12 Mar 2004 13:45:34 -0000 1.11
@@ -15,6 +15,37 @@
+
+
+select to_char(start_date, :ansi_date_format) as ansi_start_date,
+ to_char(end_date, :ansi_date_format) as ansi_end_date,
+ coalesce(e.name, a.name) as name,
+ coalesce(e.status_summary, a.status_summary) as status_summary,
+ e.event_id as item_id,
+ (to_date(start_date,:ansi_date_format) - to_date(:first_weekday_of_the_week_tz,
+ :ansi_date_format)) as day_of_week,
+ cals.calendar_id,
+ cals.calendar_name,
+ cit.type as item_type
+from acs_activities a,
+ acs_events e,
+ timespans s,
+ time_intervals t,
+ calendars cals,
+ cal_items ci left join
+ cal_item_types cit on cit.item_type_id = ci.item_type_id
+where e.timespan_id = s.timespan_id
+and s.interval_id = t.interval_id
+and e.activity_id = a.activity_id
+and start_date between
+ to_date(:first_weekday_of_the_week_tz, :ansi_date_format) and
+ to_date(:last_weekday_of_the_week_tz, :ansi_date_format)
+and cals.calendar_id = ci.on_which_calendar
+and e.event_id = ci.cal_item_id
+$calendars_clause
+order by to_char(start_date, 'J'), to_char(start_date,'HH24:MI')
+
+