acs_user::site_wide_admin_p (public)

 acs_user::site_wide_admin_p [ -user_id user_id ]

Defined in packages/acs-tcl/tcl/community-core-procs.tcl

Return 1 if the specified user (defaults to logged-in user) is site-wide administrator and 0 otherwise.

Switches:
-user_id (optional)
The id of the user to check for admin privilege.
Author:
Peter Marklund

Partial Call Graph (max 5 caller/called nodes):
%3 test_demote_promote_a_user demote_promote_a_user (test acs-tcl) acs_user::site_wide_admin_p acs_user::site_wide_admin_p test_demote_promote_a_user->acs_user::site_wide_admin_p acs_magic_object acs_magic_object (public) acs_user::site_wide_admin_p->acs_magic_object ad_conn ad_conn (public) acs_user::site_wide_admin_p->ad_conn permission::permission_p permission::permission_p (public) acs_user::site_wide_admin_p->permission::permission_p Object ::xo::api Object ::xo::api (public) Object ::xo::api->acs_user::site_wide_admin_p apm_application_new_checkbox apm_application_new_checkbox (public) apm_application_new_checkbox->acs_user::site_wide_admin_p notification::security::can_admin_request_p notification::security::can_admin_request_p (public) notification::security::can_admin_request_p->acs_user::site_wide_admin_p packages/acs-admin/lib/become.tcl packages/acs-admin/ lib/become.tcl packages/acs-admin/lib/become.tcl->acs_user::site_wide_admin_p packages/acs-admin/lib/service-parameters.tcl packages/acs-admin/ lib/service-parameters.tcl packages/acs-admin/lib/service-parameters.tcl->acs_user::site_wide_admin_p

Testcases:
demote_promote_a_user
Source code:
    if { $user_id eq ""} {
        set user_id [ad_conn user_id]
    }

    return [permission::permission_p -party_id $user_id  -object_id [acs_magic_object security_context_root]  -privilege "admin"]
Generic XQL file:
packages/acs-tcl/tcl/community-core-procs.xql

PostgreSQL XQL file:
packages/acs-tcl/tcl/community-core-procs-postgresql.xql

Oracle XQL file:
packages/acs-tcl/tcl/community-core-procs-oracle.xql

[ hide source ] | [ make this the default ]
Show another procedure: