HOTFEATURE 2015.5, 2015.4, 2015.3 - Info items can be added using the client api now.
Info items can be added using the client api now. To accomplish this, two new fields have been added to the item model: CartItemType and SpecialItemData. These fields have the same functionality as the remote carting parameters ItemType and SpecialItemData
https://americommerce.zendesk.com/hc/en-us/articles/201904880-Embedded-Commerce-Parameter-List
Here's an example of their usage:
item = {
itemName: itemName,
itemNumber: itemNumber,
price: price,
quantity: 1,
MaxQuantity: MaxQuantity,
CartItemType: "Info",
SpecialItemData: "Info Only Data",
IsHidden: true
};
AC.cart.add(item, function(response) { var cart = response.cart || response.data; // See the readme for an explanation on why this is necessary. updateCartCount(cart); });
https://americommerce.zendesk.com/hc/en-us/articles/201904880-Embedded-Commerce-Parameter-List
Here's an example of their usage:
item = {
itemName: itemName,
itemNumber: itemNumber,
price: price,
quantity: 1,
MaxQuantity: MaxQuantity,
CartItemType: "Info",
SpecialItemData: "Info Only Data",
IsHidden: true
};
AC.cart.add(item, function(response) { var cart = response.cart || response.data; // See the readme for an explanation on why this is necessary. updateCartCount(cart); });
0
Please sign in to leave a comment.
Comments
0 comments