public JsonResult Delete(int taskId)
        {
            if (taskId < 0)
            {
                return(Json("Index"));
            }
            var result     = _taskBusiness.Delete(taskId);
            var ajaxResult = JsonSerializer.Serialize(result);

            return(Json(ajaxResult));
        }
 public IActionResult Delete(int id)
 {
     _taskBusiness.Delete(id);
     return(NoContent());
 }
        public async Task <IActionResult> DeleteTask(int id)
        {
            await _taskManagerBusiness.Delete(id);

            return(NoContent());
        }