Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
UCC
uccportal
Commits
906b7ca8
Commit
906b7ca8
authored
Feb 26, 2019
by
frekk
Browse files
don't redirect to admin site from renewal form
parent
d6e451ef
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/memberdb/register.py
View file @
906b7ca8
...
...
@@ -181,7 +181,7 @@ class RenewView(LoginRequiredMixin, RegisterView):
def
form_valid
(
self
,
form
):
m
,
ms
=
form
.
save
()
messages
.
success
(
self
.
request
,
'Your membership renewal has been submitted.'
)
if
self
.
request
.
user
.
is_staff
:
return
HttpResponseRedirect
(
reverse
(
"admin:membership-approve"
,
args
=
[
ms
.
pk
]))
else
:
return
HttpResponseRedirect
(
reverse
(
"memberdb:home"
))
# always redirect to member home on renewal - you can't renew for someone else, and it
# is confusing if you get redirected to the admin site
return
HttpResponseRedirect
(
reverse
(
"memberdb:home"
))
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment