im_can_user_administer_group

one of the documented procedures in this installation of the ACS
Usage:
im_can_user_administer_group   db   { group_id "" }   { user_id "" }
What it does:
An intranet user can administer a given group if thery are a site-wide intranet user, a general site-wide administrator, or if they belong to the specified user group
Defined in: /web/philip/tcl/intranet-defs.tcl

Source code:


    if { [empty_string_p $user_id] } {
	set user_id [ad_get_user_id]
    }
    if { $user_id == 0 } {
	return 0
    }
    set site_wide_or_intranet_user [im_is_user_site_wide_or_intranet_admin $db $user_id] 
    
    if { $site_wide_or_intranet_user } {
	return 1
    }

    # Else, if the user is in the group with any role, s/he can administer that group
    return [database_to_tcl_string $db  "select decode(ad_group_member_p($user_id, $group_id), 't', 1, 0) from dual"]




philg@mit.edu