public class B2BCartsController
extends java.lang.Object
| Modifier and Type | Field and Description |
|---|---|
protected DataMapper |
dataMapper |
protected static java.lang.String |
DEFAULT_FIELD_SET |
protected UserFacade |
userFacade |
| Constructor and Description |
|---|
B2BCartsController() |
| Modifier and Type | Method and Description |
|---|---|
CartModificationListWsDTO |
addCartEntries(java.lang.String baseSiteId,
java.lang.String fields,
OrderEntryListWsDTO entries)
Adds more quantity to the cart of specific products in the cart based either in the product code or the
entryNumber.
|
CartModificationWsDTO |
addCartEntry(java.lang.String baseSiteId,
java.lang.String product,
long quantity,
java.lang.String fields)
Adds more quantity to the cart for a specific entry based on it's product code, if the product is already in the
cart the amount will be added to the existing quantity.
|
protected java.util.List<OrderEntryData> |
convertToData(OrderEntryListWsDTO entriesWS) |
protected CartModificationDataList |
getCartModificationDataList(java.util.List<CartModificationData> result) |
CartWsDTO |
getCurrentCart(java.lang.String fields) |
protected OrderEntryData |
getOrderEntryData(long quantity,
java.lang.String productCode,
java.lang.Integer entryNumber) |
CartWsDTO |
setCartCostCenter(java.lang.String costCenterId,
java.lang.String fields)
Set the cost center for the checkout cart
|
CartWsDTO |
setCartDeliveryAddress(java.lang.String addressId,
java.lang.String fields)
Set delivery address for the checkout cart
|
CartWsDTO |
setPaymentType(java.lang.String paymentType,
java.lang.String purchaseOrderNumber,
java.lang.String fields)
Set the payment type for the checkout cart; if purchaseOrderNumber is not null, also set it to the cart
|
CartModificationListWsDTO |
updateCartEntries(java.lang.String baseSiteId,
java.lang.String fields,
OrderEntryListWsDTO entries)
Updates the quantity for specific products in the cart based either in the product code or the entryNumber.
|
CartModificationWsDTO |
updateCartEntry(java.lang.String baseSiteId,
int entryNumber,
java.lang.Long quantity,
java.lang.String fields)
Updates the total amount of a specific product in the cart based on the entryNumber.
|
CartModificationWsDTO |
updateCartEntry(java.lang.String baseSiteId,
java.lang.String product,
java.lang.Integer entryNumber,
java.lang.Long quantity,
java.lang.String fields)
Updates the total amount of a specific product in the cart based either in the product code or the entryNumber.
|
protected UserFacade userFacade
protected static final java.lang.String DEFAULT_FIELD_SET
protected DataMapper dataMapper
public CartModificationWsDTO addCartEntry(java.lang.String baseSiteId, java.lang.String product, long quantity, java.lang.String fields)
baseSiteId - the id of the site.product - code of the product to be added to the cart.quantity - amount to be added.fields - level mapping configuration.public CartModificationWsDTO updateCartEntry(java.lang.String baseSiteId, int entryNumber, java.lang.Long quantity, java.lang.String fields)
baseSiteId - the id of the site.entryNumber - the id of the entry in the cart.quantity - new quantity for this entry.fields - level mapping configuration.public CartModificationWsDTO updateCartEntry(java.lang.String baseSiteId, java.lang.String product, java.lang.Integer entryNumber, java.lang.Long quantity, java.lang.String fields)
baseSiteId - the id of the site.product - code of the product to be added to the cart, this code is not considered if an entryNumber is passed.entryNumber - the id of the entry in the cart, this parameter takes precedence over the product code.quantity - new quantity for this product.fields - level mapping configuration.public CartModificationListWsDTO addCartEntries(java.lang.String baseSiteId, java.lang.String fields, OrderEntryListWsDTO entries)
baseSiteId - the id of the site.fields - level mapping configuration.entries - list of entries containing the amount to add and the product code or the entryNumber.public CartModificationListWsDTO updateCartEntries(java.lang.String baseSiteId, java.lang.String fields, OrderEntryListWsDTO entries)
baseSiteId - the id of the site.fields - level mapping configuration.entries - list of entries containing the amount to add and the product code or the entryNumber.public CartWsDTO setCartCostCenter(java.lang.String costCenterId, java.lang.String fields)
costCenterId - fields - public CartWsDTO setPaymentType(java.lang.String paymentType, java.lang.String purchaseOrderNumber, java.lang.String fields)
paymentType - purchaseOrderNumber - fields - public CartWsDTO setCartDeliveryAddress(java.lang.String addressId, java.lang.String fields)
addressId - fields - NoCheckoutCartExceptionpublic CartWsDTO getCurrentCart(java.lang.String fields)
protected CartModificationDataList getCartModificationDataList(java.util.List<CartModificationData> result)
protected java.util.List<OrderEntryData> convertToData(OrderEntryListWsDTO entriesWS)
protected OrderEntryData getOrderEntryData(long quantity, java.lang.String productCode, java.lang.Integer entryNumber)
Copyright © 2017 SAP SE. All Rights Reserved.