lundi 29 février 2016

Ember issue with routes and parameters

I am running into an issue setting up routes. I have a route group of

this.route('users', function () {

for

/users

/users/add

as well this.route('users', {path: '/users/:user_id'}, function () {

for routes like

/users/1/edit

/users/1/goals

/users/1/goals/1

The issue I have is that {{#link-to 'users'}}Users{{/link-to}} results in a link to "/users/undefined", which causes other issues, it needs to be "/users". Is there a way to do routes like this or would I be forced to have "users" and "user" route groups?




Aucun commentaire:

Enregistrer un commentaire