[FIX] web: keep hash when login redirect

The anchor part of the url should be kept when a login redirect is done.

introduced by 8f3f9ef46b

note: for 8.0 and saas-6
This commit is contained in:
Nicolas Lempereur 2015-08-20 10:51:49 +02:00
parent cfbd086b09
commit 0ea89c10b6
1 changed files with 1 additions and 1 deletions

View File

@ -314,7 +314,7 @@ def login_redirect():
# built the redirect url, keeping all the query parameters of the url
redirect_url = '%s?%s' % (request.httprequest.base_url, werkzeug.urls.url_encode(request.params))
return """<html><head><script>
window.location = '%sredirect=' + encodeURIComponent("%s");
window.location = '%sredirect=' + encodeURIComponent("%s" + location.hash);
</script></head></html>
""" % (url, redirect_url)