You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to web...@googlegroups.com
hi everybody,
been starting with web2py weeks ago and now my first unsolved issue appears.
There is an action to handle a custom form (as skeleton code here):
form = FORM()
for row in some_data_source: if row in relevant_data_source: form.append( INPUT(...var...) )
if form.accepts(...): for v in form.vars[...var...]: ... change relevant_data_source ...
So far the skeleton code. Now the issue: i have to call twice this action because first relevant_data_source will be updated in accepts block and after then creation of form will be effected. But i can't twist the code because i need values of input vars.
thx for helping
Niphlod
unread,
Feb 13, 2015, 2:47:16 PM2/13/15
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to web...@googlegroups.com
that doesn't really make sense....
""" i have to call twice this action because first relevant_data_source will be updated in accepts block """
What you're stating is - actually - that you need two separate logics (and forms): in order to create - and validate - the second, you need the user to fill in some details in the first one.... why don't you just use two forms with a redirect between the first and the second, or some kind of flag (i.e. step=1 in the first, step=2 in the second) ?