Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
Fukász Rómeó Ervin
/
cloud
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
A prog2-höz tartozó friss repo anyagok itt elérhetőek:
https://git.iit.bme.hu/
Commit
1e859cdd
authored
Mar 07, 2014
by
Oláh István Gergely
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
dashboard: fix returning in removing user from group
parent
3dda2ca0
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
11 deletions
+3
-11
circle/dashboard/static/dashboard/group-details.js
+1
-9
circle/dashboard/views.py
+2
-2
No files found.
circle/dashboard/static/dashboard/group-details.js
View file @
1e859cdd
...
...
@@ -48,15 +48,7 @@ function removeMember(data) {
url
:
data
[
'url'
],
headers
:
{
"X-CSRFToken"
:
getCookie
(
'csrftoken'
)},
success
:
function
(
re
,
textStatus
,
xhr
)
{
if
(
!
data
[
'redirect'
])
{
selected
=
[];
addMessage
(
re
[
'message'
],
'success'
);
$
(
'a[data-'
+
data
[
'type'
]
+
'-pk="'
+
data
[
'pk'
]
+
'"]'
).
closest
(
'tr'
).
fadeOut
(
function
()
{
$
(
this
).
remove
();
});
}
else
{
window
.
location
.
replace
(
'/dashboard'
);
}
$
(
'#group-detail-pane'
).
load
(
location
.
href
+
" #group-detail-panel"
);
},
error
:
function
(
xhr
,
textStatus
,
error
)
{
addMessage
(
'Uh oh :('
,
'danger'
)
...
...
circle/dashboard/views.py
View file @
1e859cdd
...
...
@@ -1022,7 +1022,8 @@ class GroupRemoveUserView(LoginRequiredMixin, DeleteView):
if
next
:
return
next
else
:
return
reverse_lazy
(
'dashboard.views.group-list'
)
return
reverse_lazy
(
"dashboard.views.group-detail"
,
kwargs
=
{
'pk'
:
self
.
get_object
()
.
pk
})
def
get
(
self
,
request
,
member_pk
,
*
args
,
**
kwargs
):
self
.
member_pk
=
member_pk
...
...
@@ -1045,7 +1046,6 @@ class GroupRemoveUserView(LoginRequiredMixin, DeleteView):
self
.
remove_member
(
kwargs
[
"member_pk"
])
success_url
=
self
.
get_success_url
()
success_message
=
self
.
get_success_message
()
if
request
.
is_ajax
():
return
HttpResponse
(
json
.
dumps
({
'message'
:
success_message
}),
...
...
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