Exemple #1
0
        public async Task <IActionResult> AddEnteredSchool(EnteredListViewModel model)
        {
            try
            {
                await _schoolService.AddEnteredSchoolToList(model.EnteredSchool.Id,
                                                            model.EnteredSchool.Name,
                                                            model.EnteredSchool.SchoolDistrictId,
                                                            model.EnteredSchool.SchoolTypeId);

                ShowAlertSuccess($"Added Entered School '{model.EnteredSchool.Name}' to School list");
            }
            catch (GraException gex)
            {
                ShowAlertDanger("Unable to add Entered School: ", gex);
            }
            return(RedirectToAction("Entered"));
        }