Ticket #10448: patch10448against10203.diff

File patch10448against10203.diff, 1.0 KB (added by sebastian.hillig, 16 years ago)
  • django/contrib/admin/options.py

     
    782782            'app_label': opts.app_label,
    783783        }
    784784        context.update(extra_context or {})
    785         return self.render_change_form(request, context, add=True)
     785        return self.render_change_form(request, context, form_url=form_url, add=True)
    786786    add_view = transaction.commit_on_success(add_view)
    787787
    788788    def change_view(self, request, object_id, extra_context=None):
     
    805805            raise Http404(_('%(name)s object with primary key %(key)r does not exist.') % {'name': force_unicode(opts.verbose_name), 'key': escape(object_id)})
    806806
    807807        if request.method == 'POST' and request.POST.has_key("_saveasnew"):
    808             return self.add_view(request, form_url='../../add/')
     808            return self.add_view(request, form_url='../add/')
    809809
    810810        ModelForm = self.get_form(request, obj)
    811811        formsets = []
Back to Top