I am implementing ember-engine in my application. I am using ember-simple-auth addon for authentication. It works well with main application routes.
I extend the protected routes with mixin provided by addon.
// app/routes/protected.js
import AuthenticatedRouteMixin from 'ember-simple-auth/mixins/authenticated-route-mixin';
export default Ember.Route.extend(AuthenticatedRouteMixin);
Now I have created a users engine. which has the userlist and some other stuff. I want user to access this page only if he is authenticated. In main app routes I can extend the route with mixin and it will redirect to login route if the user is not authenticated. But same things does not work with users engine routes.
Any idea about how to implement Ember-simple-auth with Ember-engines ?
Reference : -
Ember engines - http://ift.tt/2fPG4Rm
Ember simple auth - http://ift.tt/17HJBBx
Aucun commentaire:
Enregistrer un commentaire