summaryrefslogtreecommitdiff
path: root/StoneIsland/www/js/lib/_router.js
diff options
context:
space:
mode:
Diffstat (limited to 'StoneIsland/www/js/lib/_router.js')
-rw-r--r--StoneIsland/www/js/lib/_router.js20
1 files changed, 19 insertions, 1 deletions
diff --git a/StoneIsland/www/js/lib/_router.js b/StoneIsland/www/js/lib/_router.js
index 0d0c3bd1..6434e9bf 100644
--- a/StoneIsland/www/js/lib/_router.js
+++ b/StoneIsland/www/js/lib/_router.js
@@ -1,6 +1,7 @@
var SiteRouter = Router.extend({
el: 'body',
+ routeByHash: true,
routes: {
'/': 'intro',
@@ -11,32 +12,49 @@ var SiteRouter = Router.extend({
'/faq': 'faq',
'/search': 'search',
+
+ '/cart': 'cart',
},
initialize: function(){
- this.route()
},
go: function(url){
if (app.view && app.view.hide) {
app.view.hide()
}
+ window.location.href = "#/" + url
this.parseRoute(url)
+ console.log(url)
},
intro: function(){
+ app.view = app.intro
+ app.intro.show()
},
store: function(){
+ app.view = app.store
+ app.collection.show()
},
hub: function(){
+ app.view = app.hub
+ app.hub.show()
},
story: function(){
+ app.view = app.story
+ app.story.show()
},
archive: function(){
+ app.view = app.archive
+ app.archive.show()
+ },
+
+
+ cart: function(){
},
})