Skip to Content
เมนู
คุณต้องลงทะเบียนเพื่อโต้ตอบกับคอมมูนิตี้
คำถามนี้ถูกตั้งค่าสถานะ
1 ตอบกลับ
3079 มุมมอง

How do I hide fields in one2many's view?

I will explain my question:

I have created a new module that should add to each employee's card its list of children.

The module is inherited from hr.employees and contains two models:

* A new model (children) that creates the children's table when each child has several parameters and one of them is the parent's ID.

* Another model inherited from hr.employees that also contains a one2many field that is linked to the children's model.


So far everything is working fine, and I can view the fields I want from the model.

My problem is in creating a new child, a popup opens for me where I have to fill in all the child's data, and among them also select (in the dropdown) the parent.

I do not want to present this field, in particular that what is actually stored in DB is the employee for whom I created the child, regardless of the parent I chose.

How can I remove this field from view?

The pop-up view is something automatic, which I did not create but probably comes from the one2many setting, and of course I cannot remove the parent_id field from the model - this is the field that links it to the parent.


Is there a way to solve this?

อวตาร
ละทิ้ง
คำตอบที่ดีที่สุด

Create your own form view without that field.

อวตาร
ละทิ้ง
Related Posts ตอบกลับ มุมมอง กิจกรรม
3
เม.ย. 15
4948
2
เม.ย. 15
4370
2
ธ.ค. 23
10514
1
ธ.ค. 19
5071
0
มิ.ย. 18
3383