Ejemplo n.º 1
0
        // GET: PurchaseReturns
        public ActionResult Index()
        {
            try
            {
                //LogHandler.WriteLog("PurchaseReturn Index page requested by #UserId");
                var qList = purchasereturnrepository.GetAllPurchaseReturns().ToList();



                PurchaseReturnViewModels model = new PurchaseReturnViewModels();
                model.PurchaseReturnList = qList;


                //Bind Branch
                var BranchList = purchasereturnrepository.GetBranchList().ToList();
                model.BranchList = BranchList;

                //Bind VAT
                var VATList = purchasereturnrepository.GetVAT().ToList();
                model.VATList = VATList;

                ////Bind Product
                var ProductList = purchasereturnrepository.GetProductList().ToList();
                model.ProductList = ProductList;

                ////Bind Businesspartner
                var BusinessParterList = purchasereturnrepository.GetBusinessPartnerList().ToList();
                model.BusinessPartnerList = BusinessParterList;

                //Bind PurchaseQuotation
                var qList1 = purchasereturnrepository.GetAllPurchaseInvoice().ToList();
                model.PurchaseInvoiceList = qList1;


                return(View(model));
            }
            catch (Exception ex)
            {
                ExceptionHandler.LogException(ex);
                ViewBag.AppErrorMessage = ex.Message;
                return(View("Error"));
            }
        }