Index: openacs-4/packages/calendar/tcl/calendar-2-procs-postgresql.xql
===================================================================
RCS file: /usr/local/cvsroot/openacs-4/packages/calendar/tcl/Attic/calendar-2-procs-postgresql.xql,v
diff -u -r1.2 -r1.3
--- openacs-4/packages/calendar/tcl/calendar-2-procs-postgresql.xql 27 Oct 2003 12:16:22 -0000 1.2
+++ openacs-4/packages/calendar/tcl/calendar-2-procs-postgresql.xql 11 Dec 2003 21:39:59 -0000 1.3
@@ -7,11 +7,24 @@
select calendar_name,
calendar_id,
- acs_permission__permission_p(calendar_id, :user_id, 'calendar_admin') as calendar_admin_p
+ acs_permission__permission_p(calendar_id, :user_id, 'calendar_admin') as calendar_admin_p
from calendars
- where package_id= :package_id
- and (private_p='f' or (private_p='t' and owner_id= :user_id))
+ where (private_p = 'f' and package_id = :package_id $permissions_clause) or
+ (private_p = 't' and owner_id = :user_id)
+ order by private_p asc, upper(calendar_name)
+
+
+ and acs_permission__permission_p(calendar_id, :user_id, :privilege) = 't'
+
+
+
+
+
+ select calendar__delete(:calendar_id)
+
+
+