Skip to content

Instantly share code, notes, and snippets.

@mattatcha
Created May 9, 2014 02:01
Show Gist options
  • Save mattatcha/42b0c2528d1a93e997b8 to your computer and use it in GitHub Desktop.
Save mattatcha/42b0c2528d1a93e997b8 to your computer and use it in GitHub Desktop.
App.config(function ($stateProvider) {
$stateProvider
.state('app.classes', {
url: '/classes',
abstract: true,
template: '<ui-view/>'
})
.state('app.classes.list', {
url: '',
templateUrl: 'modules/classes/partials/list.html'
})
.state('app.classes.detail', {
url: '/:id',
abstract: true,
templateUrl: 'modules/classes/partials/container.html'
})
.state('app.classes.detail.home', {
url: '',
templateUrl: 'modules/classes/partials/home.html'
})
.state('app.classes.detail.people', {
url: '/people',
templateUrl: 'modules/classes/partials/people.html'
})
.state('app.classes.detail.people.add', {
url: "/add",
onEnter: function($stateParams, $state, $modal) {
$modal.open({
templateUrl: 'modules/classes/partials/addPeople.html'
})
}
})
.state('app.classes.detail.settings', {
url: '/settings',
templateUrl: 'modules/classes/partials/settings.html'
});
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment