On Fri, Jul 26, 2013 at 6:32 AM, Dennis Backhaus < [email protected]> wrote:
> Maybe I was not clear enough: > > 1) I need the form to be prefilled based on an argument I give to the page > via the URL. > > Fetch the model from the database inside the controller that displays the form, create a dictionary of the values (vars() is usually enough) and pass it to the form. > 2) I want the form to only be accessible if PAGE/admin/user?customer_id?=X > (X being any existing customer_id) is called. If you do not submit > ?customer_id=X, I want the page to urge you to do it. > > Just add a validator over customer_id to the page that displays the form. SQLAEntityConverter might be convenient: https://bitbucket.org/_amol_/tgext.datahelpers#rst-header-validators -- You received this message because you are subscribed to the Google Groups "TurboGears" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/turbogears. For more options, visit https://groups.google.com/groups/opt_out.

