wger icon indicating copy to clipboard operation
wger copied to clipboard

Don't coerce decimals to strings in the API

Open rolandgeider opened this issue 4 years ago • 0 comments
trafficstars

The default behaviour of django rest framework seems to be to coerce decimals to string so they can be potentially localized ("2.1" vs "2,1"). This can be deactivated in the settings file, but first the App needs to be updated

https://www.django-rest-framework.org/api-guide/fields/#decimalfield

rolandgeider avatar Aug 26 '21 13:08 rolandgeider