Python
0
Вклад в тег
# def keyboards_start():
# keyboards_start = types.ReplyKeyboardMarkup(resize_keyboard=True)
# Button1 = types.KeyboardButton("Картиночка")
# keyboards_start.add(Button1)
# return keyboards_start
# def choise_picture_keyboard():
# keyboards_choise_picture = types.ReplyKeyboardMarkup(resize_keyboard=True)
# Button1 = types.KeyboardButton("М")
# Button2 = types.KeyboardButton("П")
# Button3 = types.KeyboardButton("Назад")
# keyboards_choise_picture.add(Button1,Button2,Button3)
# return(keyboards_choise_picture)
@bot.message_handler(text=["Назад"])
@bot.message_handler(commands=['start'])
def start(message):
bot.send_message(message.chat.id, "Что желаете?", reply_markup=keyboards.keyboards_start())
@bot.message_handler(text=["Картиночка"])
def choise_picture(message):
bot.send_message(message.chat.id, "Какую желаете?",
reply_markup=keyboards.choise_picture_keyboard())
bot.infinity_polling()