public async Task <IActionResult> CreateShipment(NewShipment json)
        {
            try
            {
                var req = GrpcNewShipmentRequestFactory.GetFrom(json);
                await ShippingClient.CreateShipment(req);

                return(EmpityAnswer);
            }
            catch (Exception e)
            {
                throw;
            }
        }
示例#2
0
 public GrpcNewShipmentRequestFactory(NewShipment req) => Req = req;
示例#3
0
 public static GrpcNewShipmentRequest GetFrom(NewShipment shipment) =>
 new GrpcNewShipmentRequestFactory(shipment).Get();