Index: openacs-4/packages/simulation/www/simbuild/template-edit.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/simulation/www/simbuild/template-edit.tcl,v diff -u -r1.17 -r1.18 --- openacs-4/packages/simulation/www/simbuild/template-edit.tcl 8 Jan 2004 12:34:28 -0000 1.17 +++ openacs-4/packages/simulation/www/simbuild/template-edit.tcl 9 Jan 2004 09:37:50 -0000 1.18 @@ -103,6 +103,15 @@ permission::require_permission -object_id $package_id -privilege sim_template_create } -on_submit { + set unique_p [simulation::template::pretty_name_unique_p \ + -package_id [ad_conn package_id] \ + -pretty_name $pretty_name] + + if { !$unique_p } { + form set_error sim_template pretty_name "This name is already used by another simulation" + break + } + set description_mime_type [template::util::richtext::get_property format $description] set description [template::util::richtext::get_property contents $description] } -new_data {