Пример #1
0
        public static skSales GetSalesObject(int SaleID)
        {
            DataFunctions DB = new DataFunctions();

            skSales SalesOBJ = DB.GetSalesDetails(SaleID);

            if (SalesOBJ != null)
            {
                return(SalesOBJ);
            }
            else
            {
                throw new Exception("No sale found !");
            }
        }
Пример #2
0
        public static void OpenSaleTab(skSales SaleObj)
        {
            ObjectMessenger om = new ObjectMessenger();


            if (SaleObj != null)
            {
                om.Send("TRANOBJ", SaleObj);
                UI.Enviroment.LoadNewTab("SalesDetailsView");
            }
            else
            {
                throw new Exception("No Sale with this ID can be found.");
            }
        }
Пример #3
0
        public static skSales GetSalesObject(int SaleID)
        {
            Proxies.AppDataClient DataClient = new Proxies.AppDataClient();
            try
            {
                DataClient.Open();

                skSales SalesOBJ = DataClient.GetSaleObject(SaleID).SalesObject;

                if (SalesOBJ != null)
                {
                    return(SalesOBJ);
                }
                else
                {
                    throw new Exception("No sale found !");
                }
            }
            finally
            {
                DataClient.Close();
            }
        }