Please enable JavaScript to view this site.

The manual for the JobRouter developer

Navigation: Dashboard API > Methods and objects of the dashboard API > Usable methods

Verify whether user is admin (hasUserAdminRights)

Scroll Prev Top Next More

Please note: This method is outdated. Please use the method hasAdminRights on the ApiUser object instead.

This method verifies, if the logged in user has the administration right.

You can use this e.g. in the isAuthorized method to release a widget only for administrators.

Example:

public function isAuthorized()

{

    return $this->hasUserAdminRights();

}