Table of Contents | ||
---|---|---|
|
Default customer form
Default
...
fields
By default, when the catalogue is activated, a standard form is proposed with the following fields:
...
This is what the default customer form looks like:
...
...
Specific configurations on the default form
...
Put the first name before the surname
Change the list of countries
Add custom fields
Invert the position of the first and last names: so that the first name appears first and the last name second, you need to add the configuration
"customer.invert_names" : true
in the Configuration > Store App > Pages > Catalog > Specific settings page in the Options section.Code Block { "customer": { "invert_names": true } }
...
Change the list of countries:
The default form proposes the following countries: France, Belgium, Germany, Italy, Luxembourg, Spain, Switzerland, United Kingdom. An override can be made per sales channel using the configuration "countries.{sales_channel}.{list of countries}"
in the Configuration > Store App > Pages > Catalog > Specific settings page in the Options section.
Country codes must be in ISO-3166 format. Logos and translations will add themselves in the Store App.
Code Block |
---|
{
"countries": {
"sc_ois_1": [
"FR",
"CH"
"GB"
]
}
} |
...
Add custom fields
sales channels
Classic fields
Field | Type | Mandatory | Description | ||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| string | Yes | This key is used to give the identifier of the field. This id must match with parameters used in
| ||||||||||||||||||||||||
| string | No | Indicates whether the field should be saved in the Only used for
| ||||||||||||||||||||||||
| string | No | Type of the field. By default, the
| ||||||||||||||||||||||||
| boolean | No | Indicates whether the field is mandatory or not. By default, fields are optional. | ||||||||||||||||||||||||
| string | No | This key defines the name of the form element to which it must be placed after. Please note, the form element must be in the default form or declared before in the same form. It it also possible to place the element on the top of the form with the value If not defined, the element form will be placed at the bottom of the form.
| ||||||||||||||||||||||||
| object | No | Enables to add custom validation to the field, which will be checked when the create button is clicked.
|
...