Commit 0ac14567 authored by Serge S. Koval's avatar Serge S. Koval

Bootstrap 3 adjustments.

parent c8a4cc93
...@@ -129,7 +129,7 @@ table.flters tr td:nth-child(2){ ...@@ -129,7 +129,7 @@ table.flters tr td:nth-child(2){
} }
.submit-row { .submit-row {
margin-top: 35px; margin-top: 5px;
} }
td>span.glyphicon { td>span.glyphicon {
......
...@@ -39,11 +39,12 @@ ...@@ -39,11 +39,12 @@
{% if messages %} {% if messages %}
{% for category, m in messages %} {% for category, m in messages %}
{% if category %} {% if category %}
<div class="alert alert-{{ category }} alert-dismissable"> {% set mapping = {'message': 'info', 'error': 'danger'} %}
<div class="alert alert-{{ mapping.get(category, 'warning') }} alert-dismissable">
{% else %} {% else %}
<div class="alert alert-dismissable"> <div class="alert alert-dismissable">
{% endif %} {% endif %}
<button type="button" class="close" data-dismiss="alert" aria-hidden="true">&times;</button> <button type="button" class="close" data-dismiss="alert" aria-hidden="true">&times;</button>
{{ m }} {{ m }}
</div> </div>
{% endfor %} {% endfor %}
......
...@@ -132,8 +132,8 @@ ...@@ -132,8 +132,8 @@
{% endif %} {% endif %}
{% endmacro %} {% endmacro %}
{% macro form_tag(form=None) %} {% macro form_tag(form=None, action=None) %}
<form action="" method="POST" role="form" class="form-horizontal" enctype="multipart/form-data"> <form action="{{ action or '' }}" method="POST" role="form" class="form-horizontal" enctype="multipart/form-data">
{{ caller() }} {{ caller() }}
</form> </form>
{% endmacro %} {% endmacro %}
...@@ -152,8 +152,8 @@ ...@@ -152,8 +152,8 @@
</div> </div>
{% endmacro %} {% endmacro %}
{% macro render_form(form, cancel_url, extra=None, form_opts=None) -%} {% macro render_form(form, cancel_url, extra=None, form_opts=None, action=None) -%}
{% call form_tag() %} {% call form_tag(action=action) %}
{{ render_form_fields(form, form_opts=form_opts) }} {{ render_form_fields(form, form_opts=form_opts) }}
{{ render_form_buttons(cancel_url, extra) }} {{ render_form_buttons(cancel_url, extra) }}
{% endcall %} {% endcall %}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment