discourse/app/assets/javascripts/admin/routes/admin-watched-words.js.es6

16 lines
326 B
JavaScript

import WatchedWord from 'admin/models/watched-word';
export default Discourse.Route.extend({
queryParams: {
filter: { replace: true }
},
model() {
return WatchedWord.findAll();
},
afterModel(watchedWordsList) {
this.controllerFor('adminWatchedWords').set('allWatchedWords', watchedWordsList);
}
});