Beispiel #1
0
        public IActionResult Create(Status status)
        {
            if (ModelState.IsValid)
            {
                var result = statuses.AddStatus(status);

                if (result)
                {
                    TempData["message"] = $"Status has been created.";
                }

                return(RedirectToAction("List"));
            }
            else
            {
                return(View(status));
            }
        }