Fix inline keyboard (IS THIS THE ONE?)

This commit is contained in:
Hamcha 2018-09-17 14:47:09 +02:00
parent c66e5c19d3
commit 86dabaacf4
Signed by: hamcha
GPG Key ID: A40413D21021EAEE
1 changed files with 13 additions and 11 deletions

24
main.go
View File

@ -68,17 +68,19 @@ func webhook(update tg.APIUpdate) {
PhotoURL: card.ImageUris.Large,
ThumbURL: card.ImageUris.Normal,
Title: card.Name,
ReplyMarkup: []tg.APIInlineKeyboardButton{
{
Text: "Scryfall",
URL: card.ScryfallURI,
}, {
Text: fmt.Sprintf("EDHREC (#%d)", card.EdhrecRank),
URL: card.RelatedUris.Edhrec,
}, {
Text: fmt.Sprintf("Cardmarket (%s €)", card.ScryfallURI),
URL: card.PurchaseUris.Magiccardmarket,
},
ReplyMarkup: &tg.APIInlineKeyboardMarkup{
InlineKeyboard: [][]tg.APIInlineKeyboardButton{{
{
Text: "Scryfall",
URL: card.ScryfallURI,
}, {
Text: fmt.Sprintf("EDHREC (#%d)", card.EdhrecRank),
URL: card.RelatedUris.Edhrec,
}, {
Text: fmt.Sprintf("Cardmarket (%s €)", card.ScryfallURI),
URL: card.PurchaseUris.Magiccardmarket,
},
}},
},
}
}