init code
This commit is contained in:
18
internal/services/tele/commands/market.go
Normal file
18
internal/services/tele/commands/market.go
Normal file
@@ -0,0 +1,18 @@
|
||||
package commands
|
||||
|
||||
import (
|
||||
"gopkg.in/telebot.v3"
|
||||
"me.thuanle/bbot/internal/services/controllers"
|
||||
"me.thuanle/bbot/internal/services/tele/chat"
|
||||
"me.thuanle/bbot/internal/services/tele/view"
|
||||
)
|
||||
|
||||
func OnGetTopPrices(context telebot.Context) error {
|
||||
sym, price, rate := controllers.GetTopPrices()
|
||||
return chat.ReplyMessagePre(context, view.RenderOnGetTopPricesMessage(sym, price, rate))
|
||||
}
|
||||
|
||||
func OnGetTopFundingFee(context telebot.Context) error {
|
||||
fee, float64s, cds := controllers.GetTopFundingFee()
|
||||
return chat.ReplyMessagePre(context, view.RenderOnGetTopFundingFeeMessage(fee, float64s, cds))
|
||||
}
|
||||
Reference in New Issue
Block a user