Open Monograph Press  1.1
 All Classes Namespaces Functions Variables Groups Pages
LibraryFileGridHandler Class Reference
Inheritance diagram for LibraryFileGridHandler:
CategoryGridHandler GridHandler PKPHandler LibraryFileAdminGridHandler

Public Member Functions

 _getEditFileForm ($context, $fileId)
 
 _getNewFileForm ($context)
 
 addFile ($args, $request)
 
 canEdit ()
 
 deleteFile ($args, $request)
 
 editFile ($args, $request)
 
 getActionArgs ()
 
 getCategoryRowInstance ()
 
 getContext ()
 
 getFileNameColumn ()
 
 getRowInstance ()
 
 LibraryFileGridHandler ($dataProvider)
 
 loadData ($request, $filter)
 
 saveFile ($args, $request)
 
 setCanEdit ($canEdit)
 
 updateFile ($args, $request)
 
 uploadFile ($args, $request)
 
- Public Member Functions inherited from CategoryGridHandler
 CategoryGridHandler ($dataProvider=null)
 
 fetchCategory (&$args, $request)
 
 getCurrentCategoryId ()
 
 getDataElementInCategorySequence ($categoryId, &$gridDataElement)
 
 getEmptyCategoryRowText ()
 
 getJSHandler ()
 
 getRequestArgs ()
 
 hasGridDataElementsInCategory ($categoryDataElement, $request)
 
 isDataElementInCategorySelected ($categoryId, &$gridDataElement)
 
 setDataElementInCategorySequence ($categoryId, &$gridDataElement, $newSequence)
 
 setEmptyCategoryRowText ($translationKey)
 
 setUrls ($request)
 
- Public Member Functions inherited from GridHandler
 addAction ($action, $position=GRID_ACTION_POSITION_ABOVE)
 
 addColumn ($column)
 
 authorize ($request, &$args, $roleAssignments, $enforceRestrictedSite=true)
 
 fetchCell (&$args, $request)
 
 fetchGrid ($args, $request)
 
 fetchRow (&$args, $request)
 
 getActions ($position=GRID_ACTION_POSITION_ABOVE)
 
 getColumn ($columnId)
 
getColumns ()
 
getColumnsByFlag ($flag)
 
 getColumnsCount ($flag)
 
 getDataElementSequence (&$gridDataElement)
 
 getDataProvider ()
 
 getEmptyRowText ()
 
 getFeatures ()
 
 getFootNote ()
 
getGridDataElements ($request)
 
 getGridRangeInfo ($request, $rangeName, $contextData=null)
 
 getInstructions ()
 
 getIsSubcomponent ()
 
 getItemIterator ()
 
 getJSHandler ()
 
 getPublishChangeEvents ()
 
 getRequestArg ($key)
 
 getRequestArgs ()
 
 getRequestedRow ($request, $args)
 
 getSelectName ()
 
 getTemplate ()
 
 getTitle ()
 
 getUrls ()
 
 GridHandler ($dataProvider=null)
 
 hasColumn ($columnId)
 
 hasGridDataElements ($request)
 
 initialize ($request, $args=null)
 
 isDataElementSelected ($gridDataElement)
 
 renderRow ($request, $row)
 
 saveSequence ($args, $request)
 
 setDataElementSequence ($request, $rowId, &$gridDataElement, $newSequence)
 
 setEmptyRowText ($emptyRowText)
 
 setFootNote ($footNote)
 
 setGridDataElements ($data)
 
 setInstructions ($instructions)
 
 setTemplate ($template)
 
 setTitle ($title)
 
 setUrls ($request, $extraUrls=array())
 
- Public Member Functions inherited from PKPHandler
 addCheck (&$handlerValidator)
 
 addPolicy ($authorizationPolicy, $addToTop=false)
 
 addRoleAssignment ($roleIds, $operations)
 
 authorize ($request, &$args, $roleAssignments, $enforceRestrictedSite=true)
 
getAuthorizedContext ()
 
getAuthorizedContextObject ($assocType)
 
getDispatcher ()
 
 getFirstUserContext ($user, $contexts)
 
 getId ()
 
 getLastAuthorizationMessage ()
 
 getLoginExemptions ()
 
 getRoleAssignment ($roleId)
 
 getRoleAssignments ()
 
 getWorkingContexts ($request)
 
 index ($args, $request)
 
 initialize ($request, $args=null)
 
 PKPHandler ()
 
 setDispatcher ($dispatcher)
 
 setId ($id)
 
 setupTemplate ($request)
 
 validate ($requiredContexts=null, $request=null)
 

Public Attributes

 $_canEdit
 
 $_context
 
- Public Attributes inherited from CategoryGridHandler
 $_currentCategoryId = null
 
 $_emptyCategoryRowText = 'grid.noItems'
 
- Public Attributes inherited from GridHandler
 $_actions = array(GRID_ACTION_POSITION_DEFAULT => array())
 
 $_columns = array()
 
 $_data
 
 $_emptyRowText = 'grid.noItems'
 
 $_features
 
 $_footNote = ''
 
 $_instructions = ''
 
 $_itemIterator
 
 $_template
 
 $_title = ''
 
 $_urls
 
- Public Attributes inherited from PKPHandler
 $_authorizationDecisionManager
 
 $_checks = array()
 
 $_dispatcher
 
 $_id
 
 $_roleAssignments = array()
 

Additional Inherited Members

- Static Public Member Functions inherited from PKPHandler
static getPageParamName ($rangeName)
 
static getRangeInfo ($request, $rangeName, $contextData=null)
 
static hashPageContext ($request, $contextData=array())
 
- Protected Member Functions inherited from CategoryGridHandler
 doSpecificFetchGridActions ($args, $request, &$templateMgr)
 
getCategoryData (&$categoryDataElement, $filter=null)
 
 getCategoryRowIdParameterName ()
 
 getCategoryRowInstance ()
 
 getRequestedCategoryRow ($request, $args)
 
 getRowDataElement ($request, $rowId)
 
 getRowsSequence ($request)
 
 renderRowInternally ($request, $row)
 
 setFirstDataColumn ()
 
- Protected Member Functions inherited from GridHandler
 callFeaturesHook ($hookName, $args)
 
 doSpecificFetchGridActions ($args, $request, $templateMgr)
 
getDataElementFromRequest ($request, &$elementId)
 
 getFilterForm ()
 
 getFilterSelectionData ($request)
 
 getRowDataElement ($request, $rowId)
 
 getRowInstance ()
 
 getRowsSequence ($request)
 
 initFeatures ($request, &$args)
 
 loadData ($request, $filter)
 
 noAutocompleteResults ()
 
 renderFilter ($request, $filterData=array())
 
 renderGridBodyPartsInternally ($request)
 
 renderRowInternally ($request, $row)
 
 renderRowsInternally ($request, &$elements)
 
 setFirstDataColumn ()
 

Detailed Description

Base class for handling library file grid requests.

Handle submission documents file grid requests.

Definition at line 25 of file LibraryFileGridHandler.inc.php.

Member Function Documentation

LibraryFileGridHandler::_getEditFileForm (   $context,
  $fileId 
)

Returns a specific instance of the edit form for this grid. Must be implemented by subclasses.

Parameters
$contextPress
$fileIdint

Definition at line 328 of file LibraryFileGridHandler.inc.php.

Referenced by editFile(), and updateFile().

LibraryFileGridHandler::_getNewFileForm (   $context)

Returns a specific instance of the new form for this grid. Must be implemented by subclasses.

Parameters
$contextContext

Definition at line 318 of file LibraryFileGridHandler.inc.php.

Referenced by addFile(), and saveFile().

LibraryFileGridHandler::addFile (   $args,
  $request 
)

An action to add a new file

Parameters
$argsarray
$requestPKPRequest

Definition at line 180 of file LibraryFileGridHandler.inc.php.

References _getNewFileForm(), and JSONMessage\getString().

LibraryFileGridHandler::canEdit ( )

Can the user edit/add files in this grid?

Returns
boolean

Definition at line 61 of file LibraryFileGridHandler.inc.php.

References $_canEdit.

Referenced by getRowInstance().

LibraryFileGridHandler::deleteFile (   $args,
  $request 
)

Delete a file

Parameters
$argsarray
$requestPKPRequest
Returns
string Serialized JSON object

Definition at line 271 of file LibraryFileGridHandler.inc.php.

References PKPLibraryFileManager\deleteFile(), and DAO\getDataChangedEvent().

LibraryFileGridHandler::editFile (   $args,
  $request 
)

An action to add a new file

Parameters
$argsarray
$requestPKPRequest
Returns
string Serialized JSON object

Definition at line 223 of file LibraryFileGridHandler.inc.php.

References _getEditFileForm(), and JSONMessage\getString().

LibraryFileGridHandler::getActionArgs ( )

Retrieve the arguments for the 'add file' action.

Returns
array

Definition at line 336 of file LibraryFileGridHandler.inc.php.

LibraryFileGridHandler::getCategoryRowInstance ( )

Get a new instance of a category grid row. May be overridden by subclasses if they want to provide a custom row definition.

Returns
CategoryGridRow

Definition at line 128 of file LibraryFileGridHandler.inc.php.

References getContext().

LibraryFileGridHandler::getContext ( )

Get the context

Returns
object context

Definition at line 53 of file LibraryFileGridHandler.inc.php.

References $_context.

Referenced by getCategoryRowInstance(), and loadData().

LibraryFileGridHandler::getFileNameColumn ( )

Get an instance of the cell provider for this grid.

Returns
LibraryFileGridCellProvider

Definition at line 161 of file LibraryFileGridHandler.inc.php.

LibraryFileGridHandler::getRowInstance ( )

Get the row handler - override the default row handler

Returns
LibraryFileGridRow

Definition at line 153 of file LibraryFileGridHandler.inc.php.

References canEdit().

LibraryFileGridHandler::LibraryFileGridHandler (   $dataProvider)

Constructor

Definition at line 35 of file LibraryFileGridHandler.inc.php.

References PKPHandler\addRoleAssignment().

LibraryFileGridHandler::loadData (   $request,
  $filter 
)

Implement this method to load data into the grid.

Parameters
$requestRequest
$filterarray An associative array with filter data as returned by getFilterSelectionData(). If no filter has been selected by the user then the array will be empty.
Returns
grid data

Definition at line 135 of file LibraryFileGridHandler.inc.php.

References getContext(), and LibraryFileManager\getTypeSuffixMap().

LibraryFileGridHandler::saveFile (   $args,
  $request 
)

Save a new library file.

Parameters
$argsarray
$requestPKPRequest
Returns
string

Definition at line 198 of file LibraryFileGridHandler.inc.php.

References _getNewFileForm(), and DAO\getDataChangedEvent().

LibraryFileGridHandler::setCanEdit (   $canEdit)

Set whether or not the user can edit or add files.

Parameters
$canEditboolean

Definition at line 69 of file LibraryFileGridHandler.inc.php.

LibraryFileGridHandler::updateFile (   $args,
  $request 
)

Save changes to an existing library file.

Parameters
$argsarray
$requestPKPRequest
Returns
string

Definition at line 244 of file LibraryFileGridHandler.inc.php.

References _getEditFileForm(), and DAO\getDataChangedEvent().

LibraryFileGridHandler::uploadFile (   $args,
  $request 
)

Upload a new library file.

Parameters
$argsarray
$requestPKPRequest
Returns
string

Definition at line 293 of file LibraryFileGridHandler.inc.php.

Member Data Documentation

LibraryFileGridHandler::$_canEdit

whether or not the grid is editable

Definition at line 30 of file LibraryFileGridHandler.inc.php.

Referenced by canEdit().

LibraryFileGridHandler::$_context

the context for this grid

Definition at line 27 of file LibraryFileGridHandler.inc.php.

Referenced by getContext().


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