mirror of
https://github.com/codeninjasllc/discourse.git
synced 2024-11-30 19:08:10 -05:00
FIX: dual modal when selecting 'delete spammer' in flags section
This commit is contained in:
parent
8bda8a2235
commit
521cb6bd0d
2 changed files with 2 additions and 9 deletions
|
@ -22,6 +22,7 @@ Discourse.AdminFlagsRouteType = Discourse.Route.extend({
|
||||||
@method deleteSpammer
|
@method deleteSpammer
|
||||||
**/
|
**/
|
||||||
deleteSpammer: function (user) {
|
deleteSpammer: function (user) {
|
||||||
|
this.send('closeModal');
|
||||||
user.deleteAsSpammer(function() { window.location.reload(); });
|
user.deleteAsSpammer(function() { window.location.reload(); });
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -50,6 +51,3 @@ Discourse.AdminFlagsActiveRoute = Discourse.AdminFlagsRouteType.extend({
|
||||||
Discourse.AdminFlagsOldRoute = Discourse.AdminFlagsRouteType.extend({
|
Discourse.AdminFlagsOldRoute = Discourse.AdminFlagsRouteType.extend({
|
||||||
filter: 'old'
|
filter: 'old'
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -105,7 +105,7 @@ export default ObjectController.extend(ModalFunctionality, {
|
||||||
|
|
||||||
changePostActionType: function(action) {
|
changePostActionType: function(action) {
|
||||||
this.set('selected', action);
|
this.set('selected', action);
|
||||||
}
|
},
|
||||||
},
|
},
|
||||||
|
|
||||||
canDeleteSpammer: function() {
|
canDeleteSpammer: function() {
|
||||||
|
@ -118,11 +118,6 @@ export default ObjectController.extend(ModalFunctionality, {
|
||||||
}
|
}
|
||||||
}.property('selected.name_key', 'userDetails.can_be_deleted', 'userDetails.can_delete_all_posts'),
|
}.property('selected.name_key', 'userDetails.can_be_deleted', 'userDetails.can_delete_all_posts'),
|
||||||
|
|
||||||
deleteSpammer: function() {
|
|
||||||
this.send('closeModal');
|
|
||||||
this.get('userDetails').deleteAsSpammer(function() { window.location.reload(); });
|
|
||||||
},
|
|
||||||
|
|
||||||
usernameChanged: function() {
|
usernameChanged: function() {
|
||||||
this.set('userDetails', null);
|
this.set('userDetails', null);
|
||||||
this.fetchUserDetails();
|
this.fetchUserDetails();
|
||||||
|
|
Loading…
Reference in a new issue