Commit df4cb600 authored by Russell Keith-Magee's avatar Russell Keith-Magee
Browse files

Fixed #14935 -- Corrected a test failure introduced by r14992, which revealed...

Fixed #14935 -- Corrected a test failure introduced by r14992, which revealed an unhandled edge case in LogEntry handling in the admin. Thanks to Ramiro Morales for the report.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@15024 bcc190cf-cafb-0310-a4f2-bffc1f526a37
parent 35504565
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -51,4 +51,6 @@ class LogEntry(models.Model):
        Returns the admin URL to edit the object represented by this log entry.
        This is relative to the Django admin index page.
        """
        if self.content_type and self.object_id:
            return mark_safe(u"%s/%s/%s/" % (self.content_type.app_label, self.content_type.model, quote(self.object_id)))
        return None
 No newline at end of file
+1 −1
Original line number Diff line number Diff line
@@ -60,7 +60,7 @@
            <ul class="actionlist">
            {% for entry in admin_log %}
            <li class="{% if entry.is_addition %}addlink{% endif %}{% if entry.is_change %}changelink{% endif %}{% if entry.is_deletion %}deletelink{% endif %}">
                {% if entry.is_deletion %}
                {% if entry.is_deletion or not entry.get_admin_url %}
                    {{ entry.object_repr }}
                {% else %}
                    <a href="{{ entry.get_admin_url }}">{{ entry.object_repr }}</a>