Add a way to view staff action logs in admin

This commit is contained in:
Neil Lalonde
2013-08-07 16:04:12 -04:00
parent d2fb6ec53f
commit 5c8c52482a
16 changed files with 231 additions and 24 deletions

View File

@@ -13,7 +13,6 @@ Discourse.AdminLogsBlockedEmailsController = Ember.ArrayController.extend(Discou
var self = this;
this.set('loading', true);
Discourse.BlockedEmail.findAll().then(function(result) {
console.log('findAll done');
self.set('content', result);
self.set('loading', false);
});

View File

@@ -0,0 +1,24 @@
/**
This controller supports the interface for listing staff action logs in the admin section.
@class AdminLogsStaffActionLogsController
@extends Ember.ArrayController
@namespace Discourse
@module Discourse
**/
Discourse.AdminLogsStaffActionLogsController = Ember.ArrayController.extend(Discourse.Presence, {
loading: false,
show: function() {
var self = this;
this.set('loading', true);
Discourse.StaffActionLog.findAll().then(function(result) {
self.set('content', result);
self.set('loading', false);
});
},
toggleFullDetails: function(target) {
target.set('showFullDetails', !target.get('showFullDetails'));
}
});