mirror of
https://github.com/c9s/bbgo.git
synced 2024-11-22 14:55:16 +00:00
types: improve trade text template
This commit is contained in:
parent
7952cf8804
commit
88210fd27b
|
@ -144,7 +144,7 @@ func (trade Trade) PlainText() string {
|
|||
trade.FeeCurrency)
|
||||
}
|
||||
|
||||
var slackTradeTextTemplate = ":handshake: {{ .Symbol }} {{ .Side }} Trade Execution @ {{ .Price }}"
|
||||
var slackTradeTextTemplate = ":handshake: Trade {{ .Symbol }} {{ .Side }} {{ .Quantity }} @ {{ .Price }}"
|
||||
|
||||
func (trade Trade) SlackAttachment() slack.Attachment {
|
||||
var color = "#DC143C"
|
||||
|
@ -176,7 +176,6 @@ func (trade Trade) SlackAttachment() slack.Attachment {
|
|||
// Pretext: pretext,
|
||||
Color: color,
|
||||
Fields: []slack.AttachmentField{
|
||||
{Title: "Exchange", Value: trade.Exchange.String(), Short: true},
|
||||
{Title: "Price", Value: trimTrailingZeroFloat(trade.Price), Short: true},
|
||||
{Title: "Quantity", Value: trimTrailingZeroFloat(trade.Quantity), Short: true},
|
||||
{Title: "QuoteQuantity", Value: trimTrailingZeroFloat(trade.QuoteQuantity), Short: true},
|
||||
|
|
Loading…
Reference in New Issue
Block a user