Ejemplo n.º 1
0
 // GET: Questions/Create
 public IActionResult Create(int id)
 {
     ViewData["OptionGroupId"]  = new SelectList(optionGroupService.GetAll());
     ViewData["QuestionTypeId"] = new SelectList(questionTypeService.GetAll());
     ViewData["SectionId"]      = id;
     return(View());
 }
        // GET: OptionGroups
        public IActionResult Index()
        {
            var optionGroups = optionGroupService.GetAll();
            var model        = new ListOptionGroupsViewModel {
                OptionGroups = new SelectList(optionGroups, "Id", "Name")
            };

            return(View(model));
        }