Пример #1
0
        public Task AddTask(HttpRequestMessage requestMessage, NewTask newTask)
        {
            var task   = _addTaskMaintenanceProcessor.AddTask(newTask);
            var result = new TaskCreatedActionResult(task, requestMessage);

            return(task);
        }
Пример #2
0
        public IHttpActionResult AddTask(HttpRequestMessage request, NewTask newTask)
        {
            var task   = addTaskMaintenanceProcessor.AddTask(newTask);
            var result = new TaskCreatedActionResult(request, task);

            return(result);
        }
        [HttpPost] public Task AddTask(HttpRequestMessage requestMessage, NewTask newTask)
        {
            var task = _addTaskMaintenanceProcessor.AddTask(newTask);

            return(task);
            //{
            //    Subject = "In v1, newTask.Subject = " + newTask.Subject
            //};
        }
Пример #4
0
        public IHttpActionResult AddTask(HttpRequestMessage requestMessage, NewTask newTask)
        {
            var task   = _addTaskMaintenanceProcessor.AddTask(newTask);
            var result = new TaskCreatedActionResult(requestMessage, task);

            return(result);

            //return new Task
            //{
            //    Subject = "In v2, newTask.Subject = " + newTask.Subject
            //};
        }
Пример #5
0
        public Task AddTask(HttpRequestMessage requestMessage, NewTask newTask)
        {
            var task = _addTaskMaintenanceProcessor.AddTask(newTask);

            return(task);
        }