Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
Gyuricska Milán
/
cloud
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
3d5c9614
authored
Mar 06, 2014
by
Oláh István Gergely
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
dashboard: fix base remove user template - adding username
parent
a69982ab
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
0 deletions
+12
-0
circle/dashboard/views.py
+12
-0
No files found.
circle/dashboard/views.py
View file @
3d5c9614
...
@@ -1009,6 +1009,14 @@ class GroupRemoveUserView(LoginRequiredMixin, DeleteView):
...
@@ -1009,6 +1009,14 @@ class GroupRemoveUserView(LoginRequiredMixin, DeleteView):
slug_field
=
'pk'
slug_field
=
'pk'
slug_url_kwarg
=
'group_pk'
slug_url_kwarg
=
'group_pk'
def
get_context_data
(
self
,
**
kwargs
):
context
=
super
(
GroupRemoveUserView
,
self
)
.
get_context_data
(
**
kwargs
)
try
:
context
[
'member'
]
=
User
.
objects
.
get
(
pk
=
self
.
user_pk
)
except
User
.
DoesNotExist
:
raise
Http404
()
return
context
def
get_success_url
(
self
):
def
get_success_url
(
self
):
next
=
self
.
request
.
POST
.
get
(
'next'
)
next
=
self
.
request
.
POST
.
get
(
'next'
)
if
next
:
if
next
:
...
@@ -1016,6 +1024,10 @@ class GroupRemoveUserView(LoginRequiredMixin, DeleteView):
...
@@ -1016,6 +1024,10 @@ class GroupRemoveUserView(LoginRequiredMixin, DeleteView):
else
:
else
:
return
reverse_lazy
(
'dashboard.views.group-list'
)
return
reverse_lazy
(
'dashboard.views.group-list'
)
def
get
(
self
,
request
,
user_pk
,
*
args
,
**
kwargs
):
self
.
user_pk
=
user_pk
return
super
(
GroupRemoveUserView
,
self
)
.
get
(
request
,
*
args
,
**
kwargs
)
def
get_template_names
(
self
):
def
get_template_names
(
self
):
if
self
.
request
.
is_ajax
():
if
self
.
request
.
is_ajax
():
return
[
'dashboard/confirm/ajax-remove.html'
]
return
[
'dashboard/confirm/ajax-remove.html'
]
...
...
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