a few minor bug fixes.
authorgfawcett <gfawcett@6d9bc8c9-1ec2-4278-b937-99fde70a366f>
Fri, 16 Jul 2010 15:39:49 +0000 (15:39 +0000)
committergfawcett <gfawcett@6d9bc8c9-1ec2-4278-b937-99fde70a366f>
Fri, 16 Jul 2010 15:39:49 +0000 (15:39 +0000)
git-svn-id: svn://svn.open-ils.org/ILS-Contrib/servres/trunk@925 6d9bc8c9-1ec2-4278-b937-99fde70a366f

conifer/syrup/views/_common.py
conifer/syrup/views/genshi_namespace.py
conifer/templates/item/item_metadata.xhtml

index 04c63d8..612393e 100644 (file)
@@ -20,7 +20,7 @@ import sys
 import warnings
 import pdb
 
-from conifer.integration.hooksystem import gethook, callhook, callhook_required
+from conifer.plumbing.hooksystem    import gethook, callhook, callhook_required
 from conifer.syrup                  import models
 from datetime                       import datetime
 from django.contrib.auth            import authenticate, login, logout
@@ -41,6 +41,7 @@ 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 _
 
 #-----------------------------------------------------------------------------
 # Authorization
@@ -49,7 +50,9 @@ def _access_denied(request, message):
     if request.user.is_anonymous():
         # then take them to login screen....
         dest = (request.META['SCRIPT_NAME'] + \
-                    '/accounts/login/?next=' + request.META['PATH_INFO'])
+                    '/accounts/login/?next=%s%s' % (
+                request.META['SCRIPT_NAME'],
+                request.META['PATH_INFO']))
         return HttpResponseRedirect(dest)
     else:
         return simple_message(_('Access denied.'), message,
index 0e30570..5af6a7d 100644 (file)
@@ -11,8 +11,8 @@ import django.forms
 import itertools
 import urllib
 
-from conifer.integration.hooksystem import gethook, callhook
-from conifer.syrup                  import models
-from django.utils                   import translation
+from conifer.plumbing.hooksystem import gethook, callhook
+from conifer.syrup               import models
+from django.utils                import translation
 
 _ = translation.ugettext
index a90986e..d5b591f 100644 (file)
@@ -35,7 +35,7 @@ is_editor = site.can_edit(request.user)
       <tr><th>Title</th><td>${item.title}</td></tr>
       <tr py:if="item.author"><th>Author</th><td>${item.author}</td></tr>
       <tr py:if="item.publisher"><th>Publisher</th><td>${item.publisher}</td></tr>
-      <tr py:if="item.published"><th>Published</th><td>${item.published and item.published.year}</td></tr>
+      <tr py:if="item.published"><th>Published</th><td>${item.published}</td></tr>
       <tr><th>Type</th><td>${item.get_item_type_display()}</td></tr>
       <tr py:if="item.item_type=='PHYS'"
          py:with="avail, status = item.describe_physical_item_status()">