def funcdone(form,xyz):
comment_id = form.vars.id
...
def post_comment():
xyz = 123
form = crud.create(db.comment, onaccept=lambda
form,xyz=xyz:funcdone(form,xyz))
return dict(form=form)
On Aug 26, 5:38 am, Noel Villamor <[email protected]> wrote:
> The model:
>
> db.define_table('comment', Field('txt'), Field('tag'))
>
> How do I pass/access the variable xyz, and the txt and tag field
> values in funcdone below?
>
> def funcdone(form):
> comment_id = form.vars.id
> ...
>
> def post_comment():
> xyz = 123
> form = crud.create(db.comment, onaccept=funcdone)
> return dict(form=form)
>
> Thanks!