shippingservice: money proto migration
Signed-off-by: Ahmet Alp Balkan <ahmetb@google.com>
This commit is contained in:
parent
8a07a97872
commit
c2b08f0793
3 changed files with 169 additions and 202 deletions
|
@ -34,10 +34,10 @@ func (s *server) GetQuote(ctx context.Context, in *pb.GetQuoteRequest) (*pb.GetQ
|
|||
|
||||
// 3. Generate a response.
|
||||
return &pb.GetQuoteResponse{
|
||||
CostUsd: &pb.MoneyAmount{
|
||||
Decimal: quote.Dollars,
|
||||
Fractional: quote.Cents,
|
||||
},
|
||||
CostUsd: &pb.Money{
|
||||
CurrencyCode: "USD",
|
||||
Units: int64(quote.Dollars),
|
||||
Nanos: int32(quote.Cents * 10000000)},
|
||||
}, nil
|
||||
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue