Index: openacs-4/packages/lors-central/www/course-dotlrn-assoc.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/lors-central/www/course-dotlrn-assoc.tcl,v diff -u -r1.2 -r1.3 --- openacs-4/packages/lors-central/www/course-dotlrn-assoc.tcl 31 May 2005 22:57:22 -0000 1.2 +++ openacs-4/packages/lors-central/www/course-dotlrn-assoc.tcl 9 Jun 2005 21:03:16 -0000 1.3 @@ -25,7 +25,17 @@ set user_id [ad_conn user_id] +if { ![acs_user::site_wide_admin_p] } { + set extra_query_class "and drf.role = 'instructor' and drf.community_id = dc.class_instance_id and drf.user_id = :user_id " + set extra_query_community "and dm.community_id = dc.community_id + and dm.user_id = :user_id + and dm.role = 'admin'" +} else { + set extra_query_class "" + set extra_query_community "" +} + ##################################### TO ASSOCIATE ########################################################## db_multirow -extend { rel type } classes_list get_dotlrn_classes { } {