org.forms.generic

Classes

DateRangeForm

A form providing a start/end date range.

ExportForm

A form providing a choice of export formats.

PaymentForm

ChangeUrlForm

ChangeAdjacencyListUrlForm

Module Contents

class org.forms.generic.DateRangeForm[source]

Bases: onegov.form.Form

A form providing a start/end date range.

start[source]
end[source]
validate() → bool[source]
class org.forms.generic.ExportForm[source]

Bases: onegov.form.Form

A form providing a choice of export formats.

file_format[source]
property format: str[source]
as_export_response(results: collections.abc.Sequence[dict[str, Any]], title: str = 'export', **kwargs: Any) → morepath.request.Response[source]

Turns the given results (list of dicts) into a webob response with the currently selected file format.

The additional keyword arguments are directly passed into the convert_list_of_dicts_to_* functions.

For json and xml, these additional arguments are ignored.

class org.forms.generic.PaymentForm[source]

Bases: onegov.form.Form

request: onegov.org.request.OrgRequest[source]
minimum_price_total[source]
payment_method[source]
validate_minimum_price_total(field: wtforms.fields.DecimalField) → None[source]
validate_payment_method(field: wtforms.fields.RadioField) → None[source]
class org.forms.generic.ChangeUrlForm[source]

Bases: onegov.form.Form

name[source]
test[source]
get_model() → Any[source]
is_duplicate_entry(model: Any, name: str) → bool[source]
validate_name(field: wtforms.fields.StringField) → None[source]
class org.forms.generic.ChangeAdjacencyListUrlForm[source]

Bases: ChangeUrlForm

is_duplicate_entry(model: onegov.core.orm.abstract.AdjacencyList, name: str) → bool[source]