[web2py] Re: Manipulating Items in DropDown List using SQLFORM

2016-09-15 Thread Brian Boatright
In my models.py where I setup the database tables I have a row db.define_table('item', Field('parentid','integer', label='Part of'), Field('itemtypeid', db.itemtypes, required=True, requires=IS_IN_DB(db,db.itemtypes,'%(name)s',orderby='id',error_message='Select a

[web2py] Re: Manipulating Items in DropDown List using SQLFORM

2016-09-05 Thread Nico de Groot
There *is* an option to add records to the table: auto_add (but it defaults to false). Otherwise AFAIK no changes to the tables are made. You can check this by looking at the source code if you really want to be sure. See http://web2py.readthedocs.io/en/latest/validators.html?highlight=is_in_db#

[web2py] Re: Manipulating Items in DropDown List using SQLFORM

2016-09-05 Thread Brian Boatright
That makes sense but doesn't IS_IN_DB create foreign keys in database or other relationships between the tables that might be effected? On Sunday, September 4, 2016 at 5:08:23 AM UTC-4, Brian Boatright wrote: > > I'm using SQLFORM and was able to add an orderby to the original model > class to s