Thank you for your answer, but the example i've seen :
def _get_selection(self, cursor, user_id, context=None):
return (
('choice1', 'This is the choice 1'),
('choice2', 'This is the choice 2'))
_columns = {
'sel' : fields.selection(
_get_selection,
'What do you want ?')
}
for example : the adherant list contains 3 people : Amine, Yassine, Karim and each one with its affilie list "one2many field"
Amine(Joe, Daniel, Michael) ; Yassine(Susan, Barbara, yoland) and Karim(Nadir, Nabil, Najm )
How to do the following dynamically :
When I choose Amine for example, I get only the 3 affilies Joe, Daniel, Michael on the second list to choose from; If I choose Yaasine on the adherant field, I should have only the 3 affilies Susan, Barbara, yoland instead of all the affilie that have been created in the affilie table.
I'm really stuck with this, because i do not know how to compare between the adherant name and the object got from the browse function
and how to put my code using the onchange function so that the choice of affilie depends dynamically on the adherant field
Thank you very much !