Package: django-metasettings
A reusable Django application to control the currency rate and favorite
language code, inspired by etsy.First you need to request an app id atopen exchange ratesto import currency rates.InstallationTo install it, simplypip install django-metasettingsAdd ‘metasettings’ to yourINSTALLED_APPSINSTALLED_APPS = (
    'metasettings',
)If you want to install the dashboard to allow your users to select a language
and a currency you will have to install urls from metasettings like so# urls.py

from django.conf.urls import patterns, include

urlpatterns = patterns(
    '',
    (r'^', include('metasettings.urls'))
)You can add your proper stylesheet to this dashboard view and have this kind
of result:UsageTo import current currency rates, run$ python manage.py sync_rates --app_id=openexchangesratesappidTo import currency rates in a date range, run$ python manage.py sync_rates --app_id=openexchangesratesappid --date_start=2011-10-01 --date_end=2013-10-01It will import for each months between the two dates the currency rates.The OpenExchangeRates app id can also be stored in theOPENEXCHANGERATES_APP_IDDjango setting.If you can to convert an amount from on currency to another:frommetasettings.modelsimportconvert_amountconvert_amount('EUR','USD',15)# ~20 eurosBy default it will return a full decimal, if you want a converted integer:frommetasettings.modelsimportconvert_amountconvert_amount('EUR','USD',15,ceil=True)# ~20 eurosTo retrieve the currency with a client IP Address:frommetasettings.modelsimportget_currency_from_ip_addressget_currency_from_ip_address('78.192.244.8')# EURWe are usingGeoIPwhich gives you the ability to retrieve the country and
then we are linking the country to an existing currency.So don’t forget to import a fresh GeoIP database and be sure to haveGEOIP_PATHin your settings.We recommend to usedjango-geoip-utilswhich provides some helpers to manipulate GeoIP API.CurrencyFieldA currency field for Django models that provides all ISO 4217 currencies as choices.CurrencyFieldis based on Django’sCharField, providing choices
corresponding to the official ISO 4217 list of currencies (with a defaultmax_lengthof 3).Consider the following model using aCurrencyField:fromdjango.dbimportmodelsfrommetasettings.fieldsimportCurrencyFieldclassProject(models.Model):name=models.CharField(max_length=100)currency=CurrencyField()AnyProjectinstance will have acurrencyattribute that you can use to
get details of the project’s currency:>>>project=Project(name='My project',currency='EUR')>>>project.currencyCurrency(code='EUR')>>>project.currency.label'Euro'>>>project.currency.symbol'€'>>>project=Project(name='My project',currency='USD')>>>project.currencyCurrency(code='USD')>>>project.currency.label'United States Dollar'>>>project.currency.symbol'$'>>>project.currency.trigram'USD'This object (project.currencyin the example) is aCurrencyinstance,
which is described below.Useblank_labelto set the label for the initial blank choice shown in
forms:currency = CurrencyField(blank_label='(select currency)')RoadmapseeissuesThis application only includes major currencies, don’t hesitate to send
patch or improvements.InspirationsTheCurrencyFieldis heavily inspired fromCountryFieldof the greatdjango-countries