-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathapp.js
33 lines (31 loc) · 1.07 KB
/
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
31
32
33
var app = angular.module(name, ['ui.router']);
app.config(['$urlRouterProvider', '$stateProvider', function ($urlRouterProvider, $stateProvider) {
$urlRouterProvider.otherwise('/');
$stateProvider
.state('home', {
url: '/',
views: {
'body': {
template: '<div template>we did it</div>'
},
'footer': {
template: "<div class='vCentered'>All rights reserved</div>"
}
}
});
}]);
app.directive('template', function () {
return {
restrict: 'EA',
transclude: true,
template: 'template for <ng-transclude></ng-transclude>',
controller: function ($scope, $rootScope, $timeout, $interval) {},
link: function(scope, element, attributes) {
$(element).append("<div id='time'></div>");
$('#time').load("/search");
}
};
});
angular.bootstrap(document, [name]);
event.on("started", function (data) { console.log(data) });
event.trigger("started","now");