EVA's data model for products consists of a wide range of properties. These properties are listed in Admin under Product management → Product properties. By default, we provide quite a bit of properties, but we could never provide enoguh to perfectly satisfy all of our customers, so you can add custom properties.
Custom product properties
Make sure to define your desired custom product properties before trying to add them on products.
There are two methods of adding custom product properties; including them in your
ImportProducts request, or by heading over to the Product properties overview and choosing Actions → +Add.
The property needs an ID, which EVA usually provides in
snake_case, which you probably want to adhere to for consistency's sake. You can set the category to
default, unless you've made custom categories yourself which you'd rather use.
Now for the fun part; Search type.
By default, none of these boxes are checked. Not checking any of these boxes, will not index the property in the product search. Meaning that as far as searching for products goes, these properties do not exist.
When we want our property to be indexed, we can choose between three types;
- Keyword: only exact matches will return. For example: if a property has the value "a nice jacket" and only the Keyword search type is applied, it will only match if you filter exactly on the words "a nice jacket". So it will not match if you search on the word "jacket" or "nice". This value also must be chosen if you want to be able to filter on this property.
- Text: this means the value is analyzed by Elastic, meaning every word is specifically findable. "A nice coat" for example, becomes "a" "nice" "coat". Searching on any of these words will find the product. It also enables indexation of some words to find products in the same context. For example, searching with the word "shoe" would also give you results for shoeshine.
- Hidden: it becomes an attribute on the property so frontend can know whether to show or not to show the properties (for example in a list of specs).
Make your indexing decisions carefully. It is fairly easy to slow down your product search by indexing a whole lot of properties, so choose wisely.
Mistakes in custom product properties
Once a product property is created, it is indexed right away. This means that you cannot (easily) make changes to the property anymore. As you can see in the Admin when editing a property, the values will be greyed out.
In most cases this means that you will have to delete the property and create an entirely new one, with an entirely new ID as well.
The only thing you can change for existing product properties is its search type.