@Component(value="blValidateAddRequestActivity") public class ValidateAddRequestActivity extends BaseActivity<ProcessContext<CartOperationRequest>>
| Modifier and Type | Field and Description |
|---|---|
protected CatalogService |
catalogService |
protected ValidateAddRequestActivityExtensionManager |
extensionManager |
static int |
ORDER |
protected OrderItemRequestValidationService |
orderItemRequestValidationService |
protected OrderItemService |
orderItemService |
protected OrderService |
orderService |
protected ProductOptionValidationService |
productOptionValidationService |
automaticallyRegisterRollbackHandler, beanName, errorHandler, order, rollbackHandler, rollbackRegion, stateConfiguration| Constructor and Description |
|---|
ValidateAddRequestActivity() |
| Modifier and Type | Method and Description |
|---|---|
protected void |
addSkuToCart(Sku sku,
OrderItemRequestDTO orderItemRequestDTO,
Product product,
CartOperationRequest request) |
protected boolean |
canSellDefaultSku(Product product) |
protected Product |
determineProduct(OrderItemRequestDTO orderItemRequestDTO) |
protected Sku |
determineSku(Product product,
Long skuId,
Map<String,String> attributeValues,
ActivityMessages messages) |
ProcessContext<CartOperationRequest> |
execute(ProcessContext<CartOperationRequest> context)
Called by the encompassing processor to activate
the execution of the Activity
|
protected Sku |
findMatchingSku(Product product,
Map<String,String> attributeValuesForSku) |
protected Sku |
findMatchingSku(Product product,
Map<String,String> attributeValues,
ActivityMessages messages) |
protected void |
handleIfNonDiscreteOI(OrderItemRequestDTO orderItemRequestDTO) |
protected void |
handleIfNoSku(OrderItemRequestDTO orderItemRequestDTO,
Product product) |
protected boolean |
hasPrice(NonDiscreteOrderItemRequestDTO ndr) |
protected boolean |
hasQuantity(Integer orderItemQuantity) |
protected boolean |
hasSameCurrency(OrderItemRequestDTO orderItemRequestDTO,
CartOperationRequest request,
Sku sku) |
protected boolean |
hasSkuOrIsNonDiscreteOI(Sku sku,
OrderItemRequestDTO orderItemRequestDTO) |
protected boolean |
shouldValidateWithException(boolean isRequired,
boolean isAddOrNoneType,
String attributeValue,
boolean hasStrategy) |
protected ProcessContext<CartOperationRequest> |
validate(ProcessContext<CartOperationRequest> context) |
protected void |
validateIfParentOrderItemExists(OrderItemRequestDTO orderItemRequestDTO) |
getAutomaticallyRegisterRollbackHandler, getBeanName, getErrorHandler, getOrder, getRollbackHandler, getRollbackRegion, getStateConfiguration, setAutomaticallyRegisterRollbackHandler, setBeanName, setErrorHandler, setOrder, setRollbackHandler, setRollbackRegion, setStateConfiguration, shouldExecutepublic static final int ORDER
protected OrderItemRequestValidationService orderItemRequestValidationService
protected OrderService orderService
protected CatalogService catalogService
protected ProductOptionValidationService productOptionValidationService
protected OrderItemService orderItemService
protected ValidateAddRequestActivityExtensionManager extensionManager
public ProcessContext<CartOperationRequest> execute(ProcessContext<CartOperationRequest> context) throws Exception
Activitycontext - - process context for this workflowExceptionprotected ProcessContext<CartOperationRequest> validate(ProcessContext<CartOperationRequest> context)
protected boolean hasQuantity(Integer orderItemQuantity)
protected Product determineProduct(OrderItemRequestDTO orderItemRequestDTO)
protected Sku determineSku(Product product, Long skuId, Map<String,String> attributeValues, ActivityMessages messages) throws RequiredAttributeNotProvidedException
protected boolean canSellDefaultSku(Product product)
protected Sku findMatchingSku(Product product, Map<String,String> attributeValues, ActivityMessages messages) throws RequiredAttributeNotProvidedException
protected boolean shouldValidateWithException(boolean isRequired,
boolean isAddOrNoneType,
String attributeValue,
boolean hasStrategy)
protected Sku findMatchingSku(Product product, Map<String,String> attributeValuesForSku)
protected void addSkuToCart(Sku sku, OrderItemRequestDTO orderItemRequestDTO, Product product, CartOperationRequest request)
protected boolean hasSkuOrIsNonDiscreteOI(Sku sku, OrderItemRequestDTO orderItemRequestDTO)
protected void handleIfNoSku(OrderItemRequestDTO orderItemRequestDTO, Product product)
protected void handleIfNonDiscreteOI(OrderItemRequestDTO orderItemRequestDTO)
protected boolean hasPrice(NonDiscreteOrderItemRequestDTO ndr)
protected boolean hasSameCurrency(OrderItemRequestDTO orderItemRequestDTO, CartOperationRequest request, Sku sku)
protected void validateIfParentOrderItemExists(OrderItemRequestDTO orderItemRequestDTO)
Copyright © 2025. All rights reserved.