Class ShoppingCreateBundleChildTemplatesHandler
java.lang.Object
de.hybris.platform.shoppingbackoffice.widgets.bundle.ShoppingCreateBundleChildTemplatesHandler
- All Implemented Interfaces:
com.hybris.cockpitng.widgets.configurableflow.FlowActionHandler
public class ShoppingCreateBundleChildTemplatesHandler
extends Object
implements com.hybris.cockpitng.widgets.configurableflow.FlowActionHandler
Custom Handler for the custom navigation action defined in the Bundle Wizard. This handler sets the catalog version of the
Parent Bundle in the child bundles
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected static final Stringprotected static final Stringprotected static final Stringprotected static final Stringprotected static final Stringprotected static final Stringprotected static final Stringprotected static final Stringprotected static final Stringprotected static final intprotected static final Stringprotected static final Stringprotected static final String -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected StringgetAncillaryBundleTemplateId(String bundleTemplateId) Returns the id of the Ancillary Product Bundle Template.protected BundleSelectionCriteriaModelgetAncillaryProductBundleSelectionCriteria(CatalogVersionModel catalogVersion, String bundleTemplateId) Returns theBundleSelectionCriteriaModelinstance ofAutoPickBundleSelectionCriteriaModelfor the Ancillary product bundle template.protected BundleTemplateStatusModelReturns the bundle template status modelprotected de.hybris.platform.enumeration.EnumerationServiceGets enumeration service.protected StringgetFareBundleTemplateId(String bundleTemplateId) Returns the id of the Fare Product Bundle Template.protected BundleSelectionCriteriaModelgetFareProductBundleSelectionCriteria(CatalogVersionModel catalogVersion, String bundleTemplateId) Returns theBundleSelectionCriteriaModelinstance ofPickExactlyNBundleSelectionCriteriaModelfor the Fare product bundle template.protected de.hybris.platform.servicelayer.model.ModelServiceGets model service.protected TravelBundleTemplateServiceGets travel bundle template service.protected TravelBundleTemplateStatusServiceGets travel bundle template status service.voidperform(com.hybris.cockpitng.config.jaxb.wizard.CustomType customType, com.hybris.cockpitng.widgets.configurableflow.FlowActionHandlerAdapter flowActionHandlerAdapter, Map<String, String> map) voidsetEnumerationService(de.hybris.platform.enumeration.EnumerationService enumerationService) Sets enumeration service.voidsetModelService(de.hybris.platform.servicelayer.model.ModelService modelService) Sets model service.voidsetTravelBundleTemplateService(TravelBundleTemplateService travelBundleTemplateService) Sets travel bundle template service.voidsetTravelBundleTemplateStatusService(TravelBundleTemplateStatusService travelBundleTemplateStatusService) Sets travel bundle template status service.protected booleanvalidateUniqueBundleId(String bundleTemplateId, String version) Validate the bundleTemplateId that should be unique for the given catalog.
-
Field Details
-
CREATE_BUNDLE_WIZARD_ERROR_TITLE
- See Also:
-
CREATE_BUNDLE_WIZARD_MANDATORY_FIELD_ERROR_MESSAGE
- See Also:
-
CREATE_BUNDLE_WIZARD_DUPLICATE_ID_ERROR_MESSAGE
- See Also:
-
CREATE_BUNDLE_TEMPLATE_ITEM_ID
- See Also:
-
CREATE_FARE_BUNDLE_TEMPLATE_ITEM_ID
- See Also:
-
CREATE_ANCILLARY_BUNDLE_TEMPLATE_ITEM_ID
- See Also:
-
FARE_PRODUCT_BUNDLE_ID
- See Also:
-
ANCILLARY_PRODUCT_BUNDLE_ID
- See Also:
-
DEFAULT_STATUS
- See Also:
-
PICK_EXACTLY_ONE_ID
- See Also:
-
AUTO_PICK_BUNDLE_SELECTION_ID
- See Also:
-
BUNDLE_TYPE_NAME_ID
- See Also:
-
DEFAULT_N_VALUE
protected static final int DEFAULT_N_VALUE- See Also:
-
-
Constructor Details
-
ShoppingCreateBundleChildTemplatesHandler
public ShoppingCreateBundleChildTemplatesHandler()
-
-
Method Details
-
perform
public void perform(com.hybris.cockpitng.config.jaxb.wizard.CustomType customType, com.hybris.cockpitng.widgets.configurableflow.FlowActionHandlerAdapter flowActionHandlerAdapter, Map<String, String> map) - Specified by:
performin interfacecom.hybris.cockpitng.widgets.configurableflow.FlowActionHandler
-
validateUniqueBundleId
Validate the bundleTemplateId that should be unique for the given catalog.- Parameters:
bundleTemplateId- as the bundle template idversion- as the version- Returns:
- true if the id is valid, false otherwise
-
getBundleTemplateStatus
Returns the bundle template status model- Returns:
- bundle template status model
-
getFareBundleTemplateId
Returns the id of the Fare Product Bundle Template. The id is build as a concat of the {#FARE_PRODUCT_BUNDLE_ID} constant and the id of the parentBundleTemplate id.- Parameters:
bundleTemplateId- the bundle template id- Returns:
- a string representing the id of the Fare Product Bundle Template
-
getAncillaryBundleTemplateId
Returns the id of the Ancillary Product Bundle Template. The id is build as a concat of the {#ANCILLARY_PRODUCT_BUNDLE_ID} constant and the id of the parentBundleTemplate id.- Parameters:
bundleTemplateId- the bundle template id- Returns:
- a string representing the id of the Ancillary Product Bundle Template
-
getFareProductBundleSelectionCriteria
protected BundleSelectionCriteriaModel getFareProductBundleSelectionCriteria(CatalogVersionModel catalogVersion, String bundleTemplateId) Returns theBundleSelectionCriteriaModelinstance ofPickExactlyNBundleSelectionCriteriaModelfor the Fare product bundle template.- Parameters:
catalogVersion- as the catalog versionbundleTemplateId- as the bundle template id- Returns:
- the bundle selection criteria model
-
getAncillaryProductBundleSelectionCriteria
protected BundleSelectionCriteriaModel getAncillaryProductBundleSelectionCriteria(CatalogVersionModel catalogVersion, String bundleTemplateId) Returns theBundleSelectionCriteriaModelinstance ofAutoPickBundleSelectionCriteriaModelfor the Ancillary product bundle template.- Parameters:
catalogVersion- as the catalog versionbundleTemplateId- as the bundle template id- Returns:
- the bundle selection criteria model
-
getTravelBundleTemplateService
Gets travel bundle template service.- Returns:
- the travel bundle template service
-
setTravelBundleTemplateService
Sets travel bundle template service.- Parameters:
travelBundleTemplateService- the travel bundle template service
-
getTravelBundleTemplateStatusService
Gets travel bundle template status service.- Returns:
- the travel bundle template status service
-
setTravelBundleTemplateStatusService
public void setTravelBundleTemplateStatusService(TravelBundleTemplateStatusService travelBundleTemplateStatusService) Sets travel bundle template status service.- Parameters:
travelBundleTemplateStatusService- the travel bundle template status service
-
getModelService
protected de.hybris.platform.servicelayer.model.ModelService getModelService()Gets model service.- Returns:
- the model service
-
setModelService
public void setModelService(de.hybris.platform.servicelayer.model.ModelService modelService) Sets model service.- Parameters:
modelService- the model service
-
getEnumerationService
protected de.hybris.platform.enumeration.EnumerationService getEnumerationService()Gets enumeration service.- Returns:
- the enumeration service
-
setEnumerationService
public void setEnumerationService(de.hybris.platform.enumeration.EnumerationService enumerationService) Sets enumeration service.- Parameters:
enumerationService- the enumeration service
-