Fetching Past 30 days Recent orders

Manikantha S M R V
Member since: 2017
 

Hi All,

I am trying to fetch past 30 days order history(similar to episerver commerce admin functionality). 

I am able to fetch for a particular customer but not able to fetch as whole.

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

Thanks in advance.

Regards,

Manik

#199684 Dec 05, 2018 14:15
  • Quan Mai
    Member since: 2011
     

    You can use this parameters and options for orders modified in last 30 days

                    OrderSearchParameters parameters = new OrderSearchParameters
                    {
                        SqlMetaWhereClause = $"Meta.Modified <  GETDATE() - 30 ",
                    };
    
                    OrderSearchOptions options = new OrderSearchOptions {Namespace = "Mediachase.Commerce.Orders"};

    Or use Meta.Created for orders created in last 30 days

    #199685 Dec 05, 2018 14:58
  • Manikantha S M R V
    Member since: 2017
     

    Thanks for the information

    #199696 Dec 06, 2018 14:26