Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Added markup to vertical forms (standard Bootstrap) works fine, gives…

… more control
  • Loading branch information...
commit 27c1a38d95c9339f76459df7501c5b8518a12370 1 parent 179f6b9
@dyve authored
View
50 bootstrap_toolkit/templates/bootstrap_toolkit/field_vertical.html
@@ -1,24 +1,34 @@
-{% if input_type == "checkbox" %}
- {% include "bootstrap_toolkit/field_checkbox.html" %}
- {% include "bootstrap_toolkit/field_help.html" with inline=True %}
- {% include "bootstrap_toolkit/field_errors.html" with inline=False %}
-{% else %}
- {% if input_type == "multicheckbox" %}
- <label class="nonfield{% if field.required %} required{% endif %}">{{ field.label }}</label>
- {% include "bootstrap_toolkit/field_choices.html" with type="checkbox" %}
- {% include "bootstrap_toolkit/field_help.html" with inline=False %}
- {% include "bootstrap_toolkit/field_errors.html" with inline=False %}
- {% else %}
- {% if input_type == "radioset" %}
- <label class="nonfield{% if field.required %} required{% endif %}">{{ field.label }}</label>
- {% include "bootstrap_toolkit/field_choices.html" with type="radio" %}
- {% include "bootstrap_toolkit/field_help.html" with inline=False %}
- {% include "bootstrap_toolkit/field_errors.html" with inline=False %}
- {% else %}
- <label class="nonfield{% if field.field.required %} required{% endif %}"{% if field.auto_id %} for="{{ field.auto_id }}"{% endif %}>{{ field.label }}</label>
- {% include "bootstrap_toolkit/field_default.html" %}
+<div class="control-group{% if field.errors %} error{% endif %}{% if field.field.required %} required{% endif %}">
+ {% if input_type == "checkbox" %}
+ <div class="controls">
+ {% include "bootstrap_toolkit/field_checkbox.html" %}
{% include "bootstrap_toolkit/field_help.html" with inline=True %}
{% include "bootstrap_toolkit/field_errors.html" with inline=False %}
+ </div>
+ {% else %}
+ {% if input_type == "multicheckbox" %}
+ <label class="control-label{% if field.required %} required{% endif %}">{{ field.label }}</label>
+ <div class="controls">
+ {% include "bootstrap_toolkit/field_choices.html" with type="checkbox" %}
+ {% include "bootstrap_toolkit/field_help.html" with inline=False %}
+ {% include "bootstrap_toolkit/field_errors.html" with inline=False %}
+ </div>
+ {% else %}
+ {% if input_type == "radioset" %}
+ <label class="control-label{% if field.required %} required{% endif %}">{{ field.label }}</label>
+ <div class="controls">
+ {% include "bootstrap_toolkit/field_choices.html" with type="radio" %}
+ {% include "bootstrap_toolkit/field_help.html" with inline=False %}
+ {% include "bootstrap_toolkit/field_errors.html" with inline=False %}
+ </div>
+ {% else %}
+ <label class="contral-label{% if field.field.required %} required{% endif %}"{% if field.auto_id %} for="{{ field.auto_id }}"{% endif %}>{{ field.label }}</label>
+ <div class="controls">
+ {% include "bootstrap_toolkit/field_default.html" %}
+ {% include "bootstrap_toolkit/field_help.html" with inline=True %}
+ {% include "bootstrap_toolkit/field_errors.html" with inline=False %}
+ </div>
+ {% endif %}
{% endif %}
{% endif %}
-{% endif %}
+</div>
View
2  setup.py
@@ -2,7 +2,7 @@
setup(
name='django-bootstrap-toolkit',
- version='2.3.7',
+ version='2.4.0',
url='https://github.com/dyve/django-bootstrap-toolkit',
author='Dylan Verheul',
author_email='dylan@dyve.net',
Please sign in to comment.
Something went wrong with that request. Please try again.