mirror of
https://github.com/inventree/InvenTree.git
synced 2025-06-15 19:45:46 +00:00
Exchange rate plugin (#5667)
* Add plugin mixin class for supporting exchange rates * Split some mixin classes out into their own files - mixins.py is becoming quite bloated! * Add some new settings for controlling currency updates * Adds basic plugin implementation * Refactor existing implementation - Builtin plugin uses frankfurter.app API - Better error / edge case handlign * Add sample plugin for currency exchange * Allow user to select which plugin to use for plugin updates * Observe user-configured setting for how often exchange rates are updated * Updates for some of the sample plugins * Fix plugin slug * Add doc page * Document simple example * Improve sample * Add blank page for currency settings info * More info in "config" page * Update docs again * Updated unit tests * Fill out default settings values when InvenTree runs * Add log messages * Significant improvement in default settings speed - Use bulk create - Be efficient - Dont' be inefficient * More strict checks * Refactor default values implementation - Don't run at startup - Run on list API - Implement generic @classmethod
This commit is contained in:
31
docs/docs/settings/currency.md
Normal file
31
docs/docs/settings/currency.md
Normal file
@ -0,0 +1,31 @@
|
||||
---
|
||||
title: Currency Support
|
||||
---
|
||||
|
||||
## Currency Support
|
||||
|
||||
InvenTree provides support for multiple currencies, allowing pricing information to be stored with base currency rates.
|
||||
|
||||
### Configuration
|
||||
|
||||
To specify which currencies are supported, refer to the [currency configuration](../start/config.md#supported-currencies) section
|
||||
|
||||
### Currency Conversion
|
||||
|
||||
Currency conversion is provided via the [django-money](https://github.com/django-money/django-money) library. Pricing data can be converted seamlessly between the available currencies.
|
||||
|
||||
### Currency Rate Updates
|
||||
|
||||
Currency conversion rates are periodically updated, via an external currency exchange server. Out of the box, InvenTree uses the [frankfurter.app](https://www.frankfurter.app/) service, which is an open source currency API made freely available.
|
||||
|
||||
#### Custom Rate Updates
|
||||
|
||||
If a different currency exchange backend is needed, or a custom implementation is desired, the currency exchange framework can be extended [via plugins](../extend/plugins/currency.md). Plugins which implement custom currency exchange frameworks can be easily integrated into the InvenTree framework.
|
||||
|
||||
### Currency Settings
|
||||
|
||||
In the [settings screen](./global.md), under the *Pricing* section, the following currency settings are available:
|
||||
|
||||
{% with id="currency-settings", url="settings/currency.png", description="Currency Exchange Settings" %}
|
||||
{% include 'img.html' %}
|
||||
{% endwith %}
|
Reference in New Issue
Block a user