You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 

27 lines
614 B

package handlers
import (
"context"
"gopkg.in/tucnak/telebot.v3"
"muskrat/storage"
)
func Add(ctx telebot.Context) error {
//return ctx.Send(bot.Layout.Text(ctx, "rules"), bot.Layout.Markup(ctx, "rules"))
err := storage.SetState(context.Background(), ctx.Sender().ID, "phone")
if err != nil {
return err
}
return ctx.Send("Введите <b>номер телефона</b>:")
}
func Accept(ctx telebot.Context) error {
err := storage.SetState(context.Background(), ctx.Sender().ID, "phone")
if err != nil {
return err
}
return ctx.Edit("Введите <b>номер телефона</b>:")
}