Přejít na obsah
Menu
You need to be registered to interact with the community.
This question has been flagged
1 Odpovědět
1800 Zobrazení

I am rookie of odoo and I am confused with some fields like the 'field' in the mail,

I cannot understand the usage of many2one field filling comodel_name with 'ir.model.fields'.

Please help me out and thank you.

Avatar
Zrušit
Nejlepší odpověď

Helllo, Enish


I hope you're doing well.


In Odoo, a `Many2one` field creates a relationship between two models. When you set `comodel_name` to `ir.model.fields`, you’re linking to a model that represents fields within other models in Odoo.


The `ir.model.fields` model stores information about all fields across Odoo, including their names, types, and associated models. This is particularly useful for configurations where you need to reference specific fields dynamically across different models.


You can refer the attached images.


The "Customer" field is a `Many2one` field with `comodel_name` set to `res.partner`, which means it displays all customer records from the "res.partner" model in the dropdown.






I Hope this information proves helpful to you. 

Thanks & Regards, 
Email: odoo@aktivsoftware.com 
Skype: kalpeshmaheshwari

Avatar
Zrušit
Autor

Thanks for your helping.
:)

Related Posts Odpovědi Zobrazení Aktivita
1
led 22
3274
2
čvn 19
2731
0
pro 15
5084
0
bře 15
4442
1
srp 23
2741