-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Skip populating states select on default country not included in available countries #3030
Skip populating states select on default country not included in available countries #3030
Conversation
6743379
to
4ecb4cf
Compare
4ecb4cf
to
2c54f53
Compare
2c54f53
to
9f1d5fb
Compare
de3934a
to
1bd4b36
Compare
Closes solidusio#1205. In the case that default country is not included within available countries, this commit leaves the states select empty, where previously was filled in with default country states which didn't match with any available country. The state select is later filled in by Select2, which knows which country option is selected. Server side we can't assume that the first country option is selected, because it doesn't play well with client side features, e.g. autocomplete.
1bd4b36
to
8814b86
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great work @mdesantis ! 🎉
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @mdesantis !
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! Thanks!
Description
Closes #1205. it:
country. The state select is later filled in by Select2, which knows which country option is selected. Server side we can't assume that the first country option is selected, because it doesn't play well with client side features, e.g. autocomplete.
Checklist: