DefaultController
class DefaultController extends Controller (View source)
Traits
Trait ApplicationAwareTrait A trait used with ApplicationAwareInterface
Properties
protected Application | $app | from ApplicationAwareTrait | |
protected | $helpers | from AbstractController | |
protected | $sets | from AbstractController | |
protected | $action | from AbstractController | |
protected | $request | from AbstractController | |
protected | $parameters | from AbstractController | |
protected | $entityManager | from Controller | |
protected Key | $attributeKey | from Controller | |
protected AbstractValue | $attributeValue | from Controller | |
protected | $searchIndexFieldDefinition | ||
protected | $requestArray | from Controller |
Methods
Adds an item to the view's header. This item will then be automatically printed out before the
section of the page.Adds an item to the view's footer. This item will then be automatically printed out before the section of the page.
For a DateTime implementation this could for example mean that the value is formatted and localized.
This method is called any time an attribute key is created or updated.
Is run when an attribute is saved through the standard user interfaces like the sitemap attributes dialog, the attributes panel, or the user attributes slideouts.
Create the default attribute value (if needed).
Is run whenever $object->setAttribute('my_property_location_attribute', $value) is run through code, with whatever you happen to pass through.
No description
Is used to determine the name of the entity used to store the attribute value.
Return a formatter object that provides an icon that will be shown in the list of attributes.
No description
No description
No description
No description
No description
Details
setApplication(Application $app)
Setter method for the application
__construct(EntityManager $entityManager)
No description
mixed
getRequest()
No description
setRequest(mixed $request)
No description
requireAsset()
No description
addHeaderItem(string $item)
Adds an item to the view's header. This item will then be automatically printed out before the
section of the page.
addFooterItem(string $item)
Adds an item to the view's footer. This item will then be automatically printed out before the section of the page.
set($key, $val)
No description
getSets()
No description
shouldRunControllerTask()
No description
getHelperObjects()
No description
get($key = null, $defaultValue = null)
No description
getTask()
No description
getAction()
No description
getParameters()
No description
on_start()
No description
on_before_render()
No description
isPost()
deprecated
deprecated
No description
post($field = false, $defaultValue = null)
No description
redirect()
No description
runTask($action, $parameters)
No description
runAction($action, $parameters = array())
No description
request($field = false)
No description
setRequestArray($array)
No description
mixed
setAttributeKey($attributeKey)
No description
setAttributeValue($attributeValue)
No description
AttributeKeyInterface
getAttributeKey()
Returns a Key entity.
A key is mapped with a row from the AttributeKeys table. Use the object for example to retrieve the current attribute handle (e.g. 'meta_title').
mixed
getDisplayValue()
For a DateTime implementation this could for example mean that the value is formatted and localized.
AttributeValueInterface
getAttributeValue()
Get Attribute Value object.
Type
getAttributeType()
Returns a Type entity.
The Type object is mapped with a row from the AttributeTypes table. Use the object for example to retrieve the current attribute type handle (e.g. 'date_time').
exportKey($ak)
No description
importValue(SimpleXMLElement $akv)
No description
importKey(SimpleXMLElement $element)
No description
getValidator()
No description
deleteKey()
No description
deleteValue()
No description
exportValue(SimpleXMLElement $akv)
No description
filterByAttribute(AttributedItemList $list, $value, $comparison = '=')
No description
field($fieldName)
No description
getControlView(ContextInterface $context)
No description
label($customText = false)
No description
getLabelID()
Get the ID to use for label elements
setAttributeType($attributeType)
No description
requestFieldExists()
No description
getView()
No description
string|int
getSearchIndexValue()
This value will be used by the search index.
getSearchIndexFieldDefinition()
No description
setupAndRun($method)
No description
getAttributeTypeFileURL($_file)
No description
saveKey(array $data)
This method is called any time an attribute key is created or updated.
$data is simply the POST values from the form.
duplicateKey($newAK)
No description
AttributeValueInterface
createAttributeValueFromRequest()
Is run when an attribute is saved through the standard user interfaces like the sitemap attributes dialog, the attributes panel, or the user attributes slideouts.
Value|null
createDefaultAttributeValue()
Create the default attribute value (if needed).
AttributeValueInterface
createAttributeValue($value)
Is run whenever $object->setAttribute('my_property_location_attribute', $value) is run through code, with whatever you happen to pass through.
saveForm($data)
deprecated
deprecated
No description
saveValue($mixed)
deprecated
deprecated
No description
searchKeywords($keywords, $queryBuilder)
No description
validateKey($data = false)
No description
getAttributeKeySettingsClass()
No description
createAttributeKeySettings()
No description
protected
retrieveAttributeKeySettings()
No description
getAttributeValueID()
No description
string
getAttributeValueClass()
Is used to determine the name of the entity used to store the attribute value.
You can reuse this throughout your controllers, but it's used by the getAttributeValueObject() method in the base controller to retrieve the relevant attribute data value object.
getAttributeValueObject()
No description
getAttributeKeySettings()
No description
IconFormatterInterface
getIconFormatter()
Return a formatter object that provides an icon that will be shown in the list of attributes.
Example implementation: return new FontAwesomeIconFormatter('check-square');
form()
No description
searchForm($list)
No description
search()
No description
validateValue()
No description
validateForm($data)
No description