From f1aa2d63684917b259e058c21bc61d37543416e3 Mon Sep 17 00:00:00 2001 From: "Pavel \"LEdoian\" Turinsky" Date: Wed, 31 Mar 2021 21:40:33 +0200 Subject: [PATCH] =?UTF-8?q?Fix=20bugu,=20kdy=20se=20na=20apr=C3=ADla=20obj?= =?UTF-8?q?ev=C3=AD=20na=20chv=C3=ADli=20str=C3=A1nka=20norm=C3=A1ln=C4=9B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- mamweb/templates/base.html | 6 ++---- various/context_processors.py | 1 + 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/mamweb/templates/base.html b/mamweb/templates/base.html index 3b6b4f25..8f2b7a7d 100644 --- a/mamweb/templates/base.html +++ b/mamweb/templates/base.html @@ -169,10 +169,8 @@ return Math.floor(360*Math.random()); } - $(document).ready(function(){ - $('.container').css('margin', 0); - rotace_a_posun($('.container'), randomUhel()); - }); + $('.container').css('margin', 0); + rotace_a_posun($('.container'), randomUhel()); {% endif %} {% render_block "js" %} diff --git a/various/context_processors.py b/various/context_processors.py index c0be2975..28a34858 100644 --- a/various/context_processors.py +++ b/various/context_processors.py @@ -1,4 +1,5 @@ def april(req): + return {'april': 2021} if 'X-April' in req.headers: try: year = int(req.headers['X-April'])