Portal Engine Questions on portal engine and web parts.
Version 7.x > Portal Engine > E-commerce View modes: 
User avatar
Member
Member
Sonam.Marda-bitwiseglobal - 1/23/2014 8:24:17 AM
   
E-commerce
Hi,

I am using e-commerce module of Kentico. I am creating an inline user control wherein I need to get the current order details like order id, amount, etc. How can I get these details through code or API.

Thanks,
Sonam

User avatar
Certified Developer 10
Certified Developer 10
josha-bpstudios - 1/23/2014 8:59:53 AM
   
RE:E-commerce
OrderInfo oi = OrderInfoProvider.GetOrderInfo(orderid); will return the orderinfo object, all you have to do is pass in the orderid of an order as an integer. Once you create the object just go through the properties of it and you will see all of the items that you can access.

User avatar
Certified Developer 10
Certified Developer 10
josha-bpstudios - 1/23/2014 9:27:45 AM
   
RE:E-commerce
Also, if you need to know how to get an orderid, just get a dataset of orders and then set your where clause so that you could get the orders that you want based on your criteria.

DataSet dsOrders = OrderInfoProvider.GetOrders(siteid) // Note: this method has multiple signatures, so you an also call it like this OrderInfoProvider.GetOrders(string where, string orderby,int topn, int siteid);