Browse Source

fix: corrigindo export.html em labels e checkboxes e colocando o bt5 no botao enviar

pull/183/head
moonshinerd 1 month ago
parent
commit
6cfdd0af20
  1. 3
      sigi/static/css/export.css
  2. 45
      sigi/templates/admin/import_export/export.html

3
sigi/static/css/export.css

@ -0,0 +1,3 @@
input[type="checkbox"] {
vertical-align: middle; /* Alinha verticalmente ao texto */
}

45
sigi/templates/admin/import_export/export.html

@ -35,43 +35,17 @@
{% if not form.is_selectable_fields_form %} {% if not form.is_selectable_fields_form %}
{% include "admin/import_export/resource_fields_list.html" with import_or_export="export" %} {% include "admin/import_export/resource_fields_list.html" with import_or_export="export" %}
{% endif %} {% endif %}
<p></p>
<fieldset class="module"> <fieldset class="module">
{% for field in form.visible_fields %}
<div
{% if field.field.is_selectable_field %}
{# all fields are visible by default, JS will hide unselected resource fields on load #}
class="selectable-field-export-row"
{# resource index will be used for showing-hiding fields #}
resource-index="{{ field.field.resource_index }}"
{% else %}
class="form-row aligned"
{% endif %}
>
{% if field.field.initial_field %}
<p style="padding: 0;">{% translate "This exporter will export the following fields:" %}</p> <p style="padding: 0;">{% translate "This exporter will export the following fields:" %}</p>
{% endif %} {% for field in form.visible_fields %}
{{ field.errors }} <div class="d-flex align-items-center mb-3">
<label for="{{ field.id_for_label }}" class="form-label me-2 mb-0">
{% if not field.field.is_selectable_field %} {{ field.label }}:
{{ field.label_tag }} </label>
{% endif %} <div style="margin-left: 15px;"> <!-- Ajusta o checkbox para frente -->
{% if field.field.widget.attrs.readonly %}
{{ field.field.value }}
{{ field.as_hidden }}
{% else %}
{{ field }} {{ field }}
{% endif %} </div>
{% if field.field.is_selectable_field %}
{{ field.label_tag }}
{% endif %}
{% if field.field.help_text %}
<p class="help">{{ field.field.help_text|safe }}</p>
{% endif %}
</div> </div>
{% endfor %} {% endfor %}
{% for field in form.hidden_fields %} {% for field in form.hidden_fields %}
@ -79,12 +53,13 @@
{% endfor %} {% endfor %}
</fieldset> </fieldset>
<div> <div>
{{ form.non_field_errors }} {{ form.non_field_errors }}
</div> </div>
<div class="submit-row"> <div class="submit-row">
<input type="submit" class="default" value="{% translate "Submit" %}"> <input type="submit" class="btn btn-outline-primary" value="{% translate "Submit" %}">
</div> </div>
</form> </form>
{% endblock %} {% endblock %}

Loading…
Cancel
Save