ePages 7.47.0 - DE_EPAGES/ShoppingList/API/ShoppingList.pm

Package DE_EPAGES::ShoppingList::API::ShoppingList

This package provides the interface for ShoppingList.

@EXPORT_OK
AddProductToShoppingList
GetUnityShoppingList

Functions

AddProductToShoppingList
GetUnityShoppingList

AddProductToShoppingList

Adds product to the given shopping list.

Syntax
AddProductToShoppingList($ShoppingList, $Product, $Shop, $hParams);
Input
$ShoppingList (object)
shopping list
$Product (object)
product
$Shop (object)
shop
$hParams (ref.hash)
optional parameters
  • Quantity - quantity default:1 - integer
  • LineItemGUID - line item GUID when added via basket - string
  • User - User object when added via login or registration - object

GetUnityShoppingList

Get the shopping list for an user The shopping list is automatically created unless $DoNotCreate is given

Syntax
GetUnityShoppingList($User, $DoNotCreate);
Input
$User (object)
user
$DoNotCreate (optional) (boolean)
do not create the shopping list automatically
Return
$ShoppingList (object)
shopping list object