Class ValidateProductOptionsActivity

java.lang.Object
org.broadleafcommerce.core.workflow.BaseActivity<ProcessContext<CheckoutSeed>>
org.broadleafcommerce.core.checkout.service.workflow.ValidateProductOptionsActivity
All Implemented Interfaces:
Activity<ProcessContext<CheckoutSeed>>, org.springframework.beans.factory.Aware, org.springframework.beans.factory.BeanNameAware, org.springframework.core.Ordered

@Component("blValidateProductOptionsActivity") public class ValidateProductOptionsActivity extends BaseActivity<ProcessContext<CheckoutSeed>>
This is an required activity to valiate if required product options are in the order.

If sku browsing is enabled, product option data will not be available. In this case, the following validation is skipped.

Author:
Priyesh Patel
  • Field Details

  • Constructor Details

    • ValidateProductOptionsActivity

      public ValidateProductOptionsActivity()
  • Method Details

    • execute

      Description copied from interface: Activity
      Called by the encompassing processor to activate the execution of the Activity
      Parameters:
      context - - process context for this workflow
      Returns:
      resulting process context
      Throws:
      Exception
    • getOrderItems

      protected List<DiscreteOrderItem> getOrderItems(Order order)
    • shouldValidateWithException

      protected boolean shouldValidateWithException(boolean hasValidationType, boolean hasStrategy, boolean isAddOrNoneType, boolean isSubmitType)
    • isMissingRequiredAttribute

      protected boolean isMissingRequiredAttribute(boolean isRequired, boolean hasStrategy, boolean isAddOrNoneType, boolean isSubmitType, String attributeValue)
    • getProductOptionValidationStrategyType

      public ProductOptionValidationStrategyType getProductOptionValidationStrategyType()