Class ShoppingListServices
java.lang.Object
org.apache.ofbiz.order.shoppinglist.ShoppingListServices
Shopping List Services
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionautoDeleteAutoSaveShoppingList
(DispatchContext dctx, Map<String, ? extends Object> context) createListReorders
(DispatchContext dctx, Map<String, ? extends Object> context) makeListFromOrder
(DispatchContext dctx, Map<String, ? extends Object> context) static ShoppingCart
makeShoppingListCart
(ShoppingCart listCart, LocalDispatcher dispatcher, GenericValue shoppingList, Locale locale) Add a shoppinglist to an existing shoppingcartstatic ShoppingCart
makeShoppingListCart
(LocalDispatcher dispatcher, String shoppingListId, Locale locale) static ShoppingCart
makeShoppingListCart
(LocalDispatcher dispatcher, GenericValue shoppingList, Locale locale) Create a new shoppingCart form a shoppingListsetShoppingListRecurrence
(DispatchContext dctx, Map<String, ? extends Object> context) splitShipmentMethodString
(DispatchContext dctx, Map<String, ? extends Object> context) updateShoppingListQuantitiesFromOrder
(DispatchContext ctx, Map<String, ? extends Object> context) Given an orderId, this service will look through all its OrderItems and for each shoppingListItemId and shoppingListItemSeqId, update the quantity purchased in the ShoppingListItem entity.
-
Constructor Details
-
ShoppingListServices
public ShoppingListServices()
-
-
Method Details
-
setShoppingListRecurrence
-
createListReorders
-
splitShipmentMethodString
-
makeListFromOrder
-
makeShoppingListCart
public static ShoppingCart makeShoppingListCart(LocalDispatcher dispatcher, GenericValue shoppingList, Locale locale) Create a new shoppingCart form a shoppingList- Parameters:
dispatcher
- the local dispatchershoppingList
- a GenericValue object of the shopping listlocale
- the locale in use- Returns:
- returns a new shopping cart form a shopping list
-
makeShoppingListCart
public static ShoppingCart makeShoppingListCart(ShoppingCart listCart, LocalDispatcher dispatcher, GenericValue shoppingList, Locale locale) Add a shoppinglist to an existing shoppingcart- Parameters:
listCart
- the shopping cart listdispatcher
- the local dispatchershoppingList
- a GenericValue object of the shopping listlocale
- the locale in use- Returns:
- the modified shopping cart adding the shopping list elements
-
makeShoppingListCart
public static ShoppingCart makeShoppingListCart(LocalDispatcher dispatcher, String shoppingListId, Locale locale) -
updateShoppingListQuantitiesFromOrder
public static Map<String,Object> updateShoppingListQuantitiesFromOrder(DispatchContext ctx, Map<String, ? extends Object> context) Given an orderId, this service will look through all its OrderItems and for each shoppingListItemId and shoppingListItemSeqId, update the quantity purchased in the ShoppingListItem entity. Used for tracking how many of shopping list items are purchased. This service is mounted as a seca on storeOrder.- Parameters:
ctx
- - The DispatchContext that this service is operating incontext
- - Map containing the input parameters- Returns:
- Map with the result of the service, the output parameters
-
autoDeleteAutoSaveShoppingList
-