Need on change search field - load route with params /search/WORD, path of route, example, /search/:q
How is best way?
- In template
{{input value=str}}and in controllerthis.transitionToRoute('search', this.store.find...). It require loading model in controller and duplicate to routemode:function(){ return this.store.find...}. - In controller call route by url
this.transitionToRoute('/search/' + str).
Else?
Aucun commentaire:
Enregistrer un commentaire