Index: openacs-4/packages/rules/www/delete-trigger.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/rules/www/Attic/delete-trigger.tcl,v diff -u -r1.1 -r1.2 --- openacs-4/packages/rules/www/delete-trigger.tcl 3 Dec 2004 17:56:54 -0000 1.1 +++ openacs-4/packages/rules/www/delete-trigger.tcl 10 Dec 2004 17:34:27 -0000 1.2 @@ -4,6 +4,22 @@ rule_def_id:integer,notnull,multiple rule_id:integer,notnull } +set package_id [ad_conn package_id] +set user_id [ad_conn user_id] +set context [list "Add rule"] +set rule_admin "" +set admin [permission::permission_p -object_id $package_id -party_id $user_id -privilege "admin"] +if { [exists_and_not_null rule_id] } { +set rule_admin [permission::permission_p -object_id $rule_id -party_id $user_id -privilege "admin"] +} + +if { $rule_admin == 0 && $admin == 0 } { + doc_return 200 text/html "