Ejemplo n.º 1
0
        // GET: IRMA/Checklist
        public ActionResult Checklist(int?id)
        {
            serviceModel = FSOServiceSystem.GetServiceModel(FSODataModelType.Checklist);
            FSOChecklistViewModel model = new FSOChecklistViewModel();

            if (id.HasValue)
            {
                model.Checklist = serviceModel.GetItem(string.Format("Id={0}", id.Value), "Id");
                if (model.Checklist == null) // Invalid checklist passed in
                {
                    return(RedirectToAction("Index"));
                }
            }
            else // New Checklist
            {
                model.Checklist = FSOServiceSystem.CreateChecklist();
                model.Sections  = FSOServiceSystem.GetChecklistSections();
                model.Questions = FSOServiceSystem.GetBaselineQuestions().ToList();
                Session["checklistObserverGridModel"] = new ChecklistObserverGridModel()
                {
                };
            }

            Session["ChecklistViewModel"] = model;

            return(View(model));
        }
Ejemplo n.º 2
0
        public ActionResult ChecklistOberserversPartial()
        {
            //ViewData["Users"] = FSOServiceDataModel.GetOnboardUsers();

            IFSOServiceDataModel dataModel = FSOServiceSystem.GetServiceModel(FSOServiceSystem.FSODataModelType.Observer);
            List <dynamic>       items     = dataModel.GetAllItems();

            return(PartialView());
        }