discourse/app/assets/javascripts/admin/routes/admin-customize-themes.js.es6

24 lines
497 B
Plaintext
Raw Normal View History

2018-06-15 11:03:24 -04:00
import showModal from "discourse/lib/show-modal";
export default Ember.Route.extend({
model() {
2018-06-15 11:03:24 -04:00
return this.store.findAll("theme");
},
setupController(controller, model) {
this._super(controller, model);
controller.set("editingTheme", false);
},
actions: {
installModal() {
showModal("admin-install-theme", { admin: true });
},
addTheme(theme) {
this.refresh();
2018-06-15 11:03:24 -04:00
this.transitionTo("adminCustomizeThemes.show", theme.get("id"));
}
}
});