Index: openacs-4/packages/cms/www/modules/sitemap/delete-items-postgresql.xql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/cms/www/modules/sitemap/delete-items-postgresql.xql,v diff -u -r1.2 -r1.3 --- openacs-4/packages/cms/www/modules/sitemap/delete-items-postgresql.xql 27 May 2001 00:22:34 -0000 1.2 +++ openacs-4/packages/cms/www/modules/sitemap/delete-items-postgresql.xql 30 May 2001 22:56:27 -0000 1.3 @@ -3,10 +3,35 @@ postgresql7.1 - + + select + item_id, + coalesce(content_item__get_title(item_id,'f'),name) as title, + content_item__get_path(item_id, null) as path, + pretty_name as content_type_pretty, + content_symlink__is_symlink(item_id) as is_symlink, + content_folder__is_folder(item_id) as is_folder, + content_template__is_template(item_id) as is_template + from + cr_items i, acs_object_types t + where + i.content_type = t.object_type + and + item_id in ([join $clip_items ","]) + and + -- permissions check + cms_permission__permission_p( item_id, :user_id, 'cm_write' ) = 't' + order by + -- this way parents are deleted after their children + item_id desc + + + + + select $delete_proc ( :del_item_id