Example #1
0
        public ActionResult ListUnpaidBills()
        {
            var data = PaymentProcessor.GetUnpaidBills();
            List <AssignedBillViewModel> assignedBills = new List <AssignedBillViewModel>();

            foreach (var p in data)
            {
                assignedBills.Add(new AssignedBillViewModel
                {
                    BillName  = p.BillName,
                    FirstName = p.FirstName,
                    LastName  = p.LastName,
                    AmountDue = p.AmountDue,
                    DueDate   = p.DueDate
                });
            }
            return(View(assignedBills));
        }