8.2.10.5.1.3. SecureForm¶
- class SecureForm(*args, **kwargs)[source]¶
Methods
__contains__Returns True if the named field is a member of this form.
__delattr__Implement delattr(self, name).
__delitem__Remove a field from this form.
__dir__Default dir() implementation.
__eq__Return self==value.
__format__Default object formatter.
__ge__Return self>=value.
__getattribute__Return getattr(self, name).
__getitem__Dict-style access to this form's fields.
__getstate__Helper for pickle.
__gt__Return self>value.
__hash__Return hash(self).
__init_subclass__This method is called when a class is subclassed.
__iter__Iterate form fields in creation order.
__le__Return self<=value.
__lt__Return self<value.
__ne__Return self!=value.
__new____reduce__Helper for pickle.
__reduce_ex__Helper for pickle.
__repr__Return repr(self).
__setattr__Implement setattr(self, name, value).
__setitem__Bind a field to this form.
__sizeof__Size of object in memory, in bytes.
__str__Return str(self).
__subclasshook__Abstract classes can override this to customize issubclass().
_get_translationspopulate_objPopulates the attributes of the passed obj with data from the form's fields.
processProcess default and input data with each field.
validateValidate the form by calling
validateon each field.- __init__(formdata=None, obj=None, prefix='', **kwargs)¶
- Parameters:
formdata – Input data coming from the client, usually
request.formor equivalent. Should provide a “multi dict” interface to get a list of values for a given key, such as what Werkzeug, Django, and WebOb provide.obj – Take existing data from attributes on this object matching form field attributes. Only used if
formdatais not passed.prefix – If provided, all fields will have their name prefixed with the value. This is for distinguishing multiple forms on a single page. This only affects the HTML name for matching input data, not the Python name for matching existing data.
data – Take existing data from keys in this dict matching form field attributes.
objtakes precedence if it also has a matching attribute. Only used ifformdatais not passed.meta – A dict of attributes to override on this form’s
metainstance.extra_filters – A dict mapping field attribute names to lists of extra filter functions to run. Extra filters run after filters passed when creating the field. If the form has
filter_<fieldname>, it is the last extra filter.kwargs – Merged with
datato allow passing existing data as parameters. Overwrites any duplicate keys indata. Only used ifformdatais not passed.
Attributes
__dict____weakref__list of weak references to the object
_translationsdataerrors- class Meta[source]¶
- property csrf¶
- property csrf_field_name¶
- __dict__ = mappingproxy({'__module__': 'schedula.utils.form.server.admin', 'csrf': <property object>, 'csrf_field_name': <property object>, 'build_csrf': <function SecureForm.Meta.build_csrf>, '__dict__': <attribute '__dict__' of 'Meta' objects>, '__weakref__': <attribute '__weakref__' of 'Meta' objects>, '__doc__': None, '__annotations__': {}})¶
- __doc__ = None¶
- __module__ = 'schedula.utils.form.server.admin'¶
- __weakref__¶
list of weak references to the object
- __annotations__ = {}¶
- __doc__ = None¶
- __module__ = 'schedula.utils.form.server.admin'¶
- _unbound_fields = None¶
- _wtforms_meta = None¶