1
0
mirror of https://github.com/Foltik/Shimapan synced 2024-12-10 21:48:03 -05:00
shimapan/app/public/panel/routes.js

32 lines
1.1 KiB
JavaScript
Raw Normal View History

var angular = require('angular');
2017-10-11 20:26:07 -04:00
angular.module('PanelRoutes', ['ui.router']).config(['$stateProvider', '$urlRouterProvider', '$locationProvider', function($stateProvider, $urlRouterProvider, $locationProvider) {
$locationProvider.html5Mode(true);
$urlRouterProvider.otherwise('/panel');
$stateProvider
.state('dashboard', {
2017-10-11 20:26:07 -04:00
url: '/panel',
2017-10-20 16:46:14 -04:00
templateUrl: '/views/panel/dash.html'
}).state('search', {
url: '/panel/search',
2017-10-20 16:46:14 -04:00
templateUrl: '/views/panel/search.html'
}).state('api', {
url: '/panel/api',
2017-10-20 16:46:14 -04:00
templateUrl: '/views/panel/api.html'
}).state('invites', {
url: '/panel/invites',
2017-10-20 16:46:14 -04:00
templateUrl: '/views/panel/invites.html'
}).state('stats', {
url: '/panel/stats',
2017-10-20 16:46:14 -04:00
templateUrl: '/views/panel/stats.html'
}).state('users', {
url: '/panel/users',
2017-10-20 16:46:14 -04:00
templateUrl: '/views/panel/users.html'
}).state('home', {
onEnter: ['$window', function($window) {
$window.location.href = '/home';
}]
2017-10-11 20:26:07 -04:00
});
}]);