вывод времени
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
Pavel_Duron 2022-11-03 16:35:10 +10:00
parent cffd4aae1b
commit 9775118ab3

8
bot.py
View File

@ -17,10 +17,10 @@ dp = Dispatcher(bot)
@dp.message_handler(commands=["time"])
async def send_time(message: types.Message):
current_datatime = datetime.datetime.now()
current_data = current_datatime.date()
current_time = current_datatime.time()
new_year = datetime.date(2022, 12, 31)
await message.reply('Сегодня' + current_data + '\nВремя' + current_time + '\nДо нового года осталось' + new_year) #отображение времени, пока не рабоатет
# current_data = current_datatime.date()
# current_time = current_datatime.time()
# new_year = datetime.date(2022, 12, 31)
await message.reply('Сегодня' + current_datatime) #отображение времени, пока не рабоатет