Class ScriptServiceItemSearchRequestEnricher

java.lang.Object
de.hybris.platform.integrationservices.search.enricher.ScriptServiceItemSearchRequestEnricher
All Implemented Interfaces:
ItemSearchRequestEnricher

public class ScriptServiceItemSearchRequestEnricher extends Object implements ItemSearchRequestEnricher
For Scripts, Commerce keeps a history of the Script when the content changes, i.e. a new item is created for the new content and is marked active. The previous active one is now marked as inactive. When searching just with the code, The ScriptService may fail with a non unique item error because Commerce returns all the Scripts instead of just the active one. This class enriches the search so only the active ones are returned when using the ScriptService.