示例#1
0
        public IHttpActionResult Post(PostTodoRequest request)
        {
            var user = GetCurrentUser();

            var todo = user.CreateTodo(request.Content);

            _userRepository.Save(user);

            return(Created("", new PostTodoResponse {
                Id = todo.Id
            }));
        }
示例#2
0
        public IHttpActionResult Post(PostTodoRequest request)
        {
            var user = GetCurrentUser();

            var todo = user.CreateTodo(request.Content);

            _userRepository.Save(user);

            return Created("", new PostTodoResponse{Id = todo.Id});
        }