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

Hi, I just wanna now how I could make an @api.onchange, but from a field of another class, like:


I have in account.move the field "x"

And I have a method in account.move.line, that I want to use when the field "x" from account.move changes.


I tried @api.onchange(move.x) or @api.onchange(account.move.x) but it doesen't works : /


Thanks in advance

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

Hi,

try this:

@api.onchange(xx_id.x)

Note: xx_id is the  Many2one field.

2 Classes are related by the Many2one field and One2many field.

Hop it is useful.


Ảnh đại diện
Huỷ bỏ
Bài viết liên quan Trả lời Lượt xem Hoạt động
3
thg 2 24
3402
2
thg 9 21
10901
0
thg 5 16
3388
2
thg 3 15
3598
4
thg 2 25
7172