[Building Sakai] way to tell if current user has admin privileges?

Nicola Monat-Jacobs nicola at longsight.com
Wed Mar 31 10:49:32 PDT 2010


Ah, I think I should have been more specific. I'm working on a custom sakai tool, and I'm wondering if there is a java method to determine this? Many tools treat users enrolled in the admin workspace as though they were admin, so I imagine there must be some way to test for it.

Thanks,
Nicola

On Mar 31, 2010, at  10:43 AM, Noah Botimer wrote:

> Yes. Being in Admin Workspace is the magic and sole deciding factor. There should only be one role, so there shouldn't be any confusion there.
> 
> A way to check as the user would be to try to visit /portal/site/!admin. I'm sure we could come up with something programmatic/scriptable if you needed.
> 
> Thanks,
> -Noah
> 
> On Mar 31, 2010, at 1:36 PM, Nicola Monat-Jacobs wrote:
> 
>> I may be forgetting something obvious, but is there any easy way or method to tell if the current user has admin privileges? Not the 'admin' user, but a regular user who is enrolled in the Admin Workspace?
>> 
>> Thanks,
>> Nicola
>> _______________________________________________
>> sakai-dev mailing list
>> sakai-dev at collab.sakaiproject.org
>> http://collab.sakaiproject.org/mailman/listinfo/sakai-dev
>> 
>> TO UNSUBSCRIBE: send email to sakai-dev-unsubscribe at collab.sakaiproject.org with a subject of "unsubscribe"
>> 
>> 
> 



More information about the sakai-dev mailing list