Open Journal Systems  2.4.4
 All Classes Namespaces Functions Variables Groups Pages
PKPAnnouncementHandler Class Reference
Inheritance diagram for PKPAnnouncementHandler:
ManagerHandler Handler Handler PKPHandler PKPHandler AnnouncementHandler AnnouncementHandler

Public Member Functions

 _announcementIsValid (&$request, $announcementId)
 
_getAnnouncements ($request, $rangeInfo=null)
 
_getAnnouncements ($request, $rangeInfo=null)
 
 _getAnnouncementsEnabled ($request)
 
 _getAnnouncementsIntroduction ($request)
 
 announcements ($args, &$request)
 
 announcementTypes ($args, &$request)
 
 createAnnouncement ($args, &$request)
 
 createAnnouncementType ($args, &$request)
 
 deleteAnnouncement ($args, &$request)
 
 deleteAnnouncementType ($args, $request)
 
 editAnnouncement ($args, &$request)
 
 editAnnouncementType ($args, &$request)
 
 getContextId ($request)
 
 index ($args, &$request)
 
 setupTemplate ($request, $subclass=false)
 
 setupTemplate (&$request, $subclass=false)
 
 updateAnnouncement ($args, &$request)
 
 updateAnnouncementType ($args, &$request)
 
 view ($args, &$request)
 
- Public Member Functions inherited from ManagerHandler
 email ($args)
 
 index ()
 
 ManagerHandler ()
 
retrieveRoleAssignmentPreferences ($journalId)
 
 setupTemplate ($subclass=false)
 
- Public Member Functions inherited from PKPHandler
 addCheck (&$handlerValidator)
 
 addPolicy (&$authorizationPolicy, $addToTop=false)
 
 addRoleAssignment ($roleIds, $operations)
 
 authorize (&$request, &$args, $roleAssignments)
 
getAuthorizedContext ()
 
getAuthorizedContextObject ($assocType)
 
getDispatcher ()
 
 getId ()
 
 getLastAuthorizationMessage ()
 
 getLoginExemptions ()
 
getRangeInfo ($rangeName, $contextData=null)
 
 getRoleAssignment ($roleId)
 
 getRoleAssignments ()
 
 hashPageContext ($contextData=array())
 
 index ()
 
 initialize (&$request, $args=null)
 
 PKPHandler ()
 
 requireSSL ()
 
 setDispatcher (&$dispatcher)
 
 setId ($id)
 
 validate ($requiredContexts=null, $request=null)
 

Detailed Description

Handle requests for public announcement functions.

Definition at line 18 of file announcement/PKPAnnouncementHandler.inc.php.

Member Function Documentation

PKPAnnouncementHandler::_announcementIsValid ( $request,
  $announcementId 
)

Checks whether the given announcement is valid for display.

Parameters
$announcementIdinteger

Definition at line 134 of file announcement/PKPAnnouncementHandler.inc.php.

Referenced by deleteAnnouncement(), editAnnouncement(), updateAnnouncement(), and view().

& PKPAnnouncementHandler::_getAnnouncements (   $request,
  $rangeInfo = null 
)

Get the announcements for this request.

Parameters
$requestPKPRequest
$rangeInfoObject optional
Returns
ItemIterator

Definition at line 59 of file manager/PKPAnnouncementHandler.inc.php.

& PKPAnnouncementHandler::_getAnnouncements (   $request,
  $rangeInfo = null 
)

Returns a list of (non-expired) announcements for this context.

Parameters
$requestPKPRequest
$rangeInfoDBResultRange
Returns
DAOResultFactory

Definition at line 113 of file announcement/PKPAnnouncementHandler.inc.php.

Referenced by announcements(), and index().

PKPAnnouncementHandler::_getAnnouncementsEnabled (   $request)

Returns true when announcements are enabled in the context, otherwise false.

Parameters
$requestPKPRequest
Returns
boolean

Definition at line 101 of file announcement/PKPAnnouncementHandler.inc.php.

Referenced by index(), and view().

PKPAnnouncementHandler::_getAnnouncementsIntroduction (   $request)

Returns an introductory text to be displayed with the announcements.

Parameters
$requestPKPRequest
Returns
string

Definition at line 124 of file announcement/PKPAnnouncementHandler.inc.php.

Referenced by index().

PKPAnnouncementHandler::announcements (   $args,
$request 
)

Display a list of announcements for the current context.

Parameters
$argsarray
$requestPKPRequest

Definition at line 33 of file manager/PKPAnnouncementHandler.inc.php.

References _getAnnouncements(), PKPHandler\getRangeInfo(), setupTemplate(), and PKPHandler\validate().

PKPAnnouncementHandler::announcementTypes (   $args,
$request 
)

Display a list of announcement types for the current context.

Parameters
$argsarray
$requestPKPRequest

Definition at line 203 of file manager/PKPAnnouncementHandler.inc.php.

References PKPHandler\getRangeInfo(), setupTemplate(), and PKPHandler\validate().

PKPAnnouncementHandler::createAnnouncement (   $args,
$request 
)

Display form to create new announcement.

Definition at line 140 of file manager/PKPAnnouncementHandler.inc.php.

References editAnnouncement().

PKPAnnouncementHandler::createAnnouncementType (   $args,
$request 
)

Display form to create new announcement type.

Parameters
$argsarray
$requestPKPRequest

Definition at line 293 of file manager/PKPAnnouncementHandler.inc.php.

References editAnnouncementType().

PKPAnnouncementHandler::deleteAnnouncement (   $args,
$request 
)

Delete an announcement.

Parameters
$argsarray first parameter is the ID of the announcement to delete

Definition at line 68 of file manager/PKPAnnouncementHandler.inc.php.

References _announcementIsValid(), DAORegistry\getDAO(), and PKPHandler\validate().

PKPAnnouncementHandler::deleteAnnouncementType (   $args,
  $request 
)

Delete an announcement type.

Parameters
$argsarray first parameter is the ID of the announcement type to delete
$requestPKPRequest

Definition at line 227 of file manager/PKPAnnouncementHandler.inc.php.

References DAORegistry\getDAO(), and PKPHandler\validate().

PKPAnnouncementHandler::editAnnouncement (   $args,
$request 
)

Display form to edit an announcement.

Parameters
$argsarray first parameter is the ID of the announcement to edit
$requestPKPRequest

Definition at line 94 of file manager/PKPAnnouncementHandler.inc.php.

References _announcementIsValid(), getContextId(), DAORegistry\getDAO(), setupTemplate(), and PKPHandler\validate().

Referenced by createAnnouncement().

PKPAnnouncementHandler::editAnnouncementType (   $args,
$request 
)

Display form to edit an announcement type.

Parameters
$argsarray first parameter is the ID of the announcement type to edit
$requestPKPRequest

Definition at line 252 of file manager/PKPAnnouncementHandler.inc.php.

References DAORegistry\getDAO(), setupTemplate(), and PKPHandler\validate().

Referenced by createAnnouncementType().

PKPAnnouncementHandler::getContextId (   $request)

Get the current context id in request.

Parameters
$requestPKPRequest
Returns
int or null

Definition at line 366 of file manager/PKPAnnouncementHandler.inc.php.

Referenced by editAnnouncement(), and updateAnnouncement().

PKPAnnouncementHandler::index (   $args,
$request 
)
PKPAnnouncementHandler::setupTemplate (   $request,
  $subclass = false 
)

Setup common template variables.

Parameters
$requestPKPRequest
$subclassboolean set to true if caller is below this handler in the hierarchy

Definition at line 87 of file announcement/PKPAnnouncementHandler.inc.php.

Referenced by announcements(), announcementTypes(), editAnnouncement(), editAnnouncementType(), index(), updateAnnouncement(), updateAnnouncementType(), and view().

PKPAnnouncementHandler::setupTemplate ( $request,
  $subclass = false 
)

Set up the template with breadcrumbs etc.

Parameters
$requestPKPRequest
$subclassboolean

Definition at line 349 of file manager/PKPAnnouncementHandler.inc.php.

PKPAnnouncementHandler::updateAnnouncement (   $args,
$request 
)

Save changes to an announcement.

Parameters
$requestPKPRequest

Definition at line 148 of file manager/PKPAnnouncementHandler.inc.php.

References _announcementIsValid(), getContextId(), DAORegistry\getDAO(), setupTemplate(), and PKPHandler\validate().

PKPAnnouncementHandler::updateAnnouncementType (   $args,
$request 
)

Save changes to an announcement type.

Parameters
$argsarray
$requestPKPRequest

Definition at line 302 of file manager/PKPAnnouncementHandler.inc.php.

References DAORegistry\getDAO(), setupTemplate(), and PKPHandler\validate().

PKPAnnouncementHandler::view (   $args,
$request 
)

View announcement details.

Parameters
$argsarray first parameter is the ID of the announcement to display
$requestPKPRequest

Definition at line 54 of file announcement/PKPAnnouncementHandler.inc.php.

References _announcementIsValid(), _getAnnouncementsEnabled(), DAORegistry\getDAO(), setupTemplate(), and PKPHandler\validate().


The documentation for this class was generated from the following files: