Example #1
0
        public RedirectToActionResult AddElement([FromForm] ElementDto elementDto)
        {
            try
            {
                _elementService.Add(elementDto);
            }
            catch (Exception ex)
            {
                return(RedirectToAction(actionName: "New"));
            }

            return(RedirectToAction("List", "Element"));
        }