ModelForms module

StaticSubmitButton

Entity for code elements.

A model in the Forms module, with 19 members for templates, 17 API properties and 19 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 19

Take no arguments.

# getType()
string
Returns the type of current element.
# getChildren()
Collection
# getEntity()
?string
# getId()
?int
# getName()
?string
Gets element name. It could be used in html to identify input, e.g. '<input name="{getName()}" ...>'.
# getHelp()
?string
Gets help text for the element. It could be used as a tooltip or in HTML as a title attribute, e.g. '<input title="{getHelp()}" ...>'.
# getEditor()
?string
# getText()
?string
Text for the element that usually is used for element's label
# getDefaultValue()
?string
# getPlaceholder()
?string
# isRequired()
?bool
# getRegex()
?string
# getPosition()
?int
# getSettings()
?array
# getRevision()
?FormRevision
# getStep()
?Step
# getParent()
?ElementGroup
# 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

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 17

Read-only values on the record.

# type
string
Returns the type of current element.
# children
Collection
# entity
?string
# id
?int
# name
?string
Gets element name. It could be used in html to identify input, e.g. '<input name="{getName()}" ...>'.
# help
?string
Gets help text for the element. It could be used as a tooltip or in HTML as a title attribute, e.g. '<input title="{getHelp()}" ...>'.
# editor
?string
# text
?string
Text for the element that usually is used for element's label
# defaultValue
?string
# placeholder
?string
# required
?bool
# regex
?string
# position
?int
# settings
?array
# revision
?FormRevision
# step
?Step
# parent
?ElementGroup

Admin view

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

Properties 19

Take no arguments.

# getType()
string
Returns the type of current element.
# getChildren()
Collection
# getEntity()
?string
# getId()
?int
# getName()
?string
Gets element name. It could be used in html to identify input, e.g. '<input name="{getName()}" ...>'.
# getHelp()
?string
Gets help text for the element. It could be used as a tooltip or in HTML as a title attribute, e.g. '<input title="{getHelp()}" ...>'.
# getEditor()
?string
# getText()
?string
Text for the element that usually is used for element's label
# getDefaultValue()
?string
# getPlaceholder()
?string
# isRequired()
?bool
# getRegex()
?string
# getPosition()
?int
# getSettings()
?array
# getRevision()
?FormRevision
# getStep()
?Step
# getParent()
?ElementGroup
# 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