admin-wizards-custom.js.es6 389 B

12345678910111213141516171819
  1. import CustomWizard from '../models/custom-wizard';
  2. export default Discourse.Route.extend({
  3. model() {
  4. return CustomWizard.findAll();
  5. },
  6. setupController(controller, model){
  7. controller.set("model", model.toArray());
  8. },
  9. actions: {
  10. willTransition(transition) {
  11. if (transition.intent.name === 'adminWizardsCustom') {
  12. this.refresh();
  13. }
  14. }
  15. }
  16. });