- Added ability to configure decimal places output. #154, #251 (ivanchenkodmitry)
- Fixed handling of
defaults
keyword argument inget_or_create
method. #257 (kjagiello)
- Fixed
understands_money
behaviour. Now it can be used as a decorator #215 (Stranger6667) - Do not fail comparisons because of different currency. Just return
False
#225 (benjaoming and ivirabyan) - Fixed: Not possible to revert MoneyField currency back to default #221 (benjaoming)
- Fixed invalid
creation_counter
handling. #235 (msgre and Stranger6667) - Fixed broken field resolving. #241 (Stranger6667)
- Fix packaging.
NB! If you are using custom model managers not named objects and you expect them to still work, please read below.
- Improved South support (Stranger6667)
- Added support for
Value
andFunc
expressions in queries (Stranger6667) - Added Django REST Framework support #179 (Stranger6667)
- Changed auto conversion of currencies using djmoney_rates (added in 0.7.3) to be off by default. You must now add
AUTO_CONVERT_MONEY = True
in yoursettings.py
if you want this feature. #199 (spookylukey) - Fixed default currency value for nullable fields in forms #138 (Stranger6667)
- Added
in
lookup support (Stranger6667) - Fixed
_has_changed
deprecation warnings #206 (Stranger6667) - Added Django 1.10 support #198 (Stranger6667)
- Only make objects a MoneyManager instance automatically #194 and #201 (inureyes)
- Fixed
get_or_create
crash, whendefaults
is passed. #213 (Stranger6667, spookylukey)
In 0.8, Django-money automatically patches every model managers with MoneyManager
. This causes migration problems if two or more managers are used in the same model.
As a side effect, other managers are also finally wrapped with MoneyManager
. This effect leads Django migration to point to fields with other managers to MoneyManager
, and raises ValueError
(MoneyManager
only exists as a return of money_manager
, not a class-form. However migration procedure tries to find MoneyManager
to patch other managers.)
From 0.9, Django-money only patches objects
with MoneyManager
by default (as documented). To patch other managers (e.g. custom managers), patch them by wrapping with money_manager
.
from djmoney.models.managers import money_manager
class BankAccount(models.Model):
balance = MoneyField(max_digits=10, decimal_places=2, default_currency='USD')
accounts = money_manager(MyCustomManager())
- Added support for serialization of
MoneyPatched
instances in migrations (AlexRiina) - Fixed fields caching #186 (Stranger6667)
- Fixed m2m fields data loss on Django < 1.8 #184 (Stranger6667)
- Improved django-money-rates support #173 (Stranger6667)
- Fixed managers access via instances #86 (Stranger6667)
- Fixed currency handling behaviour #172 (Stranger6667)
- Many PEP8 & flake8 fixes (benjaoming)
- Added pre-commit hooks support (benjaoming)
- Fixed filtration with
F
expressions #174 (Stranger6667) - Fixed querying on Django 1.8+ #166 (Stranger6667)
- Extended
F
expressions support (Stranger6667) - Added isort integration (Stranger6667)
- Refactored test suite (Stranger6667)
- Added Django master support (Stranger6667)
- Fixed Python 3.2 compatibility (Stranger6667)
- Added Makefile for common commands (Stranger6667)
- Added Codecov.io integration (Stranger6667)
- Added Python 3.5 builds to tox.ini and travis.yml (Stranger6667)
- Fix for
get_or_create
/create
manager methods not respecting currency code (toudi) - Fix unit tests (toudi)
- Fix for using
MoneyField
withF
expressions when using Django >= 1.8 (toudi) - Mention Django 1.9 in tox.ini (benjaoming)
- Added correct paths for py.test discovery (benjaoming)
- Fallback to
_meta.fields
if_meta.get_fields
raisesAttributeError
#149 (browniebroke) - pip Instructions updated (GheloAce)
- Fixed loaddata (jack-cvr)
- Python 2.6 fixes (jack-cvr)
- Fixed currency choices ordering (synotna)
- Support for Django 1.9 (kjagiello)
- Sum different currencies (dnmellen)
- Added
__eq__
method (benjaoming) - Comparison of different currencies (benjaoming)
- Default currency (benjaoming)
- Fix using Choices for setting currency choices (benjaoming)
- Fix tests for Python 2.6 (plumdog)
- Better checks on
None
values (tsouvarev, sjdines) - Consistency with South declarations and calling
str
function (sjdines)
- Tox cleanup (edwinlunando)
- Added Python 3 trove classifier (dekkers)
- Improved
README
(glarrain) - Appends _currency to non-money ExpressionFields #101 (alexhayes, AlexRiina, briankung)
- Data truncated for column #103 (alexhayes)
- Proxy Model with MoneyField returns wrong class #80 (spookylukey)
- Fixed
has_changed
not working #95 (spookylukey) - Added/Cleaned up tests (spookylukey, AlexRiina)
- Django 1.7 compatibility (w00kie)
- Added
choices=
to instantiation of currency widget (davidstockwell) - Nullable
MoneyField
should act asdefault=None
(jakewins) - Fixed bug where a non-required
MoneyField
threw an exception (spookylukey)
- Python 3 compatibility
- Added tox tests
- Added format localization
- Added tag
money_localize
- Fixed issues with money widget not passing attrs up to django's render method, caused id attribute to not be set in html for widgets (adambregenzer)
- Fixed issue of default currency not being passed on to widget (snbuchholz)
- Implemented the
south_triple_field
to add support for South migration (mattions) - Return the right default for South (mattions)
- Django 1.5 compatibility fix (devlocal)
- Fixed issues with
display_for_field
not detecting fields correctly (adambregenzer) - Added South ignore rule to avoid duplicate currency field when using the frozen ORM (rach)
- Disallow override of objects manager if not setting it up with an instance (rach)