diff options
author | luxagraf@c63593aa-01b0-44d9-8516-4b9c7e931d7f <luxagraf@c63593aa-01b0-44d9-8516-4b9c7e931d7f> | 2010-06-12 20:33:36 +0000 |
---|---|---|
committer | luxagraf@c63593aa-01b0-44d9-8516-4b9c7e931d7f <luxagraf@c63593aa-01b0-44d9-8516-4b9c7e931d7f> | 2010-06-12 20:33:36 +0000 |
commit | 6657ae24658383a9841450329a518327638651c0 (patch) | |
tree | 82e7fd81486a4b9154f58ed5ffe6ad48e4d8fbdb /apps | |
parent | 865f8c58c8c29aaf431076bfffb4cfc4e8116b2d (diff) |
reorganized lib
Diffstat (limited to 'apps')
-rw-r--r-- | apps/blog/models.py | 2 | ||||
-rw-r--r-- | apps/links/utils.py | 11 | ||||
-rw-r--r-- | apps/photos/utils.py | 4 | ||||
-rw-r--r-- | apps/photos/views.py | 7 | ||||
-rw-r--r-- | apps/projects/models/base.py | 2 |
5 files changed, 14 insertions, 12 deletions
diff --git a/apps/blog/models.py b/apps/blog/models.py index c3b5a3a..9995bc1 100644 --- a/apps/blog/models.py +++ b/apps/blog/models.py @@ -6,7 +6,7 @@ from django.contrib.sitemaps import Sitemap from django.template.defaultfilters import truncatewords_html -import markdown2 as markdown +from utils import markdown2 as markdown from tagging.fields import TagField from tagging.models import Tag diff --git a/apps/links/utils.py b/apps/links/utils.py index 9e5aea5..604ecab 100644 --- a/apps/links/utils.py +++ b/apps/links/utils.py @@ -4,14 +4,15 @@ from django.core.exceptions import ObjectDoesNotExist from django.template.defaultfilters import slugify,striptags from django.core.mail import EmailMessage from django.utils.encoding import smart_unicode +from django.conf import settings + -from strutils import safestr,unquotehtml -from APIClients import MagnoliaClient -import pydelicious as delicious +from utils.strutils import safestr,unquotehtml +from utils.APIClients import MagnoliaClient +from utils import pydelicious as delicious +from utils import markdown2 as markdown -import markdown2 as markdown from links.models import Link -from django.conf import settings def flickr_datetime_to_datetime(fdt): from datetime import datetime diff --git a/apps/photos/utils.py b/apps/photos/utils.py index 24991b2..137fe9f 100644 --- a/apps/photos/utils.py +++ b/apps/photos/utils.py @@ -28,13 +28,13 @@ except ImportError: raise ImportError("Could not import the Python Imaging Library.") -from strutils import safestr +from utils.strutils import safestr from photos.models import Photo,PhotoGallery # Flickr Sync stuffs API_KEY = settings.FLICKR_API_KEY -from APIClients import FlickrClient +from utils.APIClients import FlickrClient EXIF_PARAMS = {"Aperture":'f/2.8',"Make":'Apple',"Model":'iPhone',"Exposure":'',"ISO Speed":'',"Focal Length":'',"Shutter Speed":'',"Lens":'','Date and Time (Original)':'2008:07:03 22:44:25'} diff --git a/apps/photos/views.py b/apps/photos/views.py index 5ccec00..861f00e 100644 --- a/apps/photos/views.py +++ b/apps/photos/views.py @@ -5,7 +5,6 @@ from django.http import Http404,HttpResponse from django.core import serializers -from view_wrapper import luxagraf_render from tagging.models import Tag,TaggedItem from photos.models import Photo,PhotoGallery from locations.models import Country, Region @@ -24,8 +23,10 @@ def gallery_list(request,page): return object_list(request, queryset=qs, template_name='archives/photos.html') def gallery(request,slug): - g = PhotoGallery.objects.get(set_slug=slug) - return luxagraf_render(request,'details/photo_galleries.html', {'object': g,}) + context = { + 'object': PhotoGallery.objects.get(set_slug=slug) + } + render_to_response('details/photo_galleries.html', context, context_instance = RequestContext(request)) def photo_json(request, slug): p = PhotoGallery.objects.filter(set_slug=slug) diff --git a/apps/projects/models/base.py b/apps/projects/models/base.py index bc42918..96ccd59 100644 --- a/apps/projects/models/base.py +++ b/apps/projects/models/base.py @@ -6,7 +6,7 @@ from django.contrib.sitemaps import Sitemap from django.template.defaultfilters import truncatewords_html -import markdown2 as markdown +from utils import markdown2 as markdown from photos.models import PhotoGallery |