Field configuration advanced description
Fields display informations about assets and can be set up depending on your needs.
NamedFieldConfig
description
NamedFieldConfig
are named field configurations. This allows to define fields once and to re-use them across different contexts.
NamedFieldConfig
are defined in $.common.namedDisplays
. It can be one of:
A
string
reflecting aNamedFieldConfig
A
string
reflecting a field name (as defined in the admin structure area)An
ItemFieldConfig
ItemFieldConfig
description
An ItemFieldConfig
reflects a single field. It can be defined as:
A
string
representing the field you want to create. This is equivalent to creating a FieldConfig by only specifying the field property :
"myfieldname"
// equivalent to
{
"field": "myfieldname"
}
Â
A
FieldConfig
describing the field.
FieldConfig
description
An Object
representing a given field.
Property | Type | Default | Description |
---|---|---|---|
|
| No default value | Refers to a field name described in the admin area |
|
|
| Do not display the name of the field before the value |
|
|
| Display a bullet before the field |
|
| No default value | Add class to the corresponding field |
|
| No default value | Label to display (by default the name of the field will be used) |
|
| No default value | I18n key to use for the label |
|
|
| Show field even if the field has no value |
|
| No default value | If set to true facets put on the field will be ignored |
Â
Additional FieldConfig
properties for Relationship
fields
Property | Type | Default | Description |
---|---|---|---|
|
|
| Display field value(s) as a badge |
|
|
| Is value clickable or not. |
|
|
| When a badge is clickable, the click action is to redirect the user to the search page. The value of the field will be used in the search page, you can decide which operator will be used by modifying the value of this property. |
|
|
| Add constraint to existing ones or replace it. Targets only the corresponding field, not all constrains. |
Â
Additional FieldConfig
properties for Date
fields
Property | Type | Default | Description |
---|---|---|---|
|
|
| Which value to use to format dates. The value is placed in i18n files as the format should be internationalised. Internally we use |
Additional FieldConfig
properties for Relationship
fields that should display an image
Is used for fields of type Array
, Object
, or resource
. You must specify a cwVariation
in your config to use these type of field (example : show a dropdown listing users and showing their avatar).
Property | Type | Default | Description |
---|---|---|---|
|
| No default value | Choose the variation to display |
|
|
| I18n message to display in case of empty field |
|
|
| Classes to add to the field |
|
|
| Classes to add to the wrapper |
Â
Additional FieldConfig
properties for String
fields
Property | Type | Default | Description |
---|---|---|---|
|
| No default value | Handle options for tooltips. |