Index: openacs-4/packages/file-storage/tcl/file-storage-procs.xql
===================================================================
RCS file: /usr/local/cvsroot/openacs-4/packages/file-storage/tcl/file-storage-procs.xql,v
diff -u -r1.10 -r1.11
--- openacs-4/packages/file-storage/tcl/file-storage-procs.xql 17 Sep 2002 21:03:26 -0000 1.10
+++ openacs-4/packages/file-storage/tcl/file-storage-procs.xql 18 Feb 2003 20:55:28 -0000 1.11
@@ -71,6 +71,28 @@
+
+
+
+ select *
+ from (select cr_items.item_id as object_id,
+ cr_items.name
+ from cr_items
+ where cr_items.parent_id = :folder_id
+ union all
+ select fs_simple_objects.object_id,
+ fs_simple_objects.name
+ from fs_simple_objects
+ where fs_simple_objects.folder_id = :folder_id) contents
+ where exists (select 1
+ from acs_object_party_privilege_map m
+ where m.object_id = contents.object_id
+ and m.party_id = :user_id
+ and m.privilege = 'read')
+
+
+
+
select count(*)