-
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
213 select country #214
213 select country #214
Conversation
Thanks for this. I've merged your changes into a country_select branch ( see https://github.com/fatfreecrm/fat_free_crm/tree/country_select ) I've also added a 'preferred_countries' option to the address helper and settings file. Now that I'm looking at the script, I'm wondering if there are will be conversion clashes when the rake task is run... e.g. someone chose Australia (incorrectly marked as 'AT') prior to this work, but now it will display as 'Austria' instead. The rake script won't currently auto-migrate this as it's only looking for country names, not bad ISO's. I think we should fix that by enumerating all the existing errors and then encourage people to update and run the country rake script. By the way, was the country_select really badly wrong in many cases? Or did they use a different ISO standard? Also, I'm wondering if, in the near future, we should consider moving to a more first class country model so that addresses can easily extract the country name. Currently there is no way to get at the country list from outside the FormHelper. Anyway, that's for later. Thanks again for your work here, it's much appreciated. |
Thanks for adding the settings. I am not sure what you mean by The convert_table array in the rake task contains the old and the new code of a country. The only place where I see problems where the old country codes are the same About the ISO codes, Thanks for the help and guidance, it is really appreciated. |
My bad, I think all you've done is right. Australia was 'AS' in the old system and in the new it is corrected to "AU" so there won't be a problem. I'm hoping to incorporate this tomorrow. |
Great to hear that. :) |
Pushed to master as of c805554 Thanks for your help! |
Hi,
I have created this pull request based on our discussion on issue #213.
I have also added the rake task for data upgrade. (this can be possibly written for faster execution, if needed)
Please examine with care, this request changes the format how ffcrm stores countries.
A bug can cause data loss for users.
If any questions arise, feel free to contact me.
Cheers,
Balázs
P.S.: The requested, storing preferred countries in settings file, will come in a separate request.