-
Notifications
You must be signed in to change notification settings - Fork 0
/
app.js
77 lines (71 loc) · 2.23 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
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
var app =angular.module("myApp",['ui.router','ngStorage']);
app.config(function($stateProvider, $urlRouterProvider) {
$stateProvider
.state('categories', {
url:'/categories',
templateUrl : "views/categories.html",
controller: "categoriesCtrl"
})
.state("products", {
url:"/products/:name",
templateUrl : "views/products.html",
controller: "productsCtrl"
})
.state("product-view", {
url:"/product-view/:name",
templateUrl : "views/productsview.html",
controller: "productViewCtrl"
})
.state("cart", {
url:"/cart",
templateUrl : "views/cartview.html",
controller:"cartCtrl"
})
.state("login",{
url:"/login",
templateUrl : "views/login.html",
controller:"loginCtrl"
})
$urlRouterProvider.otherwise("/categories");
});
window.fbAsyncInit = function() {
FB.init({
appId : '1271883099535891',
xfbml : true,
version : 'v2.7'
});
FB.AppEvents.logPageView();
};
(function(d, s, id){
var js, fjs = d.getElementsByTagName(s)[0];
if (d.getElementById(id)) {return;}
js = d.createElement(s); js.id = id;
js.src = "//connect.facebook.net/en_US/sdk.js";
fjs.parentNode.insertBefore(js, fjs);
}(document, 'script', 'facebook-jssdk'));
// var app =angular.module("myApp",['ngRoute']);
//
// app.config(function($routeProvider) {
// $routeProvider
// .when("/", {
// templateUrl : "views/categories.html",
// // controller: "categoriesCtrl"
// })
// .when("/products/:name", {
// templateUrl : "views/products.html",
// controller: "productsCtrl"
// })
// .when("/product-view/:name", {
// templateUrl : "views/productsview.html",
// controller: "productViewCtrl"
// })
// .when("/cart", {
// templateUrl : "views/cartview.html",
// controller:"cartCtrl"
// })
// .when("/login",{
// templateUrl : "views/login.html",
// controller:"loginCtrl"
// })
//
// });