Skip to Content
Menu
This question has been flagged
1 Reply
2976 Views

I have many computed fields in my database that calculate the days until they are due.   However I have trigger the field to compute every day, is there a way for Odoo to automatically run my computed fields every morning? 

Avatar
Discard
Best Answer

To run certain job with stated periodicity, you can use scheduled jobs (cron jobs). Have a look at:

Take into account that computed fields are not obliged to be stored into a database. It is possible to trigger re-computing on a fly (when a form with that field is opened or when a field is used in a code). Thus, if you added store=False to your computed field, it would not be required to re-compute it, since the field would be computed when it is needed. 

To sum up: at the moment you have a stored field which depend on other fields + depends on dynamic date ('today'). Hence, you might either trigger recomputing by scheduled jobs or make a field not stored.


Avatar
Discard