Currency Mixin
by OpenSynergy Indonesia https://simetri-sinergi.id , PT. Simetri Sinergi Indonesia https://simetri-sinergi.id
Odoo
| Availability |
Odoo Online
Odoo.sh
On Premise
|
| Community Apps Dependencies | Show |
| Lines of code | 124 |
| Technical Name |
ssi_currency_mixin |
| License | AGPL-3 |
| Website | https://simetri-sinergi.id |
Currency Mixin
ssi_currency_mixin provides an abstract Odoo model — mixin.currency — that standardises multi-currency handling on transactional documents.
Any model that inherits from mixin.currency automatically gains:
- currency_id — the transaction currency, defaulting to the company’s currency.
- company_id — the owning company.
- rate_inverted — mirrors the rate_inverted flag from the currency master.
- rate — the exchange rate in use for the transaction date.
- onchange_rate_mixin — auto-fills rate from the currency master whenever currency_id or company_id changes.
- _convert_amount_to_company_currency — helper that converts a transaction-currency amount to the company currency using rate and rate_inverted.
Subclasses set _exchange_date_field to the name of the date field used for historical rate look-ups.
Installation
To install this module, you need to:
- Clone the branch 14.0 of the repository https://github.com/open-synergy/ssi-mixin
- Add the path to this repository in your configuration (addons-path)
- Update the module list (Must be on developer mode)
- Go to menu Apps -> Apps -> Main Apps
- Search For Currency Mixin
- Install the module
Bug Tracker
Bugs are tracked on GitHub Issues. In case of trouble, please check there if your issue has already been reported. If you spotted it first, help us smash it by providing detailed and welcomed feedback.
Credits
Contributors
- Andhitia Rama <andhitia.r@gmail.com>
Maintainer
This module is maintained by the PT. Simetri Sinergi Indonesia.
Please log in to comment on this module