I have a FloatField in one of my models. I add / edit it using ModelForms. What I need is that when editing, the Float value stored in the FloatField should display exactly with 2 precision points.
those. if my stored value is equal 1000.0 or 1000.123, I want the initial value to be displayed in the form input field 1000.00 or 1000.12.
Any suggestion on an approach would be appreciated. Thank you all.
source
share