None
@view_config(renderer="templates/form.pt", name="file")
@demonstrate("File Upload Widget")
def file(self):
class Schema(colander.Schema):
upload = colander.SchemaNode(
deform.FileData(),
widget=deform.widget.FileUploadWidget(tmpstore),
)
schema = Schema()
form = deform.Form(schema, buttons=("submit",))
return self.render_form(form, success=tmpstore.clear)