Index: openacs-4/packages/simulation/www/simbuild/task-delete.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/simulation/www/simbuild/task-delete.tcl,v diff -u -r1.3 -r1.3.2.1 --- openacs-4/packages/simulation/www/simbuild/task-delete.tcl 16 Dec 2003 18:34:00 -0000 1.3 +++ openacs-4/packages/simulation/www/simbuild/task-delete.tcl 30 Nov 2004 21:48:10 -0000 1.3.2.1 @@ -6,11 +6,20 @@ {return_url ""} } -set workflow_id [workflow::action::get_element -action_id $action_id -element workflow_id] +if { ![exists_and_not_null workflow_id] } { + set workflow_id [workflow::action::get_element \ + -action_id $action_id \ + -element workflow_id] +} + permission::require_write_permission -object_id $workflow_id simulation::action::edit -operation "delete" -action_id $action_id if { [empty_string_p $return_url] } { set return_url [export_vars -base template-edit { workflow_id }] } -ad_returnredirect $return_url + +# Let's mark this template edited +set sim_type "dev_template" + +ad_returnredirect [export_vars -base "template-sim-type-update" { workflow_id sim_type return_url }] \ No newline at end of file