-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathapp.js
30 lines (30 loc) · 863 Bytes
/
app.js
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
/*
app.js
Description: Instantiates the Angular application and handles routes
*/
(function() {
var app = angular.module('otb', ['ngMaterial', 'ngRoute'])
app.config(['$routeProvider', '$locationProvider',
function($routeProvider, $locationProvider) {
$locationProvider.hashPrefix("")
$routeProvider
.when('/', {
templateUrl: 'components/landing/landing-view.html',
controller: 'LandingController'
})
.when('/about', {
templateUrl: 'components/about/about-view.html'
})
.when('/purchase', {
templateUrl: 'components/purchase/purchase-view.html',
controller: 'PurchaseController'
})
.when('/sell', {
templateUrl: 'components/sell/sell-view.html',
controller: 'SellController'
})
.otherwise({
redirectTo:'/'
})
}])
})();