OCA / l10n-argentina

Odoo modules for Argentina
GNU Affero General Public License v3.0
21 stars 51 forks source link

[ADD] Add cities data file and object #33

Closed gabrielo77 closed 8 years ago

gabrielo77 commented 8 years ago

This commit adds cities data and object that are loading automatically on module installation. It could be useful to have an option that allows the users to choose if he/she wants to load the cities data file, because it has too many records and takes too much.

ivantodorovich commented 8 years ago

This is an outsider's question, but: Why not just make it compatible with _partner-contact/baselocation?

Then, this module would only need to add the data files.

pedrobaeza commented 8 years ago

Not only that, you can also benefit from https://github.com/OCA/partner-contact/tree/8.0/base_location_geonames_import, that imports the cities from all the existing countries in GeoNames (I think Argentina is in there).

ivantodorovich commented 8 years ago

It is there, I'm currently doing that in production.

But it takes a while to download... I don't know if it's such a bad idea to provide a simple data file, as an alternative.

pedrobaeza commented 8 years ago

In Spain we adapted this module for changing the states codes to fit with legal requirements, but the logic is there, and the best: You don't have to maintain an static data file!

ivantodorovich commented 8 years ago

Yeap.. not having to maintain a static data file is definitely a win.

But still, there are some cons.

In Argentina, the database of cities downloaded by the geonames import is HUGE. I mean, really HUGE. It contains records of cities that don't really exist anymore and I don't know if they ever did. I live in a very small town and it contains at least 5 names for it (of which I'd only ever head of 3!)

There are better databases (static, though). I remember fetching one a while ago from our local postal office (Correo Argentino) that was very clean.

Having said that. I still prefer geonamesimport, as @pedrobaeza suggested. Knowing I don't have to maintain a large static database of cities is priceless (not MasterCard related)_.

pedrobaeza commented 8 years ago

There's a procedure to request data modification in GeoNames database, so maybe that's the way to go.

ivantodorovich commented 8 years ago

Indeed, you are probably right!

gabrielo77 commented 8 years ago

Hi!

I didn't know this modules, I'll have a look at them! Thank you!

Of course, I don't want to maintain a large data file either, but it is something that it's needed right now.

On 10 March 2016 at 21:49, Iván Todorovich notifications@github.com wrote:

Indeed, you are probably right!

— Reply to this email directly or view it on GitHub https://github.com/OCA/l10n-argentina/pull/33#issuecomment-195120717.

Gabriel.

sebastiken commented 8 years ago

Merged! Then we will analyze to use base_location_geonames_import. Thanks @gabrielo77