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

Hi all,
I have a related field, and lot of data s with the field. Now i need to remove the related attribute from the field, means now i need to use the field as a normal field, but without losing the data. Is that possible ?
Note : It is a Many2one field.
Any suggestions ?

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

Hi,

You can do the above by re-writing the field and set the related attribute to '' (related='').

Eg:

field_name = fields.Many2one('your_relation', related='')

Hope it helps

Ảnh đại diện
Huỷ bỏ
Bài viết liên quan Trả lời Lượt xem Hoạt động
2
thg 3 15
17244
1
thg 1 19
3515
2
thg 12 24
4404
1
thg 11 24
3184
2
thg 4 23
18198