[open-ils-commits] r926 - servres/trunk/conifer/syrup/views (gfawcett)
svn at svn.open-ils.org
svn at svn.open-ils.org
Fri Jul 16 13:38:24 EDT 2010
Author: gfawcett
Date: 2010-07-16 13:38:20 -0400 (Fri, 16 Jul 2010)
New Revision: 926
Modified:
servres/trunk/conifer/syrup/views/_common.py
servres/trunk/conifer/syrup/views/admin.py
servres/trunk/conifer/syrup/views/feeds.py
servres/trunk/conifer/syrup/views/general.py
servres/trunk/conifer/syrup/views/genshi_namespace.py
servres/trunk/conifer/syrup/views/items.py
servres/trunk/conifer/syrup/views/sites.py
Log:
minor import cleanups
Modified: servres/trunk/conifer/syrup/views/_common.py
===================================================================
--- servres/trunk/conifer/syrup/views/_common.py 2010-07-16 15:39:49 UTC (rev 925)
+++ servres/trunk/conifer/syrup/views/_common.py 2010-07-16 17:38:20 UTC (rev 926)
@@ -35,14 +35,13 @@
HttpResponseForbidden)
from django.shortcuts import get_object_or_404
from django.utils import simplejson
-from django.utils.translation import ugettext as _
+from django.utils import translation
from _generics import * # TODO: should not import-star
from conifer.libsystems.marcxml import (marcxml_to_dictionary,
marcxml_dictionary_to_dc)
-from django.utils.translation import ugettext as _
-
+__builtins__['_'] = translation.ugettext
#-----------------------------------------------------------------------------
# Authorization
Modified: servres/trunk/conifer/syrup/views/admin.py
===================================================================
--- servres/trunk/conifer/syrup/views/admin.py 2010-07-16 15:39:49 UTC (rev 925)
+++ servres/trunk/conifer/syrup/views/admin.py 2010-07-16 17:38:20 UTC (rev 926)
@@ -1,5 +1,4 @@
-from _common import *
-from django.utils.translation import ugettext as _
+from _common import *
from datetime import date
#-----------------------------------------------------------------------------
Modified: servres/trunk/conifer/syrup/views/feeds.py
===================================================================
--- servres/trunk/conifer/syrup/views/feeds.py 2010-07-16 15:39:49 UTC (rev 925)
+++ servres/trunk/conifer/syrup/views/feeds.py 2010-07-16 17:38:20 UTC (rev 926)
@@ -1,5 +1,4 @@
from _common import *
-from django.utils.translation import ugettext as _
#-----------------------------------------------------------------------------
# Site feeds
Modified: servres/trunk/conifer/syrup/views/general.py
===================================================================
--- servres/trunk/conifer/syrup/views/general.py 2010-07-16 15:39:49 UTC (rev 925)
+++ servres/trunk/conifer/syrup/views/general.py 2010-07-16 17:38:20 UTC (rev 926)
@@ -1,10 +1,6 @@
-from _common import *
-from django.utils.translation import ugettext as _
-from search import *
-#from lxml import etree
-#import libxml2
-#import libxslt
import os
+from _common import *
+from search import *
#-----------------------------------------------------------------------------
Modified: servres/trunk/conifer/syrup/views/genshi_namespace.py
===================================================================
--- servres/trunk/conifer/syrup/views/genshi_namespace.py 2010-07-16 15:39:49 UTC (rev 925)
+++ servres/trunk/conifer/syrup/views/genshi_namespace.py 2010-07-16 17:38:20 UTC (rev 926)
@@ -13,6 +13,4 @@
from conifer.plumbing.hooksystem import gethook, callhook
from conifer.syrup import models
-from django.utils import translation
-
-_ = translation.ugettext
+from django.utils.translation import ugettext as _
Modified: servres/trunk/conifer/syrup/views/items.py
===================================================================
--- servres/trunk/conifer/syrup/views/items.py 2010-07-16 15:39:49 UTC (rev 925)
+++ servres/trunk/conifer/syrup/views/items.py 2010-07-16 17:38:20 UTC (rev 926)
@@ -1,7 +1,6 @@
-from _common import *
-from conifer.syrup import integration
-from django.utils.translation import ugettext as _
-from xml.etree import ElementTree as ET
+from _common import *
+from conifer.syrup import integration
+from xml.etree import ElementTree as ET
@members_only
def item_detail(request, site_id, item_id):
Modified: servres/trunk/conifer/syrup/views/sites.py
===================================================================
--- servres/trunk/conifer/syrup/views/sites.py 2010-07-16 15:39:49 UTC (rev 925)
+++ servres/trunk/conifer/syrup/views/sites.py 2010-07-16 17:38:20 UTC (rev 926)
@@ -1,6 +1,5 @@
from _common import *
-from django.utils.translation import ugettext as _
-from search import *
+from search import *
#-----------------------------------------------------------------------------
# Creating a new site
More information about the open-ils-commits
mailing list