Interface CsrCartOperationService
-
- All Known Implementing Classes:
DefaultCsrCartOperationService
public interface CsrCartOperationServiceService for orchestrating the different CSR triggered workflows on various cart operations. Delegates to external services as needed to process each operation.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Deprecated Methods Modifier and Type Method Description voidcancelCSRCart(@NonNull com.broadleafcommerce.cart.client.domain.Cart csrCart, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)Cancels the provided CSR cart.com.broadleafcommerce.cart.client.domain.CartcloneCartIntoStatus(com.broadleafcommerce.cart.client.domain.Cart cart, com.broadleafcommerce.cart.client.domain.enums.CartStatus status, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)Clone the given cart into a new cart with the given status.com.broadleafcommerce.cart.client.domain.CartcloneCsrCartFromInProcess(@NonNull com.broadleafcommerce.cart.client.domain.Cart cartToClone, com.broadleafcommerce.cart.client.domain.Cart csrCart, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)Clone the customer's in-process cart into a new csr-owned cart.com.broadleafcommerce.cart.client.domain.CartcloneCsrCartFromInProcess(com.broadleafcommerce.cart.client.domain.Cart csrCart, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)Deprecated.in favor forcloneCsrCartFromInProcess(Cart, Cart, ContextInfo)com.broadleafcommerce.cart.client.domain.CartoverrideCartItemPrice(com.broadleafcommerce.cart.client.domain.Cart cart, String cartItemId, OverridePriceRequest overridePrice, boolean allowPriceCart, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)Override the unit price on the cart item.com.broadleafcommerce.cart.client.domain.CartoverrideFulfillmentGroupPrice(com.broadleafcommerce.cart.client.domain.Cart cart, String fulfillmentGroupId, OverridePriceRequest overridePrice, boolean allowPriceCart, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)Override the total fulfillment price on the fulfillment group.
-
-
-
Method Detail
-
overrideCartItemPrice
com.broadleafcommerce.cart.client.domain.Cart overrideCartItemPrice(com.broadleafcommerce.cart.client.domain.Cart cart, String cartItemId, OverridePriceRequest overridePrice, boolean allowPriceCart, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)Override the unit price on the cart item.- Parameters:
cart- The id of the cart on which to perform the operation.cartItemId- The id of the cart item on which to perform the operation.overridePrice- The override price to set as the unit price on the cart item.allowPriceCart- Whether to allow the cart to be priced after updatingcontextInfo- Context information around sandbox and multitenant state.- Returns:
- The cart with the updated item.
-
overrideFulfillmentGroupPrice
com.broadleafcommerce.cart.client.domain.Cart overrideFulfillmentGroupPrice(com.broadleafcommerce.cart.client.domain.Cart cart, String fulfillmentGroupId, OverridePriceRequest overridePrice, boolean allowPriceCart, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)Override the total fulfillment price on the fulfillment group.- Parameters:
cart- The id of the cart on which to perform the operation.fulfillmentGroupId- The id of the fulfillment group on which to perform the operation.overridePrice- The override price to set as the total fulfillment price.allowPriceCart- Whether to allow the cart to be priced after updatingcontextInfo- Context information around sandbox and multitenant state.- Returns:
- The cart with the updated fulfillment group.
-
cloneCsrCartFromInProcess
@Deprecated com.broadleafcommerce.cart.client.domain.Cart cloneCsrCartFromInProcess(@Nullable com.broadleafcommerce.cart.client.domain.Cart csrCart, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)
Deprecated.in favor forcloneCsrCartFromInProcess(Cart, Cart, ContextInfo)Clone the customer's in-process cart into a new csr-owned cart.- Parameters:
csrCart- The CSR-owned cart which will be replaced by the cloned cartcontextInfo- Context information around sandbox and multitenant state.- Returns:
- The CSR-owned clone of the customer's in-process cart
-
cloneCsrCartFromInProcess
com.broadleafcommerce.cart.client.domain.Cart cloneCsrCartFromInProcess(@NonNull @NonNull com.broadleafcommerce.cart.client.domain.Cart cartToClone, @Nullable com.broadleafcommerce.cart.client.domain.Cart csrCart, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)Clone the customer's in-process cart into a new csr-owned cart.- Parameters:
cartToClone- the in-process cart to clonecsrCart- the CSR-owned cart which will be replaced by the cloned cartcontextInfo- Context information around sandbox and multitenant state.- Returns:
- The CSR-owned clone of the customer's in-process cart
-
cancelCSRCart
void cancelCSRCart(@NonNull @NonNull com.broadleafcommerce.cart.client.domain.Cart csrCart, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)Cancels the provided CSR cart.- Parameters:
csrCart- the cart to cancelcontextInfo- the contxt info
-
cloneCartIntoStatus
com.broadleafcommerce.cart.client.domain.Cart cloneCartIntoStatus(com.broadleafcommerce.cart.client.domain.Cart cart, com.broadleafcommerce.cart.client.domain.enums.CartStatus status, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)Clone the given cart into a new cart with the given status.- Parameters:
cart- The original cart which will be clonedstatus- The new status for the cloned cartcontextInfo- Context information around sandbox and multitenant state.- Returns:
- The newly cloned cart
-
-