2014-01-06 12:34:25 -08:00
|
|
|
'use strict';
|
|
|
|
|
|
|
|
//Setting up route
|
|
|
|
angular.module('mystery').config(['$routeProvider',
|
2014-01-06 12:54:32 -08:00
|
|
|
function($routeProvider) {
|
|
|
|
$routeProvider.
|
2014-01-08 06:05:19 -08:00
|
|
|
when('/block/:blockHash', {
|
|
|
|
templateUrl: 'views/block.html'
|
|
|
|
}).
|
2014-01-06 12:54:32 -08:00
|
|
|
when('/', {
|
|
|
|
templateUrl: 'views/index.html'
|
|
|
|
}).
|
2014-01-08 06:56:36 -08:00
|
|
|
when('/blocks', {
|
|
|
|
templateUrl: 'views/blocks/list.html'
|
|
|
|
}).
|
|
|
|
when('/blocks-date/:blockDate', {
|
|
|
|
templateUrl: 'views/blocks/list_date.html'
|
|
|
|
}).
|
2014-01-06 12:54:32 -08:00
|
|
|
otherwise({
|
|
|
|
redirectTo: '/'
|
|
|
|
});
|
|
|
|
}
|
2014-01-06 12:34:25 -08:00
|
|
|
]);
|
|
|
|
|
|
|
|
//Setting HTML5 Location Mode
|
|
|
|
angular.module('mystery').config(['$locationProvider',
|
2014-01-06 12:54:32 -08:00
|
|
|
function($locationProvider) {
|
|
|
|
$locationProvider.hashPrefix('!');
|
|
|
|
}
|
|
|
|
]);
|