unepwcmc/ProtectedPlanet — pull request #16 by migtorres (2014-06-19 17:44:36+00:00)
Title: Region import and stats

This pull requests adds the region data to the database and creates the statistics for it.

You must delete all the data and run rake db:seed to populate the tables and Wdpa::Importer.import in the console to import again the protected areas table.

#Seeds
Seeds file was changed. Country is the last table to be populated and includes the join column (region_id).

#Stats
Stats Module was completely refactored. Now we have Stats::Country, Stats::Regional, Stats::Global.

ALl the tests were adapted and they are fully working (test/unit/stats.rb)