Skip to Content
मेन्यू
This question has been flagged
1 Reply
3700 Views

Hi guys, 

I am  trying to filter the list of my many2one field

 

def _selection_function(self, cr, uid, context=None):

vals = []

<some condition >

record = id,name
vals.append(record)

return vals

fields.many2one('my.model', 'Field Name', selection=_selection_function )

But in the browser , still display all record of my model, 

Avatar
Discard
Author Best Answer
Avatar
Discard
Related Posts Replies Views Activity
0
अक्तू॰ 20
3246
0
मार्च 15
3072
1
मार्च 15
6218
1
सित॰ 23
1716
1
जुल॰ 19
6789