public HttpResponseMessage UpdateAsset(HttpRequestMessage request, [FromBody] Asset obj) { var result = service.UpdateAsset(obj); HttpResponseMessage response = new HttpResponseMessage(); response = request.CreateResponse(HttpStatusCode.OK, new { success = result }); return(response); }
public HttpResponseMessage UpdateAsset(HttpRequestMessage request, [FromBody] AssetViewModel obj) { obj.UpdatedDate = _dateExtension.GetDateTime(); var result = service.UpdateAsset(obj); HttpResponseMessage response = new HttpResponseMessage(); response = request.CreateResponse(HttpStatusCode.OK, new { success = result }); return(response); }