Index: openacs-4/packages/proctoring-support/tcl/proctoring-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/proctoring-support/tcl/Attic/proctoring-procs.tcl,v diff -u -r1.1.2.6 -r1.1.2.7 --- openacs-4/packages/proctoring-support/tcl/proctoring-procs.tcl 20 Jan 2021 16:21:54 -0000 1.1.2.6 +++ openacs-4/packages/proctoring-support/tcl/proctoring-procs.tcl 16 Mar 2021 17:08:47 -0000 1.1.2.7 @@ -6,18 +6,33 @@ ad_proc ::proctoring::folder { -object_id:required - -user_id + {-user_id ""} } { Returns the proctoring folder on the system } { set folder [acs_root_dir]/proctoring/$object_id - if {[info exists user_id]} { + if {[string is integer -strict $user_id]} { append folder /$user_id } file mkdir $folder return $folder } +ad_proc ::proctoring::delete { + -object_id:required + {-user_id ""} +} { + Deletes the proctoring folder. When no user is specified, + proctoring files for the whole object will be deleted. + + @param user_id when specfied, only folder for this user will be + deleted. +} { + file delete -force -- [::proctoring::folder \ + -object_id $object_id \ + -user_id $user_id] +} + ad_proc ::proctoring::configure { -object_id:required {-enabled_p true}