Route that includes several of the auth-related mixins already included, made for convenience.

Usage: (in a routes file)

import AuthRoute from '@bennerinformatics/ember-fw-gc/routes/auth';

export default AuthRoute.extend({
    // your code here...
});

This AuthRoute is extended by both the AuthRoute and the RestrictedRoute, both of which are routes you can access within your app. Thus all the mixins incorporated into this route is used by both of those as well. You should hardly ever import this AuthRoute instead of the AuthRoute accessible directly.

Show:

Methods

permit
(
  • roles
  • goTo
)
Ember.Transition | Null
public

Checks a role or list of roles against a user's available roles. If the check fails, the app will transition to the route specified.

Parameters:

  • roles String | Array

    Roles to check

  • goTo String

    Route to transition to if the check fails

Returns:

Ember.Transition | Null