mirror of https://github.com/interlegis/sigi.git
Sesóstris Vieira
2 months ago
2 changed files with 59 additions and 0 deletions
@ -0,0 +1,21 @@ |
|||
|
|||
Utilize os seguintes <a class="modal-trigger" href="#help_modal_{{ field_name }}"><i>placeholders</i></a> |
|||
<div id="help_modal_{{ field_name }}" class="modal"> |
|||
<div class="modal-content"> |
|||
<h5>Placeholders</h5> |
|||
<ul class="collection"> |
|||
{% for placeholder in placeholders %} |
|||
<li class="collection-item"><b>{{ placeholder.0 }}</b>: {{ placeholder.1 }}</li> |
|||
{% endfor %} |
|||
</ul> |
|||
</div> |
|||
<div class="modal-footer"> |
|||
<a href="#!" class="modal-close waves-effect waves-green btn-small btn-flat">Fechar</a> |
|||
</div> |
|||
</div> |
|||
<script> |
|||
console.log("Rodou"); |
|||
$(document).ready(function(){ |
|||
M.Modal.init($('.modal'), {}); |
|||
}); |
|||
</script> |
@ -0,0 +1,38 @@ |
|||
{% load i18n %} |
|||
<div id="alertModal" class="modal fade" tabindex="-1" data-bs-backdrop="static" data-bs-keyboard="false"> |
|||
<div class="modal-dialog"> |
|||
<div class="modal-content"> |
|||
<div class="modal-header"> |
|||
<h5 class="modal-title">{% translate "Avisos" %}</h5> |
|||
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button> |
|||
</div> |
|||
<div class="modal-body"> |
|||
<div class="tab-content" id="alertTabContent"> |
|||
{% for alerta in alertas %} |
|||
<div class="tab-pane fade container{% if forloop.first %} show active{% endif %}" id="{{ alerta.titulo|lower|slugify }}-pane" role="tabpanel" aria-labelledby="{{ alerta.titulo|lower|slugify }}-tab" tabindex="0"> |
|||
<h5>{{ alerta.titulo }}</h5> |
|||
{{ alerta.mensagem|safe }} |
|||
</div> |
|||
{% endfor %} |
|||
</div> |
|||
</div> |
|||
<div class="modal-footer"> |
|||
<ul class="nav nav-pills" id="alertTab" role="tablist"> |
|||
{% for alerta in alertas %} |
|||
<li class="nav-item" role="presentation"> |
|||
<button class="nav-link{% if forloop.first %} active{% endif %}" id="{{ alerta.titulo|lower|slugify }}-tab" data-bs-toggle="tab" data-bs-target="#{{ alerta.titulo|lower|slugify }}-pane" type="button" role="tab" aria-controls="{{ alerta.titulo|lower|slugify }}-pane"{% if forloop.first %} aria-selected="true"{% endif %}> # {{ forloop.counter }}</button> |
|||
</li> |
|||
{% endfor %} |
|||
</ul> |
|||
|
|||
<button type="button" class="btn btn-secondary" data-bs-dismiss="modal">{% translate "Close" %}</button> |
|||
</div> |
|||
</div> |
|||
</div> |
|||
</div> |
|||
<script> |
|||
$(document).ready(function () { |
|||
const myModal = new bootstrap.Modal('#alertModal'); |
|||
myModal.show(); |
|||
}) |
|||
</script> |
Loading…
Reference in new issue