David, 10 minutes after your original post there was already a reply: http://groups.google.com/group/web2py/browse_thread/thread/de36120b9337f00d/1fde78aa5827a84c?hl=en&lnk=gst&q=override+default+model+values+in+SQLFORM#1fde78aa5827a84c
2009/7/10 David Zejda <d...@atlas.cz>: > > -----BEGIN PGP SIGNED MESSAGE----- > Hash: SHA1 > > Please, do you have any advices? > > David Zejda napsal(a): >> Hello, >> >> I have table with a "subject" field, with default value specified in model. >> >> Now I would like to generate forms to add and update records. >> In the forms the default value specified in the model has to be >> overriden on certain conditions. >> >> I tried these: >> >> form.vars.subject = "another default value" >> >> form.custom.dspval.subject = "another default value" >> >> form.custom.inpval.subject = "another default value" >> >> But none of them works, still there are model default values pre-filled in >> the form fields. >> >> Please, could you help? >> >> Thanks in advance.. >> >> David > -----BEGIN PGP SIGNATURE----- > Version: GnuPG v1.4.9 (GNU/Linux) > Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org > > iEYEARECAAYFAkpXPrEACgkQ3oCkkciamVGzkACgo5qrBcRjdXm975QkirF85B9F > qOAAoIaIojQTG4Jfx2bhdet7Hx0VzQMz > =02Cn > -----END PGP SIGNATURE----- > > > > --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "web2py Web Framework" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~----------~----~----~----~------~----~------~--~---