@view_config(renderer="templates/form.pt", name="sequence_of_dateinputs")
@demonstrate("Sequence of Date Inputs")
def sequence_of_dateinputs(self):
import datetime
class Sequence(colander.SequenceSchema):
date = colander.SchemaNode(
colander.Date(),
validator=colander.Range(
min=datetime.date(2010, 5, 5),
min_err=_("${val} is earlier than earliest date ${min}"),
),
)
class Schema(colander.Schema):
dates = Sequence()
schema = Schema()
form = deform.Form(schema, buttons=("submit",))
return self.render_form(form)