[web2py] Re: Passing variables and field values to crud onaccept function

2011-08-26 Thread Noel Villamor
Excellent! This is what I love w/ web2py, it is s flexible! On Aug 27, 12:14 am, Massimo Di Pierro wrote: > 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,

[web2py] Re: Passing variables and field values to crud onaccept function

2011-08-26 Thread Massimo Di Pierro
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 wrote: > The model: > > db.define_table('comment', Field('t