Explorar o código

Preserve query parameters on redirect after clicking "add another"

Jeremy Stretch %!s(int64=8) %!d(string=hai) anos
pai
achega
237a889f54
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      netbox/utilities/views.py

+ 1 - 1
netbox/utilities/views.py

@@ -214,7 +214,7 @@ class ObjectEditView(GetReturnURLMixin, View):
                 UserAction.objects.log_edit(request.user, obj, msg)
 
             if '_addanother' in request.POST:
-                return redirect(request.path)
+                return redirect(request.get_full_path())
 
             return_url = form.cleaned_data.get('return_url')
             if return_url is not None and is_safe_url(url=return_url, host=request.get_host()):