discourse/app/assets/javascripts/admin/controllers/admin-plugins.js.es6

26 lines
536 B
Plaintext
Raw Normal View History

import Controller from "@ember/controller";
import computed from "ember-addons/ember-computed-decorators";
export default Controller.extend({
@computed
adminRoutes: function() {
return this.model
2018-06-15 23:03:24 +08:00
.map(p => {
if (p.get("enabled")) {
return p.admin_route;
}
})
.compact();
},
2018-07-03 11:14:53 +08:00
actions: {
clearFilter() {
this.setProperties({ filter: "", onlyOverridden: false });
},
toggleMenu() {
$(".admin-detail").toggleClass("mobile-closed mobile-open");
}
}
});