- Odoo 11 Development Cookbook(Second Edition)
- Holger Brunn Alexandre Fayolle
- 56字
- 2021-06-25 22:48:47
How it works...
The get_precision() function looks up the name in the Decimal Accuracy's Usage field and returns a tuple representing 16-digit precision with the number of decimals defined in the configuration.
Using this function in the field definition, instead of having it hard-coded, allows the end user to configure it according to their needs.