public async Task <HttpResponseMessage> Delete(string id) { IManaoUser user = await _manaoUserBusinessLogic.Get(ObjectId.Parse(id)); _manaoUserBusinessLogic.Delete(user); return(CreateResponse(HttpStatusCode.NoContent)); }
public async Task <HttpResponseMessage> Post(ManaoUser user) { IManaoUser createdUser = await _manaoUserBusinessLogic.Save(user); createdUser = await _manaoUserBusinessLogic.Get(createdUser._id); return(CreateResponse(HttpStatusCode.Created, createdUser)); }
public async Task <HttpResponseMessage> Put(ManaoUser user) { IManaoUser updatedUser = await _manaoUserBusinessLogic.Update(user); return(CreateResponse(HttpStatusCode.OK, updatedUser)); }
public async Task <HttpResponseMessage> Get(string id) { IManaoUser user = await _manaoUserBusinessLogic.Get(ObjectId.Parse(id)); return(CreateResponse(HttpStatusCode.OK, user)); }