Index: openacs-4/contrib/packages/bcms/tcl/bcms-folder-procs-postgresql.xql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/contrib/packages/bcms/tcl/bcms-folder-procs-postgresql.xql,v diff -u -r1.6 -r1.7 --- openacs-4/contrib/packages/bcms/tcl/bcms-folder-procs-postgresql.xql 3 Dec 2003 16:39:09 -0000 1.6 +++ openacs-4/contrib/packages/bcms/tcl/bcms-folder-procs-postgresql.xql 9 Feb 2004 14:29:20 -0000 1.7 @@ -50,7 +50,7 @@ - select content_folder__delete(:folder_id) + select content_folder__delete(:folder_id,:cascade_p) Index: openacs-4/contrib/packages/bcms/tcl/bcms-folder-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/contrib/packages/bcms/tcl/bcms-folder-procs.tcl,v diff -u -r1.12 -r1.13 --- openacs-4/contrib/packages/bcms/tcl/bcms-folder-procs.tcl 13 Nov 2003 14:24:38 -0000 1.12 +++ openacs-4/contrib/packages/bcms/tcl/bcms-folder-procs.tcl 9 Feb 2004 14:29:20 -0000 1.13 @@ -98,6 +98,7 @@ # for possible contribution - maybe we move this on CR's api ad_proc -public bcms::folder::delete_folder { {-folder_id:required} + {-cascade:boolean} } { deletes a cr_folder based from the folder_id @@ -122,6 +123,7 @@ {-name} {-label} {-parent_id} + {-description} } { set/edits the folder properties. @@ -148,7 +150,13 @@ if [info exists label] { db_dml edit_folder_label {} } + if [info exists description] { + db_dml edit_folder_desc {update cr_folders set description=:description} + } + ns_log notice "bcms::folder::set_folder updated $folder_id" + + } @@ -303,3 +311,14 @@ return [db_string select_folder_id_with_parent_id {} -default {}] } } + +ad_proc -public bcms::folder::content_types_select { + {-folder_id:required} +} { + Returns a list of lists of pretty name and content type + suitable for a form select widget +} { + + return [db_list_of_lists get_valid_types "select pretty_name, content_type from cr_folder_content_types where folder_id=:folder_id"] + +}