From dec9ba49fefffe6ba47efd2f8d9923b73a853a22 Mon Sep 17 00:00:00 2001 From: moonshinerd Date: Mon, 9 Dec 2024 15:13:53 -0300 Subject: [PATCH] =?UTF-8?q?adicionando=20todo=20o=20trabalho=20realizado?= =?UTF-8?q?=20para=20resolver=20conflitos=20que=20apareceram=20ap=C3=B3s?= =?UTF-8?q?=20merge=20add:=20adicionando=20base.html=20e=20export.html=20f?= =?UTF-8?q?ix:=20corrige=20duplica=C3=A7=C3=A3o=20da=20navega=C3=A7=C3=A3o?= =?UTF-8?q?=20"=C3=8Dnicio"=20no=20breadcrumbs,=20sobrescrevendo=20correta?= =?UTF-8?q?mente=20o=20bloco=20nav-breadcrumbs=20do=20Admin=20para=20evita?= =?UTF-8?q?r=20repeti=C3=A7=C3=A3o.=20Esse=20bloco=20estava=20contido=20no?= =?UTF-8?q?=20import=5Fexport/base.html=20=20fix:=20corrigindo=20export.ht?= =?UTF-8?q?ml=20em=20labels=20e=20checkboxes=20e=20colocando=20o=20bt5=20n?= =?UTF-8?q?o=20botao=20enviar=20remove:=20apagando=20arquivos=20desnecess?= =?UTF-8?q?=C3=A1rios=20feat:=20melhorando=20a=20estetica=20do=20export?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- sigi/templates/admin/import_export/base.html | 23 ++++++ .../templates/admin/import_export/export.html | 80 +++++++++++++++++++ 2 files changed, 103 insertions(+) create mode 100644 sigi/templates/admin/import_export/base.html create mode 100644 sigi/templates/admin/import_export/export.html diff --git a/sigi/templates/admin/import_export/base.html b/sigi/templates/admin/import_export/base.html new file mode 100644 index 0000000..1a7f6cf --- /dev/null +++ b/sigi/templates/admin/import_export/base.html @@ -0,0 +1,23 @@ +{% extends "admin/base_site.html" %} +{% load i18n admin_modify %} +{% load admin_urls %} +{% load static %} + +{% block extrastyle %}{{ block.super }}{% endblock %} + +{% if not is_popup %} + {% block nav-breadcrumbs %} + + {% endblock %} +{% endif %} + +{% block bodyclass %}{{ block.super }} {{ opts.app_label }}-{{ opts.object_name.lower }} change-form{% endblock %} diff --git a/sigi/templates/admin/import_export/export.html b/sigi/templates/admin/import_export/export.html new file mode 100644 index 0000000..dc6870d --- /dev/null +++ b/sigi/templates/admin/import_export/export.html @@ -0,0 +1,80 @@ +{% extends "admin/import_export/base.html" %} +{% load i18n %} +{% load admin_urls %} +{% load import_export_tags %} + +{% block extrahead %} +{{ block.super }} + +{{ form.media }} +{% endblock %} + +{% block breadcrumbs_last %} +{% translate "Export" %} +{% endblock %} + +{% block content %} +{% if form.errors %} + {{ form.errors }} +{% endif %} +
+ {% csrf_token %} + {# Export request has originated from an Admin UI action #} + {% if form.initial.export_items %} +

+ {% blocktranslate count len=form.initial.export_items|length %} + Export {{ len }} selected item. + {% plural %} + Export {{ len }} selected items. + {% endblocktranslate %} +

+ {% endif %} + + {# Fields list is not required with selectable fields form #} + {% if not form.is_selectable_fields_form %} + {% include "admin/import_export/resource_fields_list.html" with import_or_export="export" %} + {% endif %} +

+ +
+

{% translate "This exporter will export the following fields:" %}

+ +
+ {% for field in form.visible_fields %} + {% if field.name != "format" %} {# Excluindo o campo "Formato" da lista automática #} +
+
+
+ + {{ field }} + {% if field.field.help_text %} + + {{ field.field.help_text|safe }} + + {% endif %} +
+
+
+ {% endif %} + {% endfor %} +
+ + {% for field in form.hidden_fields %} + {{ field }} + {% endfor %} +
+ + {# Campo "Formato" separado, posicionado de forma independente #} +
+ + {{ form.format }} +
+ +
+ +
+ +
+{% endblock %}