We should have a default country and an admin setting. The admin setting would control what is given as a default if the user's country is not installed. Either (a) global (no country) or (b) the default country.
We should have a default country and an admin setting. The admin setting would control what is given as a default if the user's country is not installed. Either (a) global (no country) or (b) the default country.
Comments
Comment #1
nedjoAdded ability to set default country.
Comment #2
nedjoNeed to require a default country if a country is installed. Follow approaches in locale.inc.
Comment #3
nedjoComment #4
nedjoChanges needed (following locale module handling of languages where similar handling exists):
1. First country created is automatically the default. (Locale not applicable, since English is installed by default.)
2. Enabled checkbox is locked for the default country.
3. Handling in the submit handler to pass 'enabled' value through for disabled checkbox.
4. Delete handling.
Comment #5
nedjoComment #6
nedjoCommitted a set of fixes. Needs more testing.
Comment #7
catchI added a check to http://d6.6/admin/settings/country-code-country/%country to disable the checkbox and add a description if it's the default - since you could disable the default country from there despite it being prevented in the overview.
Couple of possible follow-ons, both minor IMO:
1. Do we want to hide delete links for the default country?
2. When there's only one country available should this be the default?
3. If yes to 2 and 3, how do we remove a country if there's only one? (since it'd be impossible to remove it as the default, or disable it)
Comment #8
catchThis is now in site_country module.