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

hello,

I've made a new menu to the existing one "HR". Into my view, I do: model=hr.employee

after I only use the field "name" because i only need this one. However, when i come back to the menu employee (the existing) ...It 's became the same that mine. With just the field name.

How can i use the fiel name of employees without having this problème?

Sorry for my bad english and thank ou in addvance to your answer.

Jonathan

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

Hi,

in fact in the view and/or python class, you must use attribute inherit, then without this attribute, the original view will be replaced by yours ...

but without your code, we can just imagine ...

Bye

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

First thanks to yours answers, it was helpfull.

For the right answer: i had to use inherit but I had not to repalce the original.

So the solution was to use the attribute "priority" into my new view and put it in a greater number than the original.

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

Hi, sorry, you're right, my answer was bad, I believe the question talking about a new view (but this is for a menu). you shoukd post your code too, it will be better to understand and answer. The important thing is you have finfd solution by yourself, good. Bye