1
0
mirror of https://gitlab.com/simple-stock-bots/simple-stock-bot.git synced 2025-06-16 07:16:40 +00:00

Fixes #60 Changed Date Formatting for intra reply

This commit is contained in:
Anson Biggs 2021-04-24 11:36:02 -07:00
parent f5195700a6
commit e7fa0ced5c

4
bot.py
View File

@ -314,8 +314,8 @@ def intra(update: Update, context: CallbackContext):
update.message.reply_photo( update.message.reply_photo(
photo=buf, photo=buf,
caption=f"\nIntraday chart for {symbol.name} from {df.first_valid_index().strftime('%I:%M')} to" caption=f"\nIntraday chart for {symbol.name} from {df.first_valid_index().strftime('%H:%M')} to"
+ f" {df.last_valid_index().strftime('%I:%M')} ET on" + f" {df.last_valid_index().strftime('%H:%M %Z')} on"
+ f" {datetime.date.today().strftime('%d, %b %Y')}\n\n{s.price_reply([symbol])[0]}", + f" {datetime.date.today().strftime('%d, %b %Y')}\n\n{s.price_reply([symbol])[0]}",
parse_mode=telegram.ParseMode.MARKDOWN, parse_mode=telegram.ParseMode.MARKDOWN,
disable_notification=True, disable_notification=True,