From ba87420c8b271521dd63712a9ee6d0a14aa04b5d Mon Sep 17 00:00:00 2001 From: Sylvain Delabye Date: Thu, 5 Sep 2024 16:39:17 +0200 Subject: [PATCH] Factorize import code for dropzone --- templates/conventions/cadastre.html | 7 ++----- templates/conventions/commentaires.html | 7 ++----- templates/conventions/common/dropzone_css.html | 4 ++++ templates/conventions/common/dropzone_js.html | 5 +++++ templates/conventions/denonciation.html | 7 ++----- templates/conventions/edd.html | 7 ++----- templates/conventions/finalisation/cerfa.html | 7 ++----- templates/conventions/journal.html | 8 ++------ templates/conventions/resiliation_base.html | 7 ++----- 9 files changed, 23 insertions(+), 36 deletions(-) create mode 100644 templates/conventions/common/dropzone_css.html create mode 100644 templates/conventions/common/dropzone_js.html diff --git a/templates/conventions/cadastre.html b/templates/conventions/cadastre.html index b75f1233b..9ff9d5072 100644 --- a/templates/conventions/cadastre.html +++ b/templates/conventions/cadastre.html @@ -7,15 +7,12 @@ {% load custom_filters %} {% block javascript_extras %} - - - + {% include "conventions/common/dropzone_js.html" %} {% endblock %} {% block css_extras %} - - + {% include "conventions/common/dropzone_css.html" %} {% endblock %} diff --git a/templates/conventions/commentaires.html b/templates/conventions/commentaires.html index c47a0421f..c13f9116c 100644 --- a/templates/conventions/commentaires.html +++ b/templates/conventions/commentaires.html @@ -5,15 +5,12 @@ {% load static %} {% block javascript_extras %} - - - + {% include "conventions/common/dropzone_js.html" %} {% endblock %} {% block css_extras %} - - + {% include "conventions/common/dropzone_css.html" %} {% endblock %} {% block content %} diff --git a/templates/conventions/common/dropzone_css.html b/templates/conventions/common/dropzone_css.html new file mode 100644 index 000000000..03176994d --- /dev/null +++ b/templates/conventions/common/dropzone_css.html @@ -0,0 +1,4 @@ +{% load static %} + + + \ No newline at end of file diff --git a/templates/conventions/common/dropzone_js.html b/templates/conventions/common/dropzone_js.html new file mode 100644 index 000000000..2c336d942 --- /dev/null +++ b/templates/conventions/common/dropzone_js.html @@ -0,0 +1,5 @@ +{% load static %} + + + + \ No newline at end of file diff --git a/templates/conventions/denonciation.html b/templates/conventions/denonciation.html index ca0713272..c0003d51c 100644 --- a/templates/conventions/denonciation.html +++ b/templates/conventions/denonciation.html @@ -5,15 +5,12 @@ {% load static %} {% block javascript_extras %} - - - + {% include "conventions/common/dropzone_js.html" %} {% endblock %} {% block css_extras %} - - + {% include "conventions/common/dropzone_css.html" %} {% endblock %} {% block content %} diff --git a/templates/conventions/edd.html b/templates/conventions/edd.html index 2bfd2328e..3a560edbc 100644 --- a/templates/conventions/edd.html +++ b/templates/conventions/edd.html @@ -7,15 +7,12 @@ {% load custom_filters %} {% block javascript_extras %} - - - + {% include "conventions/common/dropzone_js.html" %} {% endblock %} {% block css_extras %} - - + {% include "conventions/common/dropzone_css.html" %} {% endblock %} {% block content %} diff --git a/templates/conventions/finalisation/cerfa.html b/templates/conventions/finalisation/cerfa.html index b99e43af2..b4102aa68 100644 --- a/templates/conventions/finalisation/cerfa.html +++ b/templates/conventions/finalisation/cerfa.html @@ -5,15 +5,12 @@ {% load static %} {% block javascript_extras %} - - - + {% include "conventions/common/dropzone_js.html" %} {% endblock %} {% block css_extras %} - - + {% include "conventions/common/dropzone_css.html" %} {% endblock %} {% block content %} diff --git a/templates/conventions/journal.html b/templates/conventions/journal.html index 78cd5a651..e54fe68e3 100644 --- a/templates/conventions/journal.html +++ b/templates/conventions/journal.html @@ -5,15 +5,11 @@ {% load static %} {% block javascript_extras %} - - - - + {% include "conventions/common/dropzone_js.html" %} {% endblock %} {% block css_extras %} - - + {% include "conventions/common/dropzone_css.html" %} {% endblock %} {% block content %} diff --git a/templates/conventions/resiliation_base.html b/templates/conventions/resiliation_base.html index 190711bcf..85fbe3732 100644 --- a/templates/conventions/resiliation_base.html +++ b/templates/conventions/resiliation_base.html @@ -5,13 +5,10 @@ {% load static %} {% block javascript_extras %} - - - + {% include "conventions/common/dropzone_js.html" %} {% endblock %} {% block css_extras %} - - + {% include "conventions/common/dropzone_css.html" %} {% endblock %}