Open Journal Systems  3.3.0
PagingFeature Class Reference
Inheritance diagram for PagingFeature:
GeneralPagingFeature GridFeature

Public Member Functions

 __construct ($id='paging')
 
 fetchRow ($args)
 
 fetchUIElements ($request, $grid)
 
 getJSClass ()
 
- Public Member Functions inherited from GeneralPagingFeature
 __construct ($id, $itemsPerPage=null)
 
 getGridDataElements ($args)
 
 getGridRangeInfo ($args)
 
 getItemIterator ()
 
 getRequestArgs ($args)
 
 setGridDataElements ($args)
 
 setOptions ($request, $grid)
 
- Public Member Functions inherited from GridFeature
 addOptions ($options)
 
 fetchGrid ($args)
 
 fetchRows ($args)
 
 getId ()
 
 getInitializedCategoryRowInstance ($args)
 
 getInitializedRowInstance ($args)
 
 getOptions ()
 
 gridInitialize ($args)
 
 loadData ($args)
 
 saveSequence ($args)
 
 setId ($id)
 

Additional Inherited Members

- Data Fields inherited from GridFeature
 $_id
 
 $_options
 

Detailed Description

Add paging functionality to grids.

Definition at line 19 of file PagingFeature.inc.php.

Constructor & Destructor Documentation

◆ __construct()

PagingFeature::__construct (   $id = 'paging')
See also
GridFeature::GridFeature() Constructor.
Parameters
$idstring Feature identifier.

Reimplemented from GridFeature.

Definition at line 26 of file PagingFeature.inc.php.

Member Function Documentation

◆ fetchRow()

PagingFeature::fetchRow (   $args)

Hook called after a row is fetched.

Parameters
$argsarray 'request' => PKPRequest 'grid' => GridHandler 'row' => mixed GridRow or null 'jsonMessage' => JSONMessage Check if user really deleted a row. Handle following cases: 1 - recently added requested row is on previous pages and its addition changes the current requested page items; 2 - deleted a row from a page that's not the last one; 3 - deleted the last row from a page that's not the last one;

The solution is: 1 - fetch the first grid data row; 2 - fetch the last grid data row; 3 - send a request to refresh the entire grid usign the previous page.

Reimplemented from GridFeature.

Definition at line 74 of file PagingFeature.inc.php.

References GeneralPagingFeature\getItemIterator(), GridFeature\getOptions(), and GeneralPagingFeature\setOptions().

◆ fetchUIElements()

PagingFeature::fetchUIElements (   $request,
  $grid 
)

Fetch any user interface elements that this feature needs to add its functionality into the grid. Use this only for ui elements that grid will not fetch itself.

Parameters
$requestPKPRequest
$gridGridHandler The grid that this feature is attached to.
Returns
array It is expected that the array returns data in this format: $elementId => $elementMarkup

Reimplemented from GridFeature.

Definition at line 45 of file PagingFeature.inc.php.

References GeneralPagingFeature\getItemIterator(), PKPTemplateManager\getManager(), and GridFeature\getOptions().

◆ getJSClass()

PagingFeature::getJSClass ( )

Return the java script feature class.

Returns
string|null

Reimplemented from GridFeature.

Definition at line 37 of file PagingFeature.inc.php.


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