[ Index ]
 

Code source de LifeType 1.2.4

Accédez au Source d'autres logiciels libres

Classes | Fonctions | Variables | Constantes | Tables

title

Body

[fermer]

/class/action/admin/ -> adminaction.class.php (sommaire)

(pas de description)

Poids: 309 lignes (11 kb)
Inclus ou requis:0 fois
Référencé: 6 fois
Nécessite: 0 fichiers

Définit 1 class

AdminAction:: (13 méthodes):
  AdminAction()
  _getBlogInfo()
  _getUserInfo()
  getLocale()
  setCommonData()
  saveSession()
  mustAuthenticatePage()
  notifyEvent()
  userHasPermission()
  canPerform()
  requirePermission()
  requireAdminPermission()
  getRequiredPermissions()


Classe: AdminAction  - X-Ref

\ingroup Action

In the same way BlogAction sets some predefined information to be available for every action
for the public side of the blog, this one does the same but for the administrative interface.
So far it fetches information from the session, such as the UserInfo and the BlogInfo objects
so that they are available for every template.

This is the most basic action for the admin interface and it allows all users to see them. If you
need to create an action that can only be accessed by users with certain privileges,
please use BlogOwnerAdminAction and SiteAdminAction.

AdminAction( $actionInfo, $request )   X-Ref
Constructor.

param: actionInfo An ActionInfo object as provided by the constroller
param: request A valid HTTP request

_getBlogInfo()   X-Ref
Retrieves the blogInfo object from the session


_getUserInfo()   X-Ref
Retrieves the userInfo object from the session


getLocale()   X-Ref
sets the default locale, in case we want to send localized messages to the user.


setCommonData( $copyFormValues = false )   X-Ref
Adds some common data to the view. this function must be manually called once
we've set up a view.

param: copyFormValues

saveSession()   X-Ref
Saves the session data


mustAuthenticatePage()   X-Ref
Generates a page which shows an "access forbidden" message, prompting the user to
authenticate first using the login page.


notifyEvent( $eventType, $params = Array()   X-Ref
centralized way of throwing events, it also adds some useful information so that
child classes do not have to do it

param: eventType
param: params

userHasPermission( $permName, $mode = BLOG_PERMISSION )   X-Ref
Returns true if the user has the requested permission (in the given mode)
or false otherwise

param: permName Name of the permission
param: mode Either BLOG_PERMISSION or ADMIN_PERMISSION, depending on whether

canPerform()   X-Ref
tbd


requirePermission( $perm, $mode = BLOG_PERMISSION )   X-Ref
This method should be called by action classes to specify
what kind of permission is required to execute the current action.

param: perm The name of the permission, given as a string
param: mode Either ADMIN_PERMISSION if the permission is an admin permission

requireAdminPermission( $perm )   X-Ref
Informs the action that the given admin permission is required

param: perm An admin permission

getRequiredPermissions()   X-Ref
tbd




Généré le : Mon Nov 26 21:04:15 2007 par Balluche grâce à PHPXref 0.7
  Clicky Web Analytics