2015-03-10 15:01:15 -04:00
|
|
|
import showModal from 'discourse/lib/show-modal';
|
|
|
|
|
2015-02-05 14:34:57 -05:00
|
|
|
export default Discourse.Route.extend({
|
|
|
|
// TODO: make this automatic using an `{{outlet}}`
|
|
|
|
renderTemplate: function() {
|
2016-11-09 14:47:58 -05:00
|
|
|
this.render('admin/templates/logs/staff-action-logs', {into: 'adminLogs'});
|
2015-02-05 14:34:57 -05:00
|
|
|
},
|
|
|
|
|
|
|
|
actions: {
|
2015-04-09 18:33:37 -04:00
|
|
|
showDetailsModal(model) {
|
2016-11-16 16:38:27 -05:00
|
|
|
showModal('admin-staff-action-log-details', { model, admin: true });
|
2015-02-05 14:34:57 -05:00
|
|
|
this.controllerFor('modal').set('modalClass', 'log-details-modal');
|
|
|
|
},
|
|
|
|
|
2015-04-09 18:33:37 -04:00
|
|
|
showCustomDetailsModal(model) {
|
2017-04-12 10:52:52 -04:00
|
|
|
let modal = showModal('admin-theme-change', { model, admin: true});
|
|
|
|
this.controllerFor('modal').set('modalClass', 'history-modal');
|
|
|
|
modal.loadDiff();
|
2015-02-05 14:34:57 -05:00
|
|
|
}
|
|
|
|
}
|
|
|
|
});
|