Class CancelStatusChangeHandler
java.lang.Object
com.broadleafcommerce.orderoperation.service.handler.AbstractFulfillmentStatusChangeHandler
com.broadleafcommerce.orderoperation.service.handler.CancelStatusChangeHandler
- All Implemented Interfaces:
FulfillmentStatusChangeHandler
Handles changing a fulfillment from the status
OrderFulfillmentStatus.NEW
,
OrderFulfillmentStatus.CAPTURING_PAYMENT
,
OrderFulfillmentStatus.PAYMENT_CAPTURE_FAILED
to
OrderFulfillmentStatus.CANCELLED
.-
Constructor Summary
ConstructorDescriptionCancelStatusChangeHandler
(FulfillmentSplittingService<com.broadleafcommerce.order.client.domain.OrderFulfillment> splittingService, FulfillmentProvider<com.broadleafcommerce.order.client.domain.OrderFulfillment> fulfillmentProvider, OrderProvider<com.broadleafcommerce.order.client.domain.Order> orderProvider, FulfillmentCancelledProducer messageProducer, com.broadleafcommerce.common.extension.TypeFactory typeFactory) -
Method Summary
Modifier and TypeMethodDescriptionprotected FulfillmentCancelledProducer
protected String
protected com.broadleafcommerce.order.client.domain.OrderFulfillment
postProcessStatusChange
(FulfillmentStatusChangeRequest request, String originalStatus, List<com.broadleafcommerce.order.client.domain.OrderFulfillment> splitFulfillments, com.broadleafcommerce.order.client.domain.Order order, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo) Perform any additional handling after the fulfillment has changed status.Methods inherited from class com.broadleafcommerce.orderoperation.service.handler.AbstractFulfillmentStatusChangeHandler
addAdditionalOrderFulfillmentFields, addAdditionalOrderFulfillmentFields, canHandle, getDetachedDurableMessageSender, getFulfillmentProvider, getFulfillmentWithChangedStatus, getOrderProvider, getProperties, getSplittingService, getTypeFactory, process, processSingleFulfillment, processSplitFulfillments, requestingCompleteFulfillment, sendFulfillmentStatusChangeEvent, setDetachedDurableMessageSender, setProperties
-
Constructor Details
-
CancelStatusChangeHandler
public CancelStatusChangeHandler(FulfillmentSplittingService<com.broadleafcommerce.order.client.domain.OrderFulfillment> splittingService, FulfillmentProvider<com.broadleafcommerce.order.client.domain.OrderFulfillment> fulfillmentProvider, OrderProvider<com.broadleafcommerce.order.client.domain.Order> orderProvider, FulfillmentCancelledProducer messageProducer, com.broadleafcommerce.common.extension.TypeFactory typeFactory)
-
-
Method Details
-
getValidTargetStatus
- Specified by:
getValidTargetStatus
in classAbstractFulfillmentStatusChangeHandler
-
getValidOriginatingStatuses
- Specified by:
getValidOriginatingStatuses
in classAbstractFulfillmentStatusChangeHandler
-
postProcessStatusChange
protected com.broadleafcommerce.order.client.domain.OrderFulfillment postProcessStatusChange(FulfillmentStatusChangeRequest request, String originalStatus, List<com.broadleafcommerce.order.client.domain.OrderFulfillment> splitFulfillments, com.broadleafcommerce.order.client.domain.Order order, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo) Description copied from class:AbstractFulfillmentStatusChangeHandler
Perform any additional handling after the fulfillment has changed status.- Overrides:
postProcessStatusChange
in classAbstractFulfillmentStatusChangeHandler
- Parameters:
request
- the status change requestoriginalStatus
- the original status of the fulfillment before status changesplitFulfillments
- the fulfillments involved in the status changeorder
- the order which contains the fulfillmentscontextInfo
- context information around sandbox and multitenant state- Returns:
- the fulfillment which changed status
-
getMessageProducer
-