Hello Dear web2py users,
I would like to achieve this.
I have a referenced field 1 to many
The referenced table is mostly for storing the dropdown option.
So I have :
IS_IN_DB(choice1, choice2, etc.)
I would like to add on the same form a empty choice field that could
populate the referenced choice table...
Field ('choice_id', db.choice),
db.choice # That let add new choice.
But
1) If the db.choice input is empty don't want add NULL value
2) I would if no choice is made and a new choice is added that choice_id
takes the id of the new added choice...
Can I get something to work with "compute" that seems reserved for only one
table.
How to prevent a empty db.choice input to be inserted... Is there any
validator that could applied??
Thanks
Richard