change NEXT_MONTH to actaul next month instead of CURRENT_TIME
This commit is contained in:
parent
768f1c66e6
commit
a70fd1369e
@ -8,7 +8,7 @@ import datetime as dt
|
||||
from dateutil import relativedelta
|
||||
|
||||
CURRENT_TIME = dt.date.today()
|
||||
NEXT_MONTH = CURRENT_TIME
|
||||
NEXT_MONTH = CURRENT_TIME + relativedelta.relativedelta(months=1, day=1)
|
||||
DAYS_OF_WEEK_SR = ("PON", "UTO", "SRE", "ČET", "PET", "SUB", "NED")
|
||||
MONTHS_SR = ("Januar", "Februar", "Mart", "April", "Maj", "Jun", "Jul", "Avgust",\
|
||||
"Septembar", "Oktobar", "Novembar", "Decembar")
|
||||
@ -45,7 +45,7 @@ def drawPoster(events, bg, fg):
|
||||
_, _, w, _ = draw.textbbox((0, 0), header, font=fontFacade)
|
||||
draw.text(((W-w)/2, 120), header, font=fontFacade, fill=fg)
|
||||
|
||||
subheader = f"Plan za {MONTHS_SR[NEXT_MONTH.month - 1]}"
|
||||
subheader = f"Plan za {MONTHS_SR[NEXT_MONTH.month]}"
|
||||
_, _, w, _ = draw.textbbox((0, 0), subheader, font=fontIosevka)
|
||||
draw.text(((W-w)/2, 240), subheader, font=fontIosevka, fill=fg)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user