跳至內容
選單
此問題已被標幟
1 回覆
2664 瀏覽次數

So every partner have this fields that I added to list fields in my method. those fields are many2one fields with comodel 'product.category' so they are in the same table. how can I retrieve id's of all this field for a current partner?


頭像
捨棄
最佳答案

Hi,

would you like to get current partner field value by key? Then, just use it in brackets.

for field in fields:    
    print (self[field])

If you want to find ir.model.fields record, just use standard Odoo search by model and field name

頭像
捨棄
相關帖文 回覆 瀏覽次數 活動
1
6月 19
2500
1
4月 17
4791
1
7月 25
380
1
2月 25
1202
0
9月 23
2146