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

Hi all,


I set my custom module inherit one existing module, and using "@api.depends(<field-from-inherited-module>) def <function-name>", but found a Key error that from the field from inherited module. But it seem well if I re-declare the field (I had copied fully codes of the field from the original module to my module). I would like to know is there a way to call the fields from inherited module to custom module?


Thanks.

Qho


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

Ensure that you added dependency to first one 

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

Thanks. Sorry for my minor mistake.

I found that I wrongly inherited the custom module to module-B and that should be module-A.


Thanks a lot.

Qho


Ảnh đại diện
Huỷ bỏ