コード例 #1
0
        internal static DataTable GetOrdersList(string customerSearchTerm, string orderSearchTerm, DateTime?startDate, DateTime?endDate, int?resultMaxCount)
        {
            ApplicationLog.Log(
                SalesOrderActions.LogSource,
                "Getting the list of sales orders for a customer",
                LogTraceLevel.Trace);

            DataTable salesOrders;
            bool      retVal  = false;
            string    comment = string.Empty;

            try
            {
                salesOrders = SalesOrder.GetCustomerOrdersList(ref retVal, ref comment, customerSearchTerm, orderSearchTerm, startDate, endDate, resultMaxCount);
            }
            catch (PosisException px)
            {
                ApplicationExceptionHandler.HandleException(SalesOrderActions.LogSource, px);
                throw;
            }
            catch (Exception x)
            {
                ApplicationExceptionHandler.HandleException(SalesOrderActions.LogSource, x);
                throw new PosisException(52300, x);
            }
            return(salesOrders);
        }