[web2py] Prepopulate AutocompleteWidget causes Error

2011-04-06 Thread zip
I am using an AutocompleteWidget with and id_field set and would like to prepopulate the data for this widget. Say I have the following tables: Person with id and name fields Dog with id, name and owner fields I have the following line to setup the widget for dog.owner: db.dog.owner.widget = SQLF

[web2py] Re: Prepopulate AutocompleteWidget causes Error

2011-04-07 Thread zip
Thanks. I suspected that would work but wasn't sure if there was a solution through the SQLFORM class. I'll do it this way though. On Apr 6, 3:52 pm, DenesL wrote: > Try setting the field's default instead: > > db.dog.owner.default = 10 > > On Apr 6, 3:11 pm, zip