November Happy Hour will be moved to Thursday December 5th.

Fetching Orders data based on Organization ID

Vote:
 

Hi All,

Is there any specific method to fetch all the orders data based on organization id.

Can you please let me know if there are any existing methods or api's related to it.

Regards,

Manik

#199860
Dec 14, 2018 14:02
Vote:
 

You can use CustomerContext.GetCustomerContactsInOrganization to get all contacts in one organization, then use IOrderRepository.Load<IPurchaseOrder>(customerId, name) or OrderContext.Current.GetPurchaseOrders(customerId) for loading orders for each contact, then combine the results.

#199863
Dec 14, 2018 14:30
Vote:
 

Thanks i have tried this , but i was looking whether we can user ordersearchparameters or OrderContext to fetch the same

#199864
Dec 14, 2018 14:59
This topic was created over six months ago and has been resolved. If you have a similar question, please create a new topic and refer to this one.
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.