Ejemplo n.º 1
0
        public IActionResult AddTask(TaskViewModel model)
        {
            try
            {
                _hubService.AssignTask(model);
                _toastNotification.AddSuccessToastMessage("Tasks have been successfully assigned.");
            }
            catch (Exception e)
            {
                _toastNotification.AddErrorToastMessage(e.Message);
            }

            return(RedirectToAction("Index", "Hub", new { title = model.HubName }));
        }