diff options
-rw-r--r-- | README | 6 | ||||
-rw-r--r-- | app/locations/models.py | 16 | ||||
-rw-r--r-- | config/requirements.txt | 3 | ||||
-rw-r--r-- | config/settings/settings.py | 1 | ||||
-rw-r--r-- | config/settings/settings_dev.py | 7 | ||||
-rw-r--r-- | design/templates/base.html | 4 |
6 files changed, 30 insertions, 7 deletions
@@ -23,3 +23,9 @@ What I should do is refactor both into a single clean module with methods for bu # The whole goddamn thing. In build each model has a build function that calls all the routines necessary to build everything. I like that model, but then I need to expose those functions a bit more. + +ToDo: + +build out entry aside model +Add JavaScript to dynamically build asides. maybe. +create css for large image pages light and dark (should just need structural css, dark class name could be enough to work for large image dark pages. diff --git a/app/locations/models.py b/app/locations/models.py index e088697..6fc85cf 100644 --- a/app/locations/models.py +++ b/app/locations/models.py @@ -159,6 +159,22 @@ class Location(models.Model): def __unicode__(self): return self.name +class BirdingLocation(models.Model): + location = models.ForeignKey(Location) + name = models.CharField(max_length=50) + slug = models.SlugField() + date_visited = models.DateTimeField('Date visited',null=True) + point = models.PointField() + # GeoManager, a subclass that adds a rich set of geospatial queryset methods + objects = models.GeoManager() + + def get_absolute_url(self): + return "/birdinglocations/%s/%s/%s/" % (self.state.country.slug, self.state.slug, self.slug) + + + def __unicode__(self): return self.name + + class Route(models.Model): name = models.CharField(max_length=200) slug = models.SlugField() diff --git a/config/requirements.txt b/config/requirements.txt index 88b3bea..043e5e5 100644 --- a/config/requirements.txt +++ b/config/requirements.txt @@ -1,7 +1,6 @@ -Django==1.5c1 +Django==1.5.1 Markdown==2.2.0 PIL==1.1.7 -PyGithub==1.11.0 distribute==0.6.31 django-extensions==0.9 httplib2==0.7.7 diff --git a/config/settings/settings.py b/config/settings/settings.py index 47b5562..a2c37d3 100644 --- a/config/settings/settings.py +++ b/config/settings/settings.py @@ -142,6 +142,7 @@ INSTALLED_APPS = ( 'projects', 'guide', 'pages' + 'birds' ) diff --git a/config/settings/settings_dev.py b/config/settings/settings_dev.py index 010ac31..1f2e4e9 100644 --- a/config/settings/settings_dev.py +++ b/config/settings/settings_dev.py @@ -19,6 +19,7 @@ DATABASES = { 'ENGINE': 'django.contrib.gis.db.backends.postgis', 'USER': 'luxagraf', 'PASSWORD': 'translinguis', + 'HOST': 'localhost', } } @@ -29,7 +30,7 @@ SITE_URL = 'http://luxagraf.net/' GRAPPELLI_ADMIN_TITLE = 'Luxagraf Admin' USE_I18N = False USE_L10N = True -USE_TZ = True +USE_TZ = False #API key for Google Maps in Admin MAP_API = "google" @@ -142,8 +143,8 @@ INSTALLED_APPS = ( 'templatetags', 'projects', 'guide', - 'pages' - + 'pages', + 'birds' ) DEVELOPMENT = True if DEVELOPMENT: diff --git a/design/templates/base.html b/design/templates/base.html index ea85022..606d989 100644 --- a/design/templates/base.html +++ b/design/templates/base.html @@ -36,8 +36,8 @@ </a> <nav role="navigation" class="bl"> <ul> - <li id="stories"><a href="/writing/1/" title="An archive of writings from around the world">Writing</a>,</li> - <li id="photos"><a href="/photos/1/" title="Photos from travels around the world">Photos</a>,</li> + <li id="stories"><a href="/writing/" title="An archive of writings from around the world">Writing</a>,</li> + <li id="photos"><a href="/photos/" title="Photos from travels around the world">Photos</a>,</li> <!--<li id="guides"><a href="/travel-guide/1/" title="Travel Guides, Tips, Tricks and Recommendations">Guides</a>,</li>--> <li id="maps"><a href="/map/" title="Maps and miscellanea">Map</a>,</li> <li id="projects" ><a href="/projects/" title="Luxagraf: Projects">Projects</a>,</li> |