Press Ctrl / CMD + C to copy this to your clipboard.
This post will be reported to the moderators as potential spam to be looked at
Hey :)
Im trying to add products from the serverside, and it works .. almost :)
Im doing this in a base request :
HttpRequest request = HttpContext.Current.Request; int storeId = Convert.ToInt32(request["storeId"]); string productIdentifier = request["productIdentifier"]; int quantity = Convert.ToInt32(request["quantity"]); Guid guid = Guid.Parse(request["guid"]); Order o = TC.SetCurrentOrder(storeId, guid); TC.SetCurrentPaymentCountry(storeId, 1); TC.SetCurrentCurrency(storeId, 1); o.OrderLines.AddOrUpdate(productIdentifier, quantity);
The order gets added but it has no price, but if I afterwords add an other using HTML form, the price is calculated.
When i call the price Obj of the orderline it just return Null
So what am i missing ?
got it working -.-
forgot to call o.Save();
is working on a reply...
Write your reply to:
Upload image
Image will be uploaded when post is submitted
Adding to cart from serverside
Hey :)
Im trying to add products from the serverside, and it works .. almost :)
Im doing this in a base request :
The order gets added but it has no price, but if I afterwords add an other using HTML form, the price is calculated.
When i call the price Obj of the orderline it just return Null
So what am i missing ?
got it working -.-
forgot to call o.Save();
is working on a reply...