Siirry sisältöön
Menu
Sinun on rekisteröidyttävä, jotta voit olla vuorovaikutuksessa yhteisön kanssa.
Tämä kysymys on merkitty
2 Vastaukset
3544 Näkymät

where can i find information about models in odoo.
like there are a model called "Email Threads" and i don't know what this model do.

Avatar
Hylkää
Paras vastaus

mail_thread model is meant to be inherited by any model that needs to act as a discussion topic on which messages can be attached. Public methods are prefixed with ``message_`` in order to avoid name

collisions with methods of the models that will inherit from this class.

``mail.thread`` defines fields used to handle and display the communication history.

``mail.thread`` also manages followers of inheriting classes. All features and expected behavior are managed by mail.thread. Widgets has been designed for the 7.0 and following versions of Odoo.

Inheriting classes are not required to implement any method, as the default implementation will work for any model. However it is common to override at least the ``message_new`` and ``message_update`` methods (calling ``super``) to add model-specific behavior at

creation and update of a thread when processing incoming emails.

You can find the description here:

https://github.com/odoo/odoo/blob/15.0/addons/mail/models/mail_thread.py#L36 

Please read the documentation about how to user mail.thread model:

https://www.odoo.com/documentation/15.0/developer/reference/addons/mixins.html?highlight=thread#messaging-features




Avatar
Hylkää
Paras vastaus

You can check in the comments in the source 

Avatar
Hylkää