Class DefaultExcelSupercategorySelectionDecorator
- java.lang.Object
-
- com.hybris.backoffice.excel.exporting.DefaultExcelSupercategorySelectionDecorator
-
- All Implemented Interfaces:
ExcelExportParamsDecorator,org.springframework.core.Ordered
public class DefaultExcelSupercategorySelectionDecorator extends java.lang.Object implements ExcelExportParamsDecorator
ExcelExportParamsDecoratorthat appends 'supercategories' attribute selection.
-
-
Constructor Summary
Constructors Constructor Description DefaultExcelSupercategorySelectionDecorator()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected booleancanReadSupercategoriesAttribute()ExcelExportParamsdecorate(ExcelExportParams excelExportParams)Adds supercategories attribute toExcelExportParams.getSelectedAttributes()if: supercategory is not yet selected, and at least one classification attribute has been selected, and access to supercategory attribute is not forbidden. OtherwiseExcelExportParamsis returned without any modification.intgetOrder()AttributeDescriptorModelgetProductSupercategoriesAttribute()ComposedTypeModelgetProductType()protected booleanhasAtLeastOneClassificationAttributeSelected(ExcelExportParams excelExportParams)protected booleanhasNotSelectedSupercategoriesAttribute(ExcelExportParams excelExportParams)voidsetOrder(int order)voidsetPermissionCRUDService(PermissionCRUDService permissionCRUDService)voidsetTypeService(TypeService typeService)
-
-
-
Method Detail
-
decorate
@Nonnull public ExcelExportParams decorate(@Nonnull ExcelExportParams excelExportParams)
Adds supercategories attribute toExcelExportParams.getSelectedAttributes()if:- supercategory is not yet selected,
- and at least one classification attribute has been selected,
- and access to supercategory attribute is not forbidden.
ExcelExportParamsis returned without any modification.- Specified by:
decoratein interfaceExcelExportParamsDecorator- Parameters:
excelExportParams- that should be populated with supercategories attribute- Returns:
- excelExportParams with selected supercategory attribute if the above conditions are met
- See Also:
ExcelExportParamsDecorator.getOrder()
-
hasNotSelectedSupercategoriesAttribute
protected boolean hasNotSelectedSupercategoriesAttribute(ExcelExportParams excelExportParams)
-
hasAtLeastOneClassificationAttributeSelected
protected boolean hasAtLeastOneClassificationAttributeSelected(ExcelExportParams excelExportParams)
-
canReadSupercategoriesAttribute
protected boolean canReadSupercategoriesAttribute()
-
setTypeService
public void setTypeService(TypeService typeService)
-
setPermissionCRUDService
public void setPermissionCRUDService(PermissionCRUDService permissionCRUDService)
-
getOrder
public int getOrder()
- Specified by:
getOrderin interfaceExcelExportParamsDecorator- Specified by:
getOrderin interfaceorg.springframework.core.Ordered
-
setOrder
public void setOrder(int order)
-
getProductType
public ComposedTypeModel getProductType()
-
getProductSupercategoriesAttribute
public AttributeDescriptorModel getProductSupercategoriesAttribute()
-
-