Esempio n. 1
0
        public ActionResult TestManagement()
        {
            var allTests = _getInfoService.GetAllTests().Select(t => _advancedMapper.MapTest(t)).ToList();

            if (allTests != null)
            {
                return(View(allTests));
            }

            return(HttpNotFound());
        }
Esempio n. 2
0
        // public JsonResult GetAllTests()
        public IEnumerable <TestViewModel> GetAllTests()
        {
            var allTests = _getInfoService.GetAllTests().Select(t => _advancedMapper.MapTest(t)).ToList();

            return(allTests);
            //return Json(allTests, JsonRequestBehavior.AllowGet);
        }
Esempio n. 3
0
        public ActionResult UpdateTest(string testGuid)
        {
            Session["testGuid"] = testGuid;
            TestViewModel test = _advancedMapper.MapTest(_getInfoService.GetTestByGuid(testGuid));

            if (test != null)

            {
                return(View(test));
            }

            return(HttpNotFound());
        }
Esempio n. 4
0
        public JsonResult GetAllTests()
        {
            var allTests = _getInfoService.GetAllTests().Select(t => _advancedMapper.MapTest(t)).ToList();

            return(Json(allTests, JsonRequestBehavior.AllowGet));
        }