Browse Source

HOT-FIX: refetora composicao_list

pull/2579/head
Leandro Roberto 6 years ago
parent
commit
f2900a5c27
  1. 67
      sapl/templates/comissoes/composicao_list.html
  2. 9
      sapl/templates/crud/list.html
  3. 2
      setup.py

67
sapl/templates/comissoes/composicao_list.html

@ -1,46 +1,45 @@
{% extends "crud/list.html" %} {% extends "crud/list.html" %}
{% load i18n common_tags crispy_forms_tags%} {% load i18n common_tags crispy_forms_tags%}
{% block base_content %} {% block actions %}
{% if user.is_authenticated and perms.comissoes.add_composicao %} {% if user.is_authenticated and perms.comissoes.add_composicao %}
<div class="context-actions clearfix"> <div class="actions btn-group float-right btn-group-lg" role="group">
{% block actions %} {% if view.create_url %}
<div class="actions btn-group float-right btn-group-lg" role="group"> <a href="{{ view.create_url }}" class="btn btn-outline-primary">
{% if view.create_url %} {% blocktrans with verbose_name=view.verbose_name %} Adicionar {{ verbose_name }} {% endblocktrans %}
<a href="{{ view.create_url }}" class="btn btn-outline-primary"> </a>
{% blocktrans with verbose_name=view.verbose_name %} Adicionar {{ verbose_name }} {% endblocktrans %} {% endif %}
</a> {% block more_buttons %}{% endblock more_buttons %}
{% endif %} </div>
{% block more_buttons %}{% endblock more_buttons %}
</div>
{% endblock actions %}
</div>
{% endif %} {% endif %}
{% endblock actions %}
<fieldset class="form-group"> {% block extra_content %}
<legend>Selecione o Período</legend> <form method="GET">
<form method="GET"> <fieldset class="form-group">
<select name="pk" class="form-control" onChange="form.submit();"> <legend>Selecione o Período</legend>
{% for c in composicao_list %} <select name="pk" class="form-control" onChange="form.submit();">
<option value="{{c.id}}" {% if composicao_pk == c.id %} selected {% endif %}> {% for c in composicao_list %}
{{c}} <option value="{{c.id}}" {% if composicao_pk == c.id %} selected {% endif %}>
</option> {{c}}
{% endfor %} </option>
</select> {% endfor %}
</form> </select>
</fieldset> </fieldset>
</form>
<br/> <br/>
{% endblock %}
{% block container_table_list %}
{% if user.is_authenticated and perms.comissoes.add_participacao %} {% if user.is_authenticated and perms.comissoes.add_participacao %}
<div class="actions btn-group mb-2" role="group"> <div class="context-actions clearfix">
<a href="{% url 'sapl.comissoes:participacao_create' composicao_pk %}" class="btn btn-outline-primary"> <div class="actions btn-group mb-2" role="group">
Adicionar Participação em Comissão <a href="{% url 'sapl.comissoes:participacao_create' composicao_pk %}" class="btn btn-outline-primary">
</a> Adicionar Participação em Comissão
</a>
</div>
</div> </div>
{% endif %} {% endif %}
<div class="clearfix"></div>
<div class="container-table"> <div class="container-table">
<table class="table table-striped table-hover table-link-ordering"> <table class="table table-striped table-hover table-link-ordering">
<thead> <thead>
@ -71,4 +70,4 @@
</tbody> </tbody>
</table> </table>
</div> </div>
{% endblock base_content %} {% endblock %}

9
sapl/templates/crud/list.html

@ -5,17 +5,18 @@
<div class="context-actions clearfix"> <div class="context-actions clearfix">
<div class="actions search float-left"> <div class="actions search">
{% if form %} {% if form %}
{% crispy form %} {% crispy form %}
{% endif %} {% endif %}
</div> </div>
{% block actions %} {% block actions %}
<div class="actions btn-group float-right btn-group-lg" role="group"> <div class="actions btn-group float-right btn-group-lg" role="group">
{% if view.create_url %} {% if view.create_url %}
<a href="{{ view.create_url }}" class="btn btn-outline-primary"> <a href="{{ view.create_url }}" class="btn btn-outline-primary">
{% blocktrans with verbose_name=view.verbose_name %} Adicionar {{ verbose_name }} {% endblocktrans %} {% blocktrans with verbose_name=view.verbose_name %} Adicionar {{ verbose_name }} {% endblocktrans %}
</a> </a>
{% endif %} {% endif %}
{% block more_buttons %}{% endblock more_buttons %} {% block more_buttons %}{% endblock more_buttons %}
</div> </div>

2
setup.py

@ -20,7 +20,7 @@ install_requires = [
'django-extra-views==0.12.0', 'django-extra-views==0.12.0',
'django-model-utils==3.1.2', 'django-model-utils==3.1.2',
'django-reversion==3.0.2', 'django-reversion==3.0.2',
'django-reversion-compare==0.8.6' 'django-reversion-compare==0.8.6',
'django-speedinfo==1.4.0', 'django-speedinfo==1.4.0',
'django-extensions==2.1.4', 'django-extensions==2.1.4',
'django-image-cropping==1.2.0', 'django-image-cropping==1.2.0',

Loading…
Cancel
Save