ResultFieldTemplate
Emit events to request templates to be used for result fields.
Namespace
IO\Services\ItemSearch\Helper
Type | Name | Value | Description |
---|---|---|---|
|
'IO.ResultFields.ListItem' |
||
|
'IO.ResultFields.SingleItem' |
||
|
'IO.ResultFields.BasketItem' |
||
|
'IO.ResultFields.AutoCompleteListItem' |
||
|
'IO.ResultFields.CategoryTree' |
||
|
'IO.ResultFields.VariationAttributeMap' |
Type | Name | Description |
---|---|---|
|
||
|
Methods
public static get($template):string
Get the path to result fields file from template/ theme
Type |
Name |
Description |
|
Event to be emitted to templates/ themes |
public static load($template)
Type |
Name |
Description |
|
public setTemplate($event, $template)
Set the path of a template to read result fields from.
Type |
Name |
Description |
|
The event to set the template for. |
|
|
Path to the template to read result fields from. |
public requireFields($event, $field = [])
Add required fields to variation search requests.
Type |
Name |
Description |
|
A single template event to set required fields for or a map between template events and list of required fields |
|
|
If first parameter describes a single template event this parameter may contain a single result field or a list of field to require. |