Пример #1
0
        public ActionResult DashBoard()
        {
            List <BillingScoreBoardDetail> Filteredbillscoreboard    = new List <BillingScoreBoardDetail>();
            List <BillingScoreBoardDetail> billscoreboard            = _DashboardDao.GetBillScoreBoard(SessionManager.UserId);
            List <BillingScoreBoardDetail> billunsubmittedscoreboard = _DashboardDao.GetBillScoreBoardUnsubmitted(SessionManager.UserId);

            var vunsubmitted = billscoreboard.Where(x => (x.BillStatus == BillStatus.Complete || x.BillStatus == BillStatus.Bill)).Distinct();

            //var filteredlist = billunsubmittedscoreboard.Intersect(billscoreboard).ToList();

            var filteredlist = billunsubmittedscoreboard.Where(x => !billscoreboard.Any(y => y.ClaimId == x.ClaimId));

            //billunsubmittedscoreboard.Clear();
            Filteredbillscoreboard.AddRange(filteredlist);
            Filteredbillscoreboard.AddRange(vunsubmitted);


            ViewBag.TotalSubmittedBill   = billscoreboard.Where(x => (x.BillStatus != BillStatus.Complete && x.BillStatus != BillStatus.Bill)).Distinct().Count();
            ViewBag.TotalApprovedBill    = billscoreboard.Where(x => (x.BillStatus != BillStatus.Complete && x.BillStatus != BillStatus.Bill && x.BillStatus != BillStatus.Submit)).Distinct().Count();
            ViewBag.TotalUnApprovedBill  = billscoreboard.Where(x => (x.BillStatus == BillStatus.ClaimHandlerCorrectionRequired || x.BillStatus == BillStatus.ClaimHandlerHold)).Distinct().Count();
            ViewBag.TotalUnSubmittedBill = Filteredbillscoreboard.Distinct().Count();


            ViewBag.ListSubmittedBill   = billscoreboard.Where(x => (x.BillStatus != BillStatus.Complete && x.BillStatus != BillStatus.Bill)).Distinct();
            ViewBag.ListApprovedBill    = billscoreboard.Where(x => (x.BillStatus != BillStatus.Complete && x.BillStatus != BillStatus.Bill && x.BillStatus != BillStatus.Submit)).Distinct();
            ViewBag.ListUnApprovedBill  = billscoreboard.Where(x => (x.BillStatus == BillStatus.ClaimHandlerCorrectionRequired || x.BillStatus == BillStatus.ClaimHandlerHold)).Distinct();
            ViewBag.ListUnSubmittedBill = Filteredbillscoreboard.Distinct();

            CheckAccess();

            return(View());
        }
Пример #2
0
 public ActionResult Index()
 {
     result = _DashboardDao.GetBillScoreBoard(SessionManager.UserId);
     CheckAccess();
     return(View(result));
 }