def check_callback_data(callback):
db = sqlite3.connect("mistify.db")
c = db.cursor()
if callback.data == "btn1":
c.execute(f"UPDATE checker SET vape = 'lol' WHERE user_id = {callback.message.from_user.id}")
if callback.data == "btn2":
pass
if callback.data == "btn3":
pass
if callback.data == "btn4":
pass
if callback.data == "btn5":
pass
if callback.data == "btn6":
pass
if callback.data == "btn7":
pass
if callback.data == "btn8":
pass
if callback.data == "btn9":
markup = types.ReplyKeyboardMarkup(resize_keyboard=True)
one = types.KeyboardButton(text="1 ")
two = types.KeyboardButton(text="2 ")
three = types.KeyboardButton(text="3 ")
markup.add(one, two, three)
bot.edit_message_text(chat_id=callback.message.chat.id, message_id=callback.message.id, text="Выберите опцию ")
bot.send_message(chat_id=callback.message.chat.id, text="1. Смотреть объявления .\n2. Продать товар .\n3. Изменить город .", reply_markup=markup)
db.commit()
db.close()
@bot.callback_query_handler(func=lambda callback: callback.data)
def check_callback_data(callback):
db = sqlite3.connect("mistify.db")
c = db.cursor()
if callback.data == "btn1":
c.execute("UPDATE checker SET vape = 'lol' WHERE user_id = ?", (str(callback.message.from_user.id),))
if callback.data == "btn2":