Control of widgets in templates sans BS.
Project description
Control of widgets in templates sans BS.
Installation
We are at the cheeseshop:
pip install django_reform
Usage
To use django_reform in a project:
Include it in INSTALLED_APPS in your settings file.
Render your forms like so:
{% load reform %} {{ reform form }}
Open reform/templates/reform/field.html - by default rendering HTML5 input types. Go ahead and tweak:
{% load widget_tweaks reform %} {% with field_type=field|get_form_field_type %} {% if field_type == 'DateField' %} {% render_field field type="date" %} {% elif field_type == 'EmailField' %} {% render_field field type="email" %} {% elif field_type == 'URLField' %} {% render_field field type="url" %} {% else %} {{ field }} {% endif %} {% endwith %}
Sans BS as promised :)
History
0.1.0 (2013-11-25)
First release on PyPI.
0.1.1 (2013-11-25)
Basic documentation.
0.2.0 (2013-12-8)
Added replacement for bootstrap_toolkit’s as_bootstrap template filter. The reform template tag passed the original template context to the form templates enabling checks for instance for permissions etc.
0.2.1 (2013-12-8)
Added bootstrp CDN.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
django_reform-0.2.1.tar.gz
(6.1 kB
view hashes)