Class DefaultExcelSupercategorySelectionDecorator

java.lang.Object
com.hybris.backoffice.excel.exporting.DefaultExcelSupercategorySelectionDecorator
All Implemented Interfaces:
ExcelExportParamsDecorator, org.springframework.core.Ordered

public class DefaultExcelSupercategorySelectionDecorator extends Object implements ExcelExportParamsDecorator
ExcelExportParamsDecorator that appends 'supercategories' attribute selection.
  • Constructor Details

    • DefaultExcelSupercategorySelectionDecorator

      public DefaultExcelSupercategorySelectionDecorator()
  • Method Details

    • decorate

      @Nonnull public ExcelExportParams decorate(@Nonnull ExcelExportParams excelExportParams)
      Adds supercategories attribute to ExcelExportParams.getSelectedAttributes() if:
      • supercategory is not yet selected,
      • and at least one classification attribute has been selected,
      • and access to supercategory attribute is not forbidden.
      Otherwise ExcelExportParams is returned without any modification.
      Specified by:
      decorate in interface ExcelExportParamsDecorator
      Parameters:
      excelExportParams - that should be populated with supercategories attribute
      Returns:
      excelExportParams with selected supercategory attribute if the above conditions are met
      See Also:
    • 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:
      getOrder in interface ExcelExportParamsDecorator
      Specified by:
      getOrder in interface org.springframework.core.Ordered
    • setOrder

      public void setOrder(int order)
    • getProductType

      public ComposedTypeModel getProductType()
    • getProductSupercategoriesAttribute

      public AttributeDescriptorModel getProductSupercategoriesAttribute()