-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add text and change format of Readme file.
- Loading branch information
Showing
2 changed files
with
30 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
==================== | ||
Django World Regions | ||
==================== | ||
|
||
Simple Django app to group countries in world's regions like *Northern America*, *Eastern Europe*, etc. | ||
|
||
Regions data are based in http://techydiary.com/region-yaml-for-django-fixtures/ thanks Stephen for that. | ||
|
||
`Django Countries`_ is used to handle countries. | ||
|
||
.. note:: Currently this package don't use GeoDjango neither map data. | ||
|
||
Installation | ||
============ | ||
1. ``pip install django-world-regions`` | ||
2. Add ``world_regions`` to ``INSTALLED_APPS`` | ||
3. ``python manage.py migrate`` | ||
4. ``python manage.py loaddata fixtures/initial_data.json`` | ||
|
||
Usage | ||
===== | ||
|
||
.. code:: | ||
from world_regions.models import Region | ||
region = Region.objects.get(countries_country='US') | ||
print region.name | ||
.. _Django Countries: https://github.com/SmileyChris/django-countries |