Hello, Does anyone know how to update hidden fields on a smartgrid?
I have this table definition db.define_table('so', Field('code', 'string', label=T('Code')), # PHC Field('co_id', 'reference co', label=T('Client order'), writable=False, readable=False), Field('co_code', 'string', label=T('Client order code')), # PHC Field('delivery', 'date', label=T('Delivery')), Field('export', 'boolean', default=False, label=T('Export')), Field('notes', 'string', label=T('Notes')), Field('converted', 'datetime', label=T('Converted'), writable=False), Field('last_rec_change', 'datetime', label=T('Last record change'), writable=False), format='%(code)s') db.so.code.requires = (IS_NOT_EMPTY(), IS_NOT_IN_DB(db, 'so.code')) # filled in the controller if co_code is filled db.so.co_id.requires = IS_EMPTY_OR(IS_IN_DB(db, 'co.id')) and then I would like to update co_id in the controller (based on co_code input). I've tried using the db.so.co_id.default on the onvalidation/oncreate/onupdate with no success. Any ideas? Thanks in advance, JM -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list (Report Issues) --- You received this message because you are subscribed to the Google Groups "web2py-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to web2py+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.