Django percentage form field

Viewed 5997

I want to use a percentage form field in Django. Basically in my models I have a float field. The default when using a model form is a text input that validates that it is a number. If the user wants to enter 40%, they must enter 0.4. What I want is an optional percentage symbol that they can enter. Therefore, they can either enter 0.4 or 40%.

Is there something like that built into Django? If not, why? I would expect this to be something that is used often. Or do I tell them it is an percentage field and force them to just fill in 40?

1 Answers
Related