Skip to main content
Help us improve Python packaging – donate today!

A simple Django app for inlines formsets

Project Description


Inline forms with bootstrap3


Form-inline-bootstrap a simple Django app to create form with forsets.
Use with crispy-forms.

Quick start

1. Add 'django_form_inline__bootstrap3' to your INSTALLED_APPS setting like this:



class Company(models.Model):
name = models.CharField(max_length=250)

class Employe(models.Model):
name = models.CharField(max_length=250)
company = models.ForeignKey(Company, related_name='employes')


class FormMixin(object):
def __init__(self, *args, **kwargs):
super(FormMixin, self).__init__(*args, **kwargs)
self.helper = FormHelper()
self.helper.form_tag = False

class CompanyForm(FormMixin, forms.ModelForm):
class Meta:
model = Company

class EmployeForm(FormMixin, forms.ModelForm):
class Meta:
model = Employe

EmplyeFormSet = inlineformset_factory(Company, Employe, form=EmployeForm, extra=1)

class CompanyFormMixin(object):
model = Company
formsets_class = [EmployeFormSet]
form_class = CompanyForm

class CompanyCreate(CompanyFormMixin, FormsetMixin, CreateView):

class CompanyUpdate(CompanyFormMixin, FormsetMixin, UpdateView):
is_update_view = True


/* here need jquery <script src=""></script> /*
{% load form_inlines %}
{% load crispy_forms_tags %}
<form action="" method="post" enctype="multipart/form-data">
{{ form.errors|as_crispy_errors }}
{% main_form form formsets %}

{% render_formsets formsets %}

<div class="form-actions col-md-24">
<button type="submit" class="btn btn-primary">Save</button>

{% empty_formsets formsets %}

3. profit

Release history Release notifications

This version
History Node


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Filename, size & hash SHA256 hash help File type Python version Upload date
django-formsets-bootstrap3-0.2.2.tar.gz (4.3 kB) Copy SHA256 hash SHA256 Source None Jan 27, 2015

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging CloudAMQP CloudAMQP RabbitMQ AWS AWS Cloud computing Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page