Hello!
I have a page in my website where there are ordinary products which are loaded in from DW-backend by setting the index in the DW-admin app for ecommerce, so then they appear in the GetLoop("Products"). But then on this same page you should also be able to buy 'add-ons' for these products which I load in via ProductService.GetAllProducts() or whatever, and then my plan is to add these products to the cart via AJAX and the ordinary product via the normal form post. Basically, I both get products from DW-backend and from the ProductService.
My problem is though that I can't seem to be able to put my AJAX products in the cart like a want to. I found this link http://wrap.dynamicweb-cms.com/produkter/clothing/accessories which had some good javascript on it to save the products one by one by calling the url with query params like this: url/moreurl&cartcmd=add&ProductID=myproduct&Quantity=1, but then this becomes very complicated it seems when handling multiple products and I don't have the product.GetString("Ecom:Product.LoopCounter")-thing which appears to append on all properties like QuantityXX, ProductIDXX etc, which it does when dealing with this kind of thing and the products come from DW-backend and you can call @product.GetValue("Ecom:Product.Form.Multi.HiddenFields").
Is there basically anyway to go around this and add multiple products to the cart with addMulti, but not getting the products from DW-backend? Or do I simply have to call url/moreurl&cartcmd=add&ProductID=myproduct&Quantity=1 several times to add all my products?