Ticket #889: new-admin_popup_str_fix.patch

File new-admin_popup_str_fix.patch, 840 bytes (added by Tom Tobin <korpios@…>, 19 years ago)

Fix against new-admin r1386 for issue in ticket.

  • contrib/admin/views/main.py

     
    429429                return HttpResponseRedirect(post_url_continue % pk_value)
    430430            if request.POST.has_key("_popup"):
    431431                return HttpResponse('<script type="text/javascript">opener.dismissAddAnotherPopup(window, %s, "%s");</script>' % \
    432                     (pk_value, repr(new_object).replace('"', '\\"')))
     432                    (pk_value, str(new_object).replace('"', '\\"')))
    433433            elif request.POST.has_key("_addanother"):
    434434                request.user.add_message(msg + ' ' + (_("You may add another %s below.") % opts.verbose_name))
    435435                return HttpResponseRedirect(request.path)
Back to Top