menu

SiteGenesis / Server-side JS / Class: ProductListModel

module:models/ProductListModel~ ProductListModel

new ProductListModel()

ProductList helper function providing enhanced functionality for wishlists and other product lists.

Source:

Methods

(static) replaceProductListItem() → {Object}

Attempts to replace a product in the gift registry.

Source:
Returns:

JSON object indicating the error state if any pipelets called throw a PIPELET_ERROR.

Type
Object

(static) search(simpleForm, listType) → {dw.util.Collection.<dw.customer.ProductList>}

Searches for a Product List

Parameters:
Name Type Description
simpleForm dw.web.FormGroup

ProductList simple form

listType Number

dw.customer.ProductList.TYPE_* constant

Source:
Returns:
Type
dw.util.Collection.<dw.customer.ProductList>

isProductInProductList(product)

Check is product already in the wishlist.

Parameters:
Name Type Description
product dw.catalog.Product

The product to check

Source:

remove()

Deletes this Product List

Source:

updateItem(formListItems)

Updates an item in the Gift Registry

Parameters:
Name Type Description
formListItems dw.web.FormList
Source: