From 0ec861332d0c0b6bc245fde561d5cad229582da1 Mon Sep 17 00:00:00 2001 From: Benjamin Dauvergne Date: Thu, 19 Jul 2018 14:28:10 +0200 Subject: [PATCH 1/9] templates: output form.media in base template (#24439) It's the new habit downstream. --- .../templates/authentic2/accounts_edit.html | 10 ---------- src/authentic2/templates/authentic2/base.html | 2 ++ .../registration/registration_completion_form.html | 11 ----------- 3 files changed, 2 insertions(+), 21 deletions(-) diff --git a/src/authentic2/templates/authentic2/accounts_edit.html b/src/authentic2/templates/authentic2/accounts_edit.html index d2ec6be9..c7587b14 100644 --- a/src/authentic2/templates/authentic2/accounts_edit.html +++ b/src/authentic2/templates/authentic2/accounts_edit.html @@ -1,16 +1,6 @@ {% extends "authentic2/base-page.html" %} {% load i18n %} -{% block css %} -{{ block.super }} -{{ form.media.css }} -{% endblock %} - -{% block extra_scripts %} -{{ block.super }} -{{ form.media.js }} -{% endblock %} - {% block page-title %} {{ block.super }} - {{ view.title }} {% endblock %} diff --git a/src/authentic2/templates/authentic2/base.html b/src/authentic2/templates/authentic2/base.html index d7ce8105..c35b7887 100644 --- a/src/authentic2/templates/authentic2/base.html +++ b/src/authentic2/templates/authentic2/base.html @@ -9,10 +9,12 @@ {{ block.super }} {% renderblock "css" %} + {{ form.media.css }} {% endblock %} {% block extrascripts %} {{ block.super }} + {{ form.media.js }} {% comment %}block extra_scripts is kept for compatibility with old themes{% endcomment %} {% block extra_scripts %} {% endblock %} diff --git a/src/authentic2/templates/registration/registration_completion_form.html b/src/authentic2/templates/registration/registration_completion_form.html index cd179aaa..7935bfe3 100644 --- a/src/authentic2/templates/registration/registration_completion_form.html +++ b/src/authentic2/templates/registration/registration_completion_form.html @@ -2,17 +2,6 @@ {% load i18n %} {% load breadcrumbs %} -{% block css %} -{{ block.super }} -{{ form.media.css }} -{% endblock %} - -{% block extra_scripts %} -{{ block.super }} -{{ form.media.js }} -{% endblock %} - - {% block title %} {% trans "Registration" %} {% endblock %} -- 2.18.0