In 2002 Romania changed their ISO3 code from ROM to ROU. Ubercart should be updated to reflect this. See http://en.wikipedia.org/wiki/ISO_3166-1_alpha-3

It might be nice in the long term to collaborate with Countries API instead of maintaining a separate database of country and addressing data. Countries API has a more extensive list of countries than Ubercart.

Thanks

Comments

tr’s picture

Status: Needs review » Needs work

Can't just change the one INSERT - you have to write an update function so anyone with the wrong data in their DB can get the update.

The Drupal 7 version of Ubercart has a complete list of countries - every one of them.

Countries API is not sufficient. First, because it's not being maintained and will not be ported to D7, but more importantly because it doesn't include the zone information at all. And no, it's not complete - it's outdated. The D7 version of Ubercart has the most up-to-date country information.

neilnz’s picture

Status: Needs work » Needs review
StatusFileSize
new5.94 KB

Fair enough. I haven't checked out the D7 version of Ubercart. I should take a look.

I've figured out how the update mechanism work now. Revised patch attached. Note this required me to rename the file as part of the patch.

neilnz’s picture

StatusFileSize
new5.34 KB

Oops - that last patch had some extra cruft in it that it shouldn't have. Here's a cleaner one.

tr’s picture

Title: Fix for ISO3 code of Romania » Correct ISO 3-character country codes
Status: Needs review » Active

Thanks. I committed the fix for Romania. I noticed your patch changed every single line of the .cif file - this is probably because you have a different line terminator than Drupal standard. Regardless, if you can check next time to make sure that only the differences appear in the patch, not the entire file, it would make it a lot easier to see what you've actually changed.

I'm going to leave this issue open for now because I reviewed all 248 .cif files to se if any others had a wrong ISO 3-char code and I found two others that need fixing: Iran and Costa Rica. So I'm retitling this issue to include those as well.

neilnz’s picture

Yeah, I think it's because I asked Git to produce the simplest possible form of patch, and original patches don't have a way to rename a file (I had to rename romania_642_1.cif to romania_642_2.cif to change the version). My original patch shows the actual change I made to that file.

I did notice that the names (country_name) for Iran and Greece are in native script, whereas all the others are in English.

tr’s picture

Status: Active » Fixed

Fixed Romania, Costa Rica, and Iran in 6.x-2.x and 7.x-3.x.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.