сlass User_Admin (Administrator or User with backend access)

The class is used to identify the current system administrator. It is inherited from class User and serves to expand the functionality.

class User_Admin extends User

{

/**
* Instantiate system administrator
* @return User_Admin
*/

static public function getInstance()

/**
* Get the list of modules with read access
* @return array
*/

public function getAvailableModules()

/**
* Check if the user has a permission to view the module data
* @param string $module
* @return boolean
*/

public function canView($module)

/**
* Check if the user has a permission to edit the module data
* @param string $module
* @return boolean
*/

public function canEdit($module)

/**
* Check if the user has a permission to remove the module data
* @param string $module
* @return boolean
*/

public function canDelete($module)

/**
* Check if the user has a permission to publish the module data
* @param string $module
* @return boolean
*/

public function canPublish($module)

}

comments powered by Disqus