-
Notifications
You must be signed in to change notification settings - Fork 56
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Select a valid choice. That choice is not one of the available choices. #16
Comments
The error seems to be from the ChoiceField or its subclass and there are no ChoiceFields mentioned in README. I've just entered this address to the form from one of my projects and it works fine ( http://pix.am/uMa8.png ). Could you please provide more details? Are you using django admin? How is your 'address' field defined? Original comment by: Mikhail Korobov |
Yes, I'm trying to use it in the admin interface Well, there's a property model related as defined }}} and here's PropertyAdmin {{{
}}} Now, it appears that the address field puts the generated address id when i press [+] to add a new address. Thanks Original comment by: Ahmed Youssef |
It may be not clear from the readme, but address field should be CharField or TextField, not a ForeignKey to Address model. Address model should be considered implementation detail. Its sole purpose is to avoid using geocoder for each request, that's a kind of persistent cache. Its description is included in readme only because it can be useful for custom map templates. If text is changed in 'address' field then new Address instance will be auto-created on first map access. Thanks for reporting this issue. I've just re-read the readme and it is indeed not clear what is 'address' field supposed to be. Original comment by: Mikhail Korobov |
Clarified readme. Fix #2. → <<cset 8ced16c04330>> Original comment by: Mikhail Korobov |
but how to use it as a foreign key, what would be the approach to have it as a property to another model? Original comment by: Anonymous |
I've followed the docs on the integration as specified in README file.
Now, whenever I type an address, say, "10900 Euclid Ave, Cleveland, OH 44106, USA" I get an error "Select a valid choice. That choice is not one of the available choices."
The text was updated successfully, but these errors were encountered: