Matching Products
MatchingProductsRule
Presents the user with items matching the kitchen (this could either be to match the front, the box, or any other item - depending on retailer requirement).
Notification level: Not applicable
Key | Value |
---|---|
ID | MatchingProductsRule |
Translation key | Not applicable |
Overload Parameter
The overload is formatted as a JSON object, the overloads of this rule allow retailers to define a precise mapping between a parameter being replaced and the current value of other parameters.
Key name | Type | Default value | Description |
---|---|---|---|
Can be anything | object | – | Optional Defines the list of items mapped in key-value pair where the key is the selected product id and the value contains an array of suitable items for which the rule needs to be applied. |
Note:
Overloads will be the same as the Sample json provided below.
Sample
[
"handle": {
"front": {
"13855": ["14087", "15476"],
"15764": [],
"15761": ["14087"],
"13699": [],
"15766": [],
"15516": ["13776"],
"14119": ["15476", "13776"],
"15515": ["15476"],
"15758": ["14087", "15476"],
"74982": ["14087", "15476", "13776"]
},
"drawerFront": {
"13700": ["15476", "13776"],
"15765": ["13776"],
"15763": ["14087", "15476"],
"15514": ["14087", "15476", "13776"],
"14125": ["14087"],
"15767": ["14087", "15476"],
"15518": [],
"15517": ["15476", "13776"],
"15762": ["14087", "15476", "13776"]
}
}
]
This rule will present the user with the two-tab layout for replacing the item based on the rule defined in the overloads, where Tab1 will show suggested items based on the MatchingProductsRule
and Tab2 will show all the available items. If no matching items are configurated then the two-tab layout will not be shown. The two-tab layout will only be shown if there is at least 1 matching item.
Trigger Conditions
This rule is triggered for items available in the MatchingProductsRule
overloads.
For example, when the user replaces the handle of a cabinet, the results will be presented with two tabs, Tab1 will show only the suggested handles, and Tab2 will show all the available items as shown:
Note:
In the above example, if the selected product ID is not mentioned in the applicative rule, the rule won't find any matching handle. Hence only one tab will be presented with all the available items.