BlocksModel
extends ArcheModel
in package
Description of DetailViewModel
Tags
Table of Contents
Properties
- $config : mixed
- $drupalDb : mixed
- $limit : mixed
- $offset : mixed
- $order : mixed
- $repoDb : mixed
- $siteLang : mixed
Methods
- __construct() : mixed
- getVersionsData() : array<string|int, mixed>
- Get the Versions block data
- getViewData() : array<string|int, mixed>
- Get the data for the left side boxes
- lastModificationDate() : array<string|int, mixed>
- Get the DB last modification date for the cache
- setSqlTimeout() : mixed
- Set the sql execution max time
- closeDBConnection() : mixed
- ordering() : object
- Create the order values for the sql
- orderingByFields() : object
- reOrderResult() : array<string|int, mixed>
- Reorder the result because of the easyrdf
- setActiveConnection() : mixed
- Allow the DB connection
- sortAssociativeArrayByKey() : array<string|int, mixed>
- Reorder the Easyrdf result because the dataset is already filtered by the API But the actual order is not possible from the easyrdf, so we have to sort is manually.
- getCategoryData() : array<string|int, mixed>
- getEntityData() : array<string|int, mixed>
- Generate the entity box data
- getMainVersionResourceID() : string
- Get the newest version id, to we can fetch the whole tree
- getYearsData() : array<string|int, mixed>
- Generate the year box data
Properties
$config
protected
mixed
$config
$drupalDb
protected
mixed
$drupalDb
$limit
protected
mixed
$limit
$offset
protected
mixed
$offset
$order
protected
mixed
$order
$repoDb
protected
mixed
$repoDb
$siteLang
protected
mixed
$siteLang
Methods
__construct()
public
__construct() : mixed
getVersionsData()
Get the Versions block data
public
getVersionsData(array<string|int, mixed> $params) : array<string|int, mixed>
Parameters
- $params : array<string|int, mixed>
Return values
array<string|int, mixed>getViewData()
Get the data for the left side boxes
public
getViewData([string $identifier = "entity" ][, array<string|int, mixed> $params = array() ]) : array<string|int, mixed>
Parameters
- $identifier : string = "entity"
- $params : array<string|int, mixed> = array()
Return values
array<string|int, mixed>lastModificationDate()
Get the DB last modification date for the cache
public
lastModificationDate() : array<string|int, mixed>
Return values
array<string|int, mixed>setSqlTimeout()
Set the sql execution max time
public
setSqlTimeout([string $timeout = '7000' ]) : mixed
Parameters
- $timeout : string = '7000'
closeDBConnection()
protected
closeDBConnection() : mixed
ordering()
Create the order values for the sql
protected
ordering([string $orderby = "titleasc" ]) : object
Parameters
- $orderby : string = "titleasc"
Return values
objectorderingByFields()
protected
orderingByFields(array<string|int, mixed> $valuesAndFields[, string $orderby = "titleasc" ]) : object
Parameters
- $valuesAndFields : array<string|int, mixed>
- $orderby : string = "titleasc"
Return values
objectreOrderResult()
Reorder the result because of the easyrdf
protected
reOrderResult(array<string|int, mixed> $data, string $order) : array<string|int, mixed>
Parameters
- $data : array<string|int, mixed>
- $order : string
Return values
array<string|int, mixed>setActiveConnection()
Allow the DB connection
protected
setActiveConnection() : mixed
sortAssociativeArrayByKey()
Reorder the Easyrdf result because the dataset is already filtered by the API But the actual order is not possible from the easyrdf, so we have to sort is manually.
protected
sortAssociativeArrayByKey(array<string|int, mixed> $array, string $key, string $direction) : array<string|int, mixed>
.
Parameters
- $array : array<string|int, mixed>
- $key : string
- $direction : string
Return values
array<string|int, mixed>getCategoryData()
private
getCategoryData() : array<string|int, mixed>
Return values
array<string|int, mixed>getEntityData()
Generate the entity box data
private
getEntityData() : array<string|int, mixed>
Return values
array<string|int, mixed>getMainVersionResourceID()
Get the newest version id, to we can fetch the whole tree
private
getMainVersionResourceID(string $id) : string
Parameters
- $id : string
Return values
stringgetYearsData()
Generate the year box data
private
getYearsData() : array<string|int, mixed>