public IHttpActionResult DeleteTask(string id)
        {
            TaskBusiness tb        = new TaskBusiness();
            var          isDeleted = tb.DeleteTask(id);

            return(Ok(isDeleted));
        }
Exemple #2
0
        public IHttpActionResult DeleteTask(int id)
        {
            Task task = taskBusiness.GetTask(id);

            if (task == null)
            {
                return(NotFound());
            }
            taskBusiness.DeleteTask(task);
            return(Ok(task));
        }