diff options
Diffstat (limited to 'StoneIsland/platforms/ios/www/js/index.js')
| -rw-r--r-- | StoneIsland/platforms/ios/www/js/index.js | 54 |
1 files changed, 29 insertions, 25 deletions
diff --git a/StoneIsland/platforms/ios/www/js/index.js b/StoneIsland/platforms/ios/www/js/index.js index 2875c90b..5720dcf1 100644 --- a/StoneIsland/platforms/ios/www/js/index.js +++ b/StoneIsland/platforms/ios/www/js/index.js @@ -1,37 +1,41 @@ var app = (function(){ - var app = {} + app.init = function(){ + app.archive = new ArchiveView () + app.hub = new HubView () + app.story = new StoryView () + + app.cart = new CartView () + + app.header = new HeaderView () + app.footer = new FooterView () + app.curtain = new CurtainView () + app.nav = new NavView () + + app.login = new LoginView () + app.intro = new IntroView () + + app.product = new ProductView () + app.collection = new CollectionView () + + app.selector = new Selector () + app.bind() } + app.bind = function(){ + if (window.location.href.match("8000")) { app.ready() } document.addEventListener('deviceready', app.ready, false) } + app.ready = function(){ - cookies.setItem("testing", "testing", 60*60*24*365) - console.log(document.cookie) - $.ajax({ - url: "http://lvh.me:5000/", - xhrFields: { - withCredentials: true - }, - success: function(){ - app.again() - } - }) - document.write("duh") - } - app.again = function(){ - $.ajax({ - url: "http://lvh.me:5000/", - xhrFields: { - withCredentials: true - }, - success: function(){ - } - }) + app.view = null + app.router = new SiteRouter () + app.router.route() } - app.init() - + return app })() + +app.init() |
