Bỏ qua để đến Nội dung
Menu
Câu hỏi này đã bị gắn cờ
1 Trả lời
2691 Lượt xem

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?


Ảnh đại diện
Huỷ bỏ
Câu trả lời hay nhất

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

Ảnh đại diện
Huỷ bỏ
Bài viết liên quan Trả lời Lượt xem Hoạt động
1
thg 6 19
2512
1
thg 4 17
4807
1
thg 7 25
392
Search a message Đã xử lý
1
thg 2 25
1213
0
thg 9 23
2156