Skip to Content
Meniu
Trebuie să fiți înregistrat pentru a interacționa cu comunitatea.
Această întrebare a fost marcată
2 Răspunsuri
12330 Vizualizări
I would like to understand how the chatter records are generated and how they 
are related to the "owning" record.

What PostgreSQL tables & fields  are involved?
Imagine profil
Abandonează
Cel mai bun răspuns
Chatter is stored in the mail.message model which is persisted in the mail_message table in PostgreSQL.


When I add a chatter message to a Sales Order (id=7) like this:




The following mail.message record is created:



The fields that related it back to the "owning" record are Related Document Model (the model field) and Related Document ID (the res_id field).

WARNING:

You can EASILY end up corrupting your database by getting your data into an inconsistent state when you have an incomplete understanding of the schema and do not update the data tables and/or fields and/or related tables in a way that is consistent with the way the Odoo ORM manages data. 

We do not recommend using SQL DML (CREATE, INSERT, UPDATE, DELETE) statements with Odoo databases because this bypasses the business logic defined in the Python models - there will be no "validation" that your change is consistent, valid and is supported by the logical behavior of each model record (in addition, not all fields are persisted in PostgreSQL). 

We recommend using only SQL DQL (SELECT) statements with Odoo databases.

Odoo can only provide VERY LIMITED support to Users who elect to ignore these recommendations.
Imagine profil
Abandonează
Cel mai bun răspuns

Hello Ray, I'd like to know how can I access the mail.message records, like the one you just created on the sale order, how can I see the list of records?


Thank you.



Imagine profil
Abandonează
Related Posts Răspunsuri Vizualizări Activitate
4
dec. 24
30792
2
iun. 19
2806
2
mar. 15
9563
1
dec. 24
1530
1
nov. 24
2006