From e5609ed074dd75bcf087d9fbb825539dc62e4e29 Mon Sep 17 00:00:00 2001 From: Lady Di <93448337+dialuna@users.noreply.github.com> Date: Sun, 30 Apr 2023 10:05:32 +0300 Subject: [PATCH] bot_database.py --- Задания/task1/Gasanova/bot_database.py | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/Задания/task1/Gasanova/bot_database.py b/Задания/task1/Gasanova/bot_database.py index 11dd716..1c3d867 100644 --- a/Задания/task1/Gasanova/bot_database.py +++ b/Задания/task1/Gasanova/bot_database.py @@ -40,22 +40,22 @@ def start(message): def handle_text(message): if (message.text.strip() == "Лучший скейтборд этого сезона"): i = random.choice(array) - ans = f'Название: {i[2]}\nЦена: {i[3]}\n' - bot.send_message(message.chat.id, ans) + inf = f'Название: {i[2]}\nЦена: {i[3]}\n' + bot.send_message(message.chat.id, inf) bot.send_photo(message.chat.id, open(i[4], 'rb')) cat = open('kotik.webm', 'rb') bot.send_video(message.chat.id, cat) elif (message.text.strip() == "Предложение дня"): i = random.choice(array) - ans = f'Название: {i[2]}\nЦена: {i[3]}\n' - bot.send_message(message.chat.id, ans) + inf = f'Название: {i[2]}\nЦена: {i[3]}\n' + bot.send_message(message.chat.id, inf) bot.send_photo(message.chat.id, open(i[4], 'rb')) cat = open('kotik.webm', 'rb') bot.send_video(message.chat.id, cat) elif (message.text.strip() == "Выбор редакции нашей компании"): i = random.choice(array) - ans = f'Название: {i[2]}\nЦена: {i[3]}\n' - bot.send_message(message.chat.id, ans) + inf = f'Название: {i[2]}\nЦена: {i[3]}\n' + bot.send_message(message.chat.id, inf) bot.send_photo(message.chat.id, open(i[4], 'rb')) cat = open('kotik.webm', 'rb') bot.send_video(message.chat.id, cat)