Перейти к содержимому
Меню
Чтобы взаимодействовать с сообществом, необходимо зарегистрироваться.
Этот вопрос был отмечен
2 Ответы
4790 Представления

I need a mechanism that lets me listen for database events on models (insert, update, delete) and execute a function whenever such events occur. Something like Django signals post_save and post_delete.

So whenever an model object is saved i can execute my function and do something regarding the data that has just been saved.

Аватар
Отменить
Лучший ответ

You can override Odoo's ORM Functions from model.py. create, write, copy.. SO whenevet this fucntion is called from any model you can do the operations you need by using these datas.

Аватар
Отменить
Лучший ответ

if your Odoo installation is in Linux you can use a great tool called pg_activity

to install  open terminal and enter the following command

:~$  sudo pip install pg_activity

then switch to postgres user , type:

:~$  sudo su postgres

finally , type :

:~$ pg_activity



Regards,

Husam Mustafa

Аватар
Отменить