Fix custom keyboard after edit quest.

This commit is contained in:
Ceda EI 2018-11-07 21:00:10 +05:30
parent e0c28b7410
commit aab7f7cc29
1 changed files with 3 additions and 1 deletions

4
bot.py
View File

@ -315,7 +315,9 @@ def edit_quest(bot, update, player, qid, target, type):
player.set_state('esq', qid) player.set_state('esq', qid)
custom_keyboard = [ custom_keyboard = [
["Mark as done"], ["Mark as done"],
["Edit Name", "Change Priority", "Change Difficulty"], ["Edit Name", "Change Priority"],
["Change Difficulty", "Delete " +
{"quest": "Quest", "side_quest": "Side Quest"}[type]],
["Back"]] ["Back"]]
reply_markup = telegram.ReplyKeyboardMarkup(custom_keyboard) reply_markup = telegram.ReplyKeyboardMarkup(custom_keyboard)
bot.send_message(chat_id=chat_id, text=text, reply_markup=reply_markup, bot.send_message(chat_id=chat_id, text=text, reply_markup=reply_markup,