Beispiel #1
0
        // GET: CardDetails
        public async Task <ActionResult> Index()
        {
            if (!await AuthorizePage("MyCard"))
            {
                return(RedirectToAction("NoAccess", "Home"));
            }

            OmniDataItemManager mgr;
            OmniDataItemMock    injector = new OmniDataItemMock();

            mgr = new OmniDataItemManager(injector);
            mgr.LoadCardDetails();
            return(View(mgr));
        }
        // GET: Rewards
        public async Task <ActionResult> Index()
        {
            if (!await AuthorizePage("MyRewards"))
            {
                return(RedirectToAction("NoAccess", "Home"));
            }

            OmniDataItemManager mgr;
            OmniDataItemMock    injector = new OmniDataItemMock();

            mgr = new OmniDataItemManager(injector);
            mgr.LoadCardDetails();

            ViewBag.TotalCardRewards = mgr.CardDetailsList.Sum(r => r.totalCardPoints);

            return(View(mgr));
        }