form.process adds little bits to the form to be able to actually process
the posted data.
in pseudo-code you need to
list_of_forms = []
for something in list_of_values:
key = something_unique
form = SQLFORM(....)
if form.process(formname=something_unique).accepted:
.....code dealing with the posted values, such as form.vars, etc
elif form.errors:
.....code dealing with form errors
list_of_forms.append(form)
......
return dict(list_of_forms=list_of_forms, ....)
In the view, you can then:
{{for single_form in list_of_forms:}}
<div class="row">
{{=single_form}} #or {{single_form.custom.etc etc etc}}
</div>
<hr />
{{pass}}
--
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
---
You received this message because you are subscribed to the Google Groups
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.