Beispiel #1
0
        public async Task WhenAsync(MergePatchShipmentMethodTypeDto c)
        {
            var idObj         = (c as IMergePatchShipmentMethodType).ShipmentMethodTypeId;
            var uriParameters = new ShipmentMethodTypeUriParameters();

            uriParameters.Id = idObj;

            var req  = new ShipmentMethodTypePatchRequest(uriParameters, (MergePatchShipmentMethodTypeDto)c);
            var resp = await _ramlClient.ShipmentMethodType.Patch(req);

            ShipmentMethodTypeProxyUtils.ThrowOnHttpResponseError(resp);
        }
Beispiel #2
0
        public async Task <IShipmentMethodTypeState> GetAsync(string shipmentMethodTypeId)
        {
            IShipmentMethodTypeState state = null;
            var idObj         = shipmentMethodTypeId;
            var uriParameters = new ShipmentMethodTypeUriParameters();

            uriParameters.Id = idObj;

            var req = new ShipmentMethodTypeGetRequest(uriParameters);

            var resp = await _ramlClient.ShipmentMethodType.Get(req);

            ShipmentMethodTypeProxyUtils.ThrowOnHttpResponseError(resp);
            state = (resp.Content == null) ? null : resp.Content.ToShipmentMethodTypeState();
            return(state);
        }
Beispiel #3
0
        public async Task WhenAsync(DeleteShipmentMethodTypeDto c)
        {
            var idObj         = (c as IDeleteShipmentMethodType).ShipmentMethodTypeId;
            var uriParameters = new ShipmentMethodTypeUriParameters();

            uriParameters.Id = idObj;

            var q = new ShipmentMethodTypeDeleteQuery();

            q.CommandId   = c.CommandId;
            q.RequesterId = c.RequesterId;
            q.Version     = Convert.ToString(c.Version);

            var req = new ShipmentMethodTypeDeleteRequest(uriParameters);

            req.Query = q;

            var resp = await _ramlClient.ShipmentMethodType.Delete(req);

            ShipmentMethodTypeProxyUtils.ThrowOnHttpResponseError(resp);
        }