ModelHooks module

RetrieveRecordsAction

Class for specification of an action to retrieve a record

A model in the Hooks module, with 24 members for templates, 21 API properties and 34 members for admin templates.

View
What Smarty and Twig templates receive. Properties in REST API responses and job payloads. What admin screen templates receive when you override them.

Templates view

Properties 24

Take no arguments.

# getEntity()
?string
Get the entity which should be retrieved
# getCriteria()
array
Get the criteria that should be passed to the handler when searching for the record
# getOrderBy()
?array
Get the order that should be applied when retrieving records
# getLimit()
?string
Get the limit for retrieving records
# getOffset()
string
Get the offset when retrieving records
# getType()
string
Get the type of the action, which is the object name without namespace for the action
# getDisplayType()
string
Get Nice Name for Action Class
# getAvailablePreviousActions()
Collection
Get the available previous actions
# getId()
?int
# getName()
?string
# getText()
?string
# getPosition()
?int
# getData()
?array
# getCreated()
?DateTime
# getModified()
?DateTime
# getHook()
?Hook
Get the Hook this Action is assigned to
# getParent()
?BaseAction
# getPublished()
?DateTime
# isPublished()
bool
# isContainedInLoop()
bool
Check whether the action is contained in a loop
# getContainingLoop()
?Loop
Get the loop this action is contained in
# isNewRecord() Not in API & Jobs
bool
Check if the record is a new record
# isHierarchicalModel() Not in API & Jobs
bool
Check whether a model is a hierarchical model, i.e. can have children
# isVersionedModel() Not in API & Jobs
bool
Check whether a model is versioned

API & Jobs view

API & JobsEach property is a key in REST API responses and job payloads. Its name is the template getter without get, is or has. Methods that need arguments are not available here.

Properties 21

Read-only values on the record.

# entity
?string
Get the entity which should be retrieved
# criteria
array
Get the criteria that should be passed to the handler when searching for the record
# orderBy
?array
Get the order that should be applied when retrieving records
# limit
?string
Get the limit for retrieving records
# offset
string
Get the offset when retrieving records
# type
string
Get the type of the action, which is the object name without namespace for the action
# displayType
string
Get Nice Name for Action Class
# availablePreviousActions
Collection
Get the available previous actions
# id
?int
# name
?string
# text
?string
# position
?int
# data
?array
# created
?DateTime
# modified
?DateTime
# hook
?Hook
Get the Hook this Action is assigned to
# parent
?BaseAction
# published
?DateTime
# published
bool
# containedInLoop
bool
Check whether the action is contained in a loop
# containingLoop
?Loop
Get the loop this action is contained in

Admin view

AdminAvailable in cdna-admin templates. Copy an admin template into your site repository to change how this record is edited.

Properties 34

Take no arguments.

# getEntity()
?string
Get the entity which should be retrieved
# getCriteria()
array
Get the criteria that should be passed to the handler when searching for the record
# getOrderBy()
string
Get a string representation of the order by array
# getLimit()
?string
Get the limit for retrieving records
# getOffset()
string
Get the offset when retrieving records
# getType()
string
Get the type of the action, which is the object name without namespace for the action
# getDisplayType()
string
Get Nice Name for Action Class
# getAvailablePreviousActions()
Collection
Get the available previous actions
# getId()
?int
# getName()
?string
# getText()
?string
# getPosition()
?int
# getData()
?array
# getCreated()
?DateTime
# getModified()
?DateTime
# getHook()
?Hook
Get the Hook this Action is assigned to
# getParent()
?BaseAction
# getPublished()
?DateTime
# isPublished()
bool
# isContainedInLoop()
bool
Check whether the action is contained in a loop
# getContainingLoop()
?Loop
Get the loop this action is contained in
# isNewRecord() Not in API & Jobs
bool
Check if the record is a new record
# isHierarchicalModel() Not in API & Jobs
bool
Check whether a model is a hierarchical model, i.e. can have children
# isVersionedModel() Not in API & Jobs
bool
Check whether a model is versioned
# getModule() Admin only
?string
Get the module name from which records should be retrieved
# getEntityName() Admin only
?string
Get the entity name (without namespace) from which records should be retrieved
# getAvailableEntities() Admin only
array
Get the entities available for retrieving using this action
# getDisplayIcon() Admin only
string
Get the display icon to use when rendering the action
# getRunDataVariables() Admin only
array
Get the run data variables provided by this action
# getEditUrl() Admin only
?string
Get the url for editing the record.
# getMoveUrl() Admin only
?string
Get the url for moving the record.
# getDeleteUrl() Admin only
?string
Get the url for deleting the record.
# getAvailableTemplateVariables() Admin only
array
Get the template variables available in this action