forms.MultiValueField.compress()

compress(data_list) [source] Takes a list of valid values and returns a “compressed” version of those values – in a single value. For example, SplitDateTimeField is a subclass which combines a time field and a date field into a datetime object. This method must be implemented in the subclasses.

forms.MultiValueField

class MultiValueField(fields=(), **kwargs) [source] Default widget: TextInput Empty value: '' (an empty string) Normalizes to: the type returned by the compress method of the subclass. Validates the given value against each of the fields specified as an argument to the MultiValueField. Error message keys: required, invalid, incomplete Aggregates the logic of multiple fields that together produce a single value. This field is abstract and must be subclassed. In contrast with the single-va

forms.MultipleHiddenInput.choices

choices This attribute is optional when the form field does not have a choices attribute. If it does, it will override anything you set here when the attribute is updated on the Field.

forms.MultipleHiddenInput

class MultipleHiddenInput [source] Multiple <input type='hidden' ...> widgets. A widget that handles multiple hidden widgets for fields that have a list of values. choices This attribute is optional when the form field does not have a choices attribute. If it does, it will override anything you set here when the attribute is updated on the Field.

forms.MultipleChoiceField

class MultipleChoiceField(**kwargs) [source] Default widget: SelectMultiple Empty value: [] (an empty list) Normalizes to: A list of Unicode objects. Validates that every value in the given list of values exists in the list of choices. Error message keys: required, invalid_choice, invalid_list The invalid_choice error message may contain %(value)s, which will be replaced with the selected choice. Takes one extra required argument, choices, as for ChoiceField.

forms.models.modelform_factory()

modelform_factory(model, form=ModelForm, fields=None, exclude=None, formfield_callback=None, widgets=None, localized_fields=None, labels=None, help_texts=None, error_messages=None, field_classes=None) [source] Returns a ModelForm class for the given model. You can optionally pass a form argument to use as a starting point for constructing the ModelForm. fields is an optional list of field names. If provided, only the named fields will be included in the returned fields. exclude is an optiona

forms.models.modelformset_factory()

modelformset_factory(model, form=ModelForm, formfield_callback=None, formset=BaseModelFormSet, extra=1, can_delete=False, can_order=False, max_num=None, fields=None, exclude=None, widgets=None, validate_max=False, localized_fields=None, labels=None, help_texts=None, error_messages=None, min_num=None, validate_min=False, field_classes=None) [source] Returns a FormSet class for the given model class. Arguments model, form, fields, exclude, formfield_callback, widgets, localized_fields, labels,

forms.models.inlineformset_factory()

inlineformset_factory(parent_model, model, form=ModelForm, formset=BaseInlineFormSet, fk_name=None, fields=None, exclude=None, extra=3, can_order=False, can_delete=True, max_num=None, formfield_callback=None, widgets=None, validate_max=False, localized_fields=None, labels=None, help_texts=None, error_messages=None, min_num=None, validate_min=False, field_classes=None) [source] Returns an InlineFormSet using modelformset_factory() with defaults of formset=BaseInlineFormSet, can_delete=True, a

forms.models.BaseModelFormSet.new_objects

models.BaseModelFormSet.new_objects

forms.models.BaseModelFormSet.deleted_objects

models.BaseModelFormSet.deleted_objects