Esempio n. 1
0
        //Payments
        public ActionResult Payments(int id = 0)
        {
            var paymentlist = new List <Payment>();
            var method      = new OrderCrudViewModel();

            try
            {
                paymentlist = method.GetPaymentsDetail(id, "ShopManager");
                if (paymentlist.Count == 0)
                {
                    TempData["PaymentHomeMessage"] = "No Payment History Yet Now";
                }
            }
            catch (Exception e)
            {
                TempData["PaymentHomeMessage"] = e.Message;
            }

            return(View(paymentlist));
        }
Esempio n. 2
0
        public ActionResult CustomerPayments(int id = 0)
        {
            var paymentlist = new List <Payment>();
            var method      = new OrderCrudViewModel();

            try
            {
                paymentlist = method.GetPaymentsDetail(id, "Customer");
                if (paymentlist.Count == 0)
                {
                    TempData["PaymentHomeMessage"] = "No Payment History Yet Now";
                }
            }
            catch (Exception e)
            {
                TempData["PaymentHomeMessage"] = e.Message;
            }
            var viewmodel = new PaymentViewModel();

            viewmodel.PaymentList = paymentlist;
            return(View(viewmodel));
        }