2018-06-15 11:03:24 -04:00
|
|
|
import showModal from "discourse/lib/show-modal";
|
2015-03-10 15:01:15 -04:00
|
|
|
|
2015-02-05 14:34:57 -05:00
|
|
|
export default Discourse.Route.extend({
|
|
|
|
// TODO: make this automatic using an `{{outlet}}`
|
|
|
|
renderTemplate: function() {
|
2018-06-15 11:03:24 -04: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) {
|
2018-06-15 11:03:24 -04:00
|
|
|
showModal("admin-staff-action-log-details", { model, admin: true });
|
|
|
|
this.controllerFor("modal").set("modalClass", "log-details-modal");
|
2015-02-05 14:34:57 -05:00
|
|
|
},
|
|
|
|
|
2015-04-09 18:33:37 -04:00
|
|
|
showCustomDetailsModal(model) {
|
2018-06-15 11:03:24 -04:00
|
|
|
let modal = showModal("admin-theme-change", { model, admin: true });
|
|
|
|
this.controllerFor("modal").set("modalClass", "history-modal");
|
2017-04-12 10:52:52 -04:00
|
|
|
modal.loadDiff();
|
2015-02-05 14:34:57 -05:00
|
|
|
}
|
|
|
|
}
|
|
|
|
});
|