add json struct tags

This commit is contained in:
c9s 2021-01-20 16:15:34 +08:00
parent 617f5119fd
commit 09d712416f

View File

@ -6,9 +6,9 @@ import (
) )
type Position struct { type Position struct {
Base fixedpoint.Value Base fixedpoint.Value `json:"base"`
Quote fixedpoint.Value Quote fixedpoint.Value `json:"quote"`
AverageCost fixedpoint.Value AverageCost fixedpoint.Value `json:"averageCost"`
} }
func (p *Position) AddTrade(t types.Trade) (fixedpoint.Value, bool) { func (p *Position) AddTrade(t types.Trade) (fixedpoint.Value, bool) {