discourse/app/assets/javascripts/admin/controllers/admin-customize-email-templates.js.es6
Mark VanLandingham 2ae21e9c35
DEV: Import every instance of Ember.computed function (#8267)
* DEV: Import every instance of Ember.computed function

* export default for Ember.computed
2019-10-30 15:28:29 -05:00

19 lines
429 B
JavaScript

import { sort } from "@ember/object/computed";
import Controller from "@ember/controller";
export default Controller.extend({
emailTemplates: null,
sortedTemplates: sort("emailTemplates", "titleSorting"),
init() {
this._super(...arguments);
this.titleSorting = ["title"];
},
actions: {
selectTemplate(template) {
this.transitionToRoute("adminCustomizeEmailTemplates.edit", template);
}
}
});