Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

Fixed #1699 -- Fixed JavaScript error in admin site with raw_id_admin…

… and database backend that returns integers as long ints

git-svn-id: http://code.djangoproject.com/svn/django/trunk@2844 bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information...
commit b301640a1b96cff9a567204abacff3784c343574 1 parent 503a27d
Adrian Holovaty authored May 05, 2006
2  django/contrib/admin/templatetags/admin_list.py
@@ -167,7 +167,7 @@ def items_for_result(cl, result):
167 167
         if first: # First column is a special case
168 168
             first = False
169 169
             url = cl.url_for_result(result)
170  
-            result_id = getattr(result, pk)
  170
+            result_id = str(getattr(result, pk)) # str() is needed in case of 23L (long ints)
171 171
             yield ('<th%s><a href="%s"%s>%s</a></th>' % \
172 172
                 (row_class, url, (cl.is_popup and ' onclick="opener.dismissRelatedLookupPopup(window, %r); return false;"' % result_id or ''), result_repr))
173 173
         else:

0 notes on commit b301640

Please sign in to comment.
Something went wrong with that request. Please try again.