Parent: [798bd2] (diff)

Child: [0765ef] (diff)

Download this file

routes.js    41 lines (37 with data), 1.4 kB

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
/*made by Miguel Rodrigues @ KBZ miguel.rodrigues@knowledgebiz.pt*/
//FrontEnd Routes
console.log("Defining feRoutes");
angular.module('feRoutes', ['ngRoute'])
.config(['$routeProvider', '$locationProvider', function($routeProvider, $locationProvider) {
$routeProvider
// home page with the developerid as route parameter
.when('/', {
templateUrl: 'views/registerApp.html',
controller: 'appCtrl'
})
.when('/:developerid', {
templateUrl: 'views/appList.html',
controller: 'listCtrl'
})
.when('/:developerid/:appid', {
templateUrl: 'views/appView.html',
controller: 'viewCtrl'
})
.when('/:developerid/:appid/listrules', {
templateUrl: 'views/appListRules.html',
controller: 'listRules'
})
.when('/:developerid/:appid/create/rule', {
templateUrl: 'views/appRules.html',
controller: 'rulesCtrl'
})
.when('/:developerid/:appid/:rulesid/statistics', {
templateUrl: 'views/notificationStatistics.html',
controller: 'statisticsCtrl'
})
.when('/create/new/app/:developerid', {
templateUrl: 'views/createApp.html',
controller: 'createAppCtrl'
});
$locationProvider.html5Mode(true);
}])