public void Patch(string id, [FromBody] MergePatchInOutLineMvoDto value) { try { InOutLineMvosControllerUtils.SetNullIdOrThrowOnInconsistentIds(id, value); _inOutLineMvoApplicationService.When(value as IMergePatchInOutLineMvo); } catch (Exception ex) { var response = InOutLineMvosControllerUtils.GetErrorHttpResponseMessage(ex); throw new HttpResponseException(response); } }
public async Task WhenAsync(MergePatchInOutLineMvoDto c) { var idObj = InOutLineMvoProxyUtils.ToIdString((c as IMergePatchInOutLineMvo).InOutLineId); var uriParameters = new InOutLineMvoUriParameters(); uriParameters.Id = idObj; var req = new InOutLineMvoPatchRequest(uriParameters, (MergePatchInOutLineMvoDto)c); var resp = await _ramlClient.InOutLineMvo.Patch(req); InOutLineMvoProxyUtils.ThrowOnHttpResponseError(resp); }
public void When(MergePatchInOutLineMvoDto c) { WhenAsync(c).GetAwaiter().GetResult(); }