Document_Grid
Handles the display of a Document_Grid
Tags
Table of Contents
- $args : mixed
- $grid_cards : mixed
- $id : mixed
- $query : mixed
- $documents : array<string|int, Document>
- The Documents to be displayed.
- $cache : mixed
- $grid_html : mixed
- $grid_initialised : mixed
- $hooks : mixed
- __construct() : mixed
- Constructor.
- get_grid() : string
- Initiliase and/or retrive a grid.
- update() : mixed
- Update the grid
- add_default_grid_args() : array<string|int, mixed>
- Add default args which always apply to the grid.
- fetch_documents() : mixed
- Fetch the documents.
Properties
$args
public
mixed
$args
$grid_cards
public
mixed
$grid_cards
$id
public
mixed
$id
$query
public
mixed
$query
$documents
The Documents to be displayed.
protected
array<string|int, Document>
$documents
$cache
private
mixed
$cache
$grid_html
private
mixed
$grid_html
$grid_initialised
private
mixed
$grid_initialised
= false
$hooks
private
mixed
$hooks
Methods
__construct()
Constructor.
public
__construct(mixed $id, array<string|int, mixed> $args) : mixed
Parameters
- $id : mixed
- $args : array<string|int, mixed>
Return values
mixed —get_grid()
Initiliase and/or retrive a grid.
public
get_grid([string $output = 'html' ]) : string
Parameters
- $output : string = 'html'
Return values
string —update()
Update the grid
public
update(int|array<string|int, mixed> $args) : mixed
Parameters
- $args : int|array<string|int, mixed>
Return values
mixed —add_default_grid_args()
Add default args which always apply to the grid.
private
static add_default_grid_args(array<string|int, mixed> $args) : array<string|int, mixed>
Parameters
- $args : array<string|int, mixed>
-
The initial grid arguments.
Return values
array<string|int, mixed> —The modified grid arguments.
fetch_documents()
Fetch the documents.
private
fetch_documents() : mixed