public void Patch(string id, [FromBody] MergePatchItemIssuanceMvoDto value)
 {
     try {
         ItemIssuanceMvosControllerUtils.SetNullIdOrThrowOnInconsistentIds(id, value);
         _itemIssuanceMvoApplicationService.When(value as IMergePatchItemIssuanceMvo);
     } catch (Exception ex) { var response = ItemIssuanceMvosControllerUtils.GetErrorHttpResponseMessage(ex); throw new HttpResponseException(response); }
 }
 public void Delete(string id, string commandId, string version, string requesterId = default(string))
 {
     try {
         var value = new DeleteItemIssuanceMvoDto();
         value.CommandId       = commandId;
         value.RequesterId     = requesterId;
         value.ShipmentVersion = (long)Convert.ChangeType(version, typeof(long));
         ItemIssuanceMvosControllerUtils.SetNullIdOrThrowOnInconsistentIds(id, value);
         _itemIssuanceMvoApplicationService.When(value as IDeleteItemIssuanceMvo);
     } catch (Exception ex) { var response = ItemIssuanceMvosControllerUtils.GetErrorHttpResponseMessage(ex); throw new HttpResponseException(response); }
 }
        public void Put(string id, [FromBody] CreateOrMergePatchOrDeleteItemIssuanceMvoDto value)
        {
            try {
                // ///////////////////////////////
                if (value.ShipmentVersion != default(long))
                {
                    value.CommandType = CommandType.MergePatch;
                    ItemIssuanceMvosControllerUtils.SetNullIdOrThrowOnInconsistentIds(id, value);
                    _itemIssuanceMvoApplicationService.When(value as IMergePatchItemIssuanceMvo);
                    return;
                }
                // ///////////////////////////////

                ItemIssuanceMvosControllerUtils.SetNullIdOrThrowOnInconsistentIds(id, value);
                _itemIssuanceMvoApplicationService.When(value as ICreateItemIssuanceMvo);
            } catch (Exception ex) { var response = ItemIssuanceMvosControllerUtils.GetErrorHttpResponseMessage(ex); throw new HttpResponseException(response); }
        }