Hi,
I'm looking for some examples of how to use the AddToFavorite with the api.
I need to save a product to a certain list using the following code:
foreach (CustomerProductList customerProductList in customerProductLists)
{
Product product = new Product();
product = new ProductService().GetProductByNumber(productNo, true);
CustomerProductList.AddToFavorites(product.Id, product.VariantId, product.LanguageId, customerProductList.ID);
CustomerProductList.ClearCache(thisUser.ID);
}
When I look into the database, the table EcomCustomerFavoriteProducts is empty, even though I don't get any errors.
Any suggestions?
--
Best regards
Kurt Moskjaer Andersen