Re: [web2py] simple controller question

2013-09-13 Thread Richard Vézina
Hi Alex, I didn't read carefully your code but just a couple advice... With SQLFORM.factory you need to insert you data yourself like this : form = SQLFORM.factory(db.your_table_name, ...) if form.process().accept: id =

Re: [web2py] simple controller question

2013-09-13 Thread Alex Glaros
Thanks Richard, works correctly now. What does this mean? About you predefined choice from a all ready existing record (update mode with .factory()), I you have to set the default value for the form base on the value extract form the DB for the existing record Do you mean I should copy this

Re: [web2py] simple controller question

2013-09-13 Thread Richard Vézina
As I wrote I didn't take time to read all you code... It just mean that if you want to use SQLFORM.factory() in update mode like crud.update you can't just pass the id of the edited record. The way it works with factory is tu use default=value for each field to set the value of the record in the

[web2py] simple controller question

2013-09-12 Thread Alex Glaros
Anybody see anything wrong with the second controller below that gets called by the first one? The error is that no data gets written to table IdeaComment, but if I substitute smartgrid for factory, all suggestions instead of just the one selected in the first controller get displayed, and