Last active
August 11, 2018 11:36
-
-
Save oerp-odoo/751742ec2a291e2ad3d6b3dc0ff5ce4a to your computer and use it in GitHub Desktop.
Recompute Odoo field from shell
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# python3 odoo-bin shell -c odoo.conf -d <database> | |
model = env['some.model'] | |
env.add_todo(model._fields['field_name'], model.search([])) | |
model.recompute() | |
env.cr.commit() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment