public void Patch(string id, [FromBody] MergePatchPhysicalInventoryLineMvoDto value) { try { PhysicalInventoryLineMvosControllerUtils.SetNullIdOrThrowOnInconsistentIds(id, value); _physicalInventoryLineMvoApplicationService.When(value as IMergePatchPhysicalInventoryLineMvo); } catch (Exception ex) { var response = PhysicalInventoryLineMvosControllerUtils.GetErrorHttpResponseMessage(ex); throw new HttpResponseException(response); } }
public async Task WhenAsync(MergePatchPhysicalInventoryLineMvoDto c) { var idObj = PhysicalInventoryLineMvoProxyUtils.ToIdString((c as IMergePatchPhysicalInventoryLineMvo).PhysicalInventoryLineId); var uriParameters = new PhysicalInventoryLineMvoUriParameters(); uriParameters.Id = idObj; var req = new PhysicalInventoryLineMvoPatchRequest(uriParameters, (MergePatchPhysicalInventoryLineMvoDto)c); var resp = await _ramlClient.PhysicalInventoryLineMvo.Patch(req); PhysicalInventoryLineMvoProxyUtils.ThrowOnHttpResponseError(resp); }
public void When(MergePatchPhysicalInventoryLineMvoDto c) { WhenAsync(c).GetAwaiter().GetResult(); }