Open Journal Systems  3.3.0
IssueHandler Class Reference
Inheritance diagram for IssueHandler:
APIHandler PKPHandler

Public Member Functions

 __construct ()
 
 archive ($args, $request)
 
 authorize ($request, &$args, $roleAssignments)
 
 authorize ($request, &$args, $roleAssignments)
 
 current ($args, $request)
 
 download ($args, $request)
 
 get ($slimRequest, $response, $args)
 
 getCurrent ($slimRequest, $response, $args)
 
 getGalley ()
 
 getMany ($slimRequest, $response, $args)
 
 index ($args, $request)
 
 initialize ($request, $args=array())
 
 setGalley ($galley)
 
 setupTemplate ($request)
 
 userCanViewGalley ($request)
 
 view ($args, $request)
 
- Public Member Functions inherited from APIHandler
 convertStringsToSchema ($schema, $params)
 
 getApp ()
 
 getEndpointPattern ()
 
 getEndpoints ()
 
 getEntityId ($parameterName)
 
 getParameter ($parameterName, $default=null)
 
 getRequest ()
 
 getSlimRequest ()
 
 setSlimRequest ($slimRequest)
 
 setupEndpoints ()
 
- Public Member Functions inherited from PKPHandler
 addPolicy ($authorizationPolicy, $addToTop=false)
 
 addRoleAssignment ($roleIds, $operations)
 
 getApiToken ()
 
getAuthorizedContext ()
 
getAuthorizedContextObject ($assocType)
 
getDispatcher ()
 
 getFirstUserContext ($user, $contexts)
 
 getId ()
 
 getLastAuthorizationMessage ()
 
 getRoleAssignment ($roleId)
 
 getRoleAssignments ()
 
 getSiteRedirectContext ($request)
 
 getTargetContext ($request, &$contextsCount=null)
 
 initialize ($request)
 
 markRoleAssignmentsChecked ()
 
 requireSSL ()
 
 setApiToken ($apiToken)
 
 setDispatcher ($dispatcher)
 
 setEnforceRestrictedSite ($enforceRestrictedSite)
 
 setId ($id)
 
 validate ($requiredContexts=null, $request=null)
 

Static Public Member Functions

static _setupIssueTemplate ($request, $issue, $showToc=false)
 
- Static Public Member Functions inherited from PKPHandler
static getPageParamName ($rangeName)
 
static getRangeInfo ($request, $rangeName, $contextData=null)
 
static hashPageContext ($request, $contextData=array())
 

Data Fields

 $_galley = null
 
- Data Fields inherited from PKPHandler
 $_authorizationDecisionManager
 
 $_checks = array()
 
 $_dispatcher
 
 $_enforceRestrictedSite = true
 
 $_id
 
 $_isBackendPage = false
 
 $_roleAssignments = array()
 
 $_roleAssignmentsChecked = false
 

Additional Inherited Members

- Protected Member Functions inherited from APIHandler
 _validateStatDates ($params, $dateStartParam='dateStart', $dateEndParam='dateEnd')
 
- Protected Attributes inherited from APIHandler
 $_app
 
 $_endpoints = array()
 
 $_handlerPath = null
 
 $_pathPattern
 
 $_request
 
 $_slimRequest = null
 
- Protected Attributes inherited from PKPHandler
 $_apiToken = null
 

Detailed Description

Handle API requests for issues operations.

Handle requests for issue functions.

Definition at line 20 of file api/v1/issues/IssueHandler.inc.php.

Constructor & Destructor Documentation

◆ __construct()

IssueHandler::__construct ( )

Constructor

Reimplemented from APIHandler.

Definition at line 25 of file api/v1/issues/IssueHandler.inc.php.

References APIHandler\getEndpointPattern().

Member Function Documentation

◆ _setupIssueTemplate()

static IssueHandler::_setupIssueTemplate (   $request,
  $issue,
  $showToc = false 
)
static

Given an issue, set up the template with all the required variables for frontend/objects/issue_toc.tpl to function properly (i.e. current issue and view issue).

Parameters
$issueobject The issue to display
$showTocboolean iff false and a custom cover page exists, the cover page will be displayed. Otherwise table of contents will be displayed.

Definition at line 282 of file pages/issue/IssueHandler.inc.php.

References PKPServices\get(), PKPApplication\get(), DAORegistry\getDAO(), AppLocale\getLocale(), PKPTemplateManager\getManager(), getMany(), and Application\getPaymentManager().

Referenced by IndexHandler\index(), and view().

◆ archive()

IssueHandler::archive (   $args,
  $request 
)

Display the issue archive listings

Parameters
$argsarray
$requestPKPRequest

Definition at line 122 of file pages/issue/IssueHandler.inc.php.

References PKPServices\get(), PKPTemplateManager\getManager(), getMany(), Config\getVar(), and setupTemplate().

◆ authorize() [1/2]

IssueHandler::authorize (   $request,
$args,
  $roleAssignments 
)

Authorize this request.

Routers will call this method automatically thereby enforcing authorization. This method will be called before the validate() method and before passing control on to the handler operation.

NB: This method will be called once for every request only.

Parameters
$requestRequest
$argsarray request arguments
$roleAssignmentsarray the operation role assignment, see getRoleAssignment() for more details.
Returns
boolean

Reimplemented from PKPHandler.

Definition at line 30 of file pages/issue/IssueHandler.inc.php.

References PKPHandler\addPolicy().

◆ authorize() [2/2]

IssueHandler::authorize (   $request,
$args,
  $roleAssignments 
)

Authorize this request.

Routers will call this method automatically thereby enforcing authorization. This method will be called before the validate() method and before passing control on to the handler operation.

NB: This method will be called once for every request only.

Parameters
$requestRequest
$argsarray request arguments
$roleAssignmentsarray the operation role assignment, see getRoleAssignment() for more details.
Returns
boolean

Reimplemented from PKPHandler.

Definition at line 53 of file api/v1/issues/IssueHandler.inc.php.

References PKPHandler\addPolicy(), and APIHandler\getSlimRequest().

◆ current()

IssueHandler::current (   $args,
  $request 
)

Display current issue page.

Definition at line 74 of file pages/issue/IssueHandler.inc.php.

References DAORegistry\getDAO(), PKPTemplateManager\getManager(), PluginRegistry\loadCategory(), and setupTemplate().

Referenced by index().

◆ download()

IssueHandler::download (   $args,
  $request 
)

Downloads an issue galley file

Parameters
$argsarray ($issueId, $galleyId)
$requestRequest

Definition at line 164 of file pages/issue/IssueHandler.inc.php.

References HookRegistry\call(), PKPHandler\getAuthorizedContextObject(), getGalley(), and userCanViewGalley().

◆ get()

IssueHandler::get (   $slimRequest,
  $response,
  $args 
)

Get a single issue

Parameters
$slimRequestRequest Slim request object
$responseResponse object
array$argsarguments
Returns
Response

Definition at line 231 of file api/v1/issues/IssueHandler.inc.php.

References PKPServices\get(), PKPHandler\getAuthorizedContextObject(), and APIHandler\getRequest().

◆ getCurrent()

IssueHandler::getCurrent (   $slimRequest,
  $response,
  $args 
)

Get the current issue

Parameters
$slimRequestRequest Slim request object
$responseResponse object
array$argsarguments
Returns
Response

Definition at line 202 of file api/v1/issues/IssueHandler.inc.php.

References PKPServices\get(), DAORegistry\getDAO(), and APIHandler\getRequest().

◆ getGalley()

IssueHandler::getGalley ( )

Get the retrieved issue galley

Returns
IssueGalley

Definition at line 181 of file pages/issue/IssueHandler.inc.php.

References $_galley.

Referenced by download(), userCanViewGalley(), and view().

◆ getMany()

IssueHandler::getMany (   $slimRequest,
  $response,
  $args 
)

Get a collection of issues

Parameters
$slimRequestRequest Slim request object
$responseResponse object
array$argsarguments
Returns
Response

Definition at line 88 of file api/v1/issues/IssueHandler.inc.php.

References HookRegistry\call(), PKPServices\get(), and APIHandler\getRequest().

Referenced by _setupIssueTemplate(), and archive().

◆ index()

IssueHandler::index (   $args,
  $request 
)

Display about index page.

Reimplemented from PKPHandler.

Definition at line 67 of file pages/issue/IssueHandler.inc.php.

References current().

◆ initialize()

IssueHandler::initialize (   $request,
  $args = array() 
)
See also
PKPHandler::initialize()
Parameters
$argsarray Arguments list

Definition at line 48 of file pages/issue/IssueHandler.inc.php.

References PKPHandler\getAuthorizedContextObject(), DAORegistry\getDAO(), and setGalley().

◆ setGalley()

IssueHandler::setGalley (   $galley)

Set a retrieved issue galley

Parameters
$galleyIssueGalley

Definition at line 189 of file pages/issue/IssueHandler.inc.php.

Referenced by initialize().

◆ setupTemplate()

IssueHandler::setupTemplate (   $request)

Set up the basic template.

Parameters
$requestPKPRequest

Reimplemented from PKPHandler.

Definition at line 268 of file pages/issue/IssueHandler.inc.php.

References AppLocale\requireComponents().

Referenced by archive(), current(), and view().

◆ userCanViewGalley()

IssueHandler::userCanViewGalley (   $request)

Determines whether or not a user can view an issue galley.

Parameters
$requestRequest

Definition at line 197 of file pages/issue/IssueHandler.inc.php.

References PKPHandler\getAuthorizedContextObject(), DAORegistry\getDAO(), getGalley(), Application\getPaymentManager(), Validation\isLoggedIn(), and Validation\redirectLogin().

Referenced by download(), and view().

◆ view()

IssueHandler::view (   $args,
  $request 
)

Field Documentation

◆ $_galley

IssueGalley IssueHandler::$_galley = null

retrieved issue galley

Definition at line 24 of file pages/issue/IssueHandler.inc.php.

Referenced by getGalley().


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