コード例 #1
0
 public ActionResult Index()
 {
     using (var context = new DatabaseContext())
     {
         //Get all the calculations again from the db (our new Calculation should be there)
         DateTime       ddr = (DateTime)HttpContext.Session["dataDeRef"];
         ViewModelIndex vmi = new ViewModelIndex(1, ddr.AddDays(-6), ddr, context);
         return(View(vmi));
     }
 }
コード例 #2
0
        public ActionResult Index()
        {
            var model = new ViewModelIndex(manager.GetAll());

            return(View(model));
        }