Skip to Content
0
Former Member
Nov 09, 2017 at 06:10 PM

Advanced Search in Backoffice by Catalog version

228 Views

Hi, I'm trying to add a custom ConditionSearchController to filter only staged products in a custom view in backoffice. I followed the official guide:

https://help.hybris.com/6.2.0/hcd/8b5074b3866910149d2bf4072759941e.html

They explain how to filter by custom field and Approval field adding SearchConditionData:

 private static final String APPROVAL_STATUS = "approvalStatus";
 ...
 final FieldType approvalStatus = new FieldType();
         approvalStatus.setDisabled(true);
         approvalStatus.setSelected(true);
         approvalStatus.setName(APPROVAL_STATUS);
 ...
 
 SearchConditionData(approvalStatus, ArticleApprovalStatus.APPROVED, ValueComparisonOperator.EQUALS)

But if I try to add "catalogVersion" field and then add a SearchConditionData

 SearchConditionData catalogCondition = new SearchConditionData(catalogVersion, "Staged", ValueComparisonOperator.EQUALS);

Doesn't work, i have not found a enum class like ArticleApprovalStatus for Catalog version, I suppose it's part of the problem