Пример #1
0
 public IActionResult Create(CountryForm model)
 {
     if (ModelState.IsValid)
     {
         var result = _service.CreateFromDto <CountryForm>(model);
         if (result.Succeeded)
         {
             return(RedirectToAction("Index"));
         }
         ModelState.AddResultErrors(result);
     }
     return(View(model));
 }