summaryrefslogtreecommitdiff
path: root/StoneIsland/platforms/ios
diff options
context:
space:
mode:
Diffstat (limited to 'StoneIsland/platforms/ios')
-rwxr-xr-xStoneIsland/platforms/ios/Stone Island.xcodeproj/project.pbxproj53
-rwxr-xr-xStoneIsland/platforms/ios/Stone Island/config.xml3
-rwxr-xr-xStoneIsland/platforms/ios/frameworks.json17
-rwxr-xr-xStoneIsland/platforms/ios/ios.json18
-rwxr-xr-xStoneIsland/platforms/ios/platform_www/cordova_plugins.js11
-rwxr-xr-xStoneIsland/platforms/ios/www/cordova_plugins.js11
-rwxr-xr-xStoneIsland/platforms/ios/www/css/nav.css1
-rwxr-xr-xStoneIsland/platforms/ios/www/js/lib/account/PaymentView.js2
-rwxr-xr-xStoneIsland/platforms/ios/www/js/lib/account/ProfileView.js2
-rwxr-xr-xStoneIsland/platforms/ios/www/js/lib/account/SettingsView.js2
-rwxr-xr-xStoneIsland/platforms/ios/www/js/lib/account/ShippingView.js2
-rwxr-xr-xStoneIsland/platforms/ios/www/js/lib/auth/LoginView.js2
-rwxr-xr-xStoneIsland/platforms/ios/www/js/lib/auth/SignupView.js2
-rwxr-xr-xStoneIsland/platforms/ios/www/js/lib/cart/CartConfirm.js2
-rwxr-xr-xStoneIsland/platforms/ios/www/js/lib/cart/CartPayment.js2
-rwxr-xr-xStoneIsland/platforms/ios/www/js/lib/cart/CartShipping.js2
-rwxr-xr-xStoneIsland/platforms/ios/www/js/lib/cart/CartSummary.js2
-rwxr-xr-xStoneIsland/platforms/ios/www/js/lib/nav/SearchView.js2
-rwxr-xr-xStoneIsland/platforms/ios/www/js/lib/products/ProductView.js72
-rwxr-xr-xStoneIsland/platforms/ios/www/js/lib/products/Selector.js18
-rwxr-xr-xStoneIsland/platforms/ios/www/js/sdk/_sdk.js2
21 files changed, 175 insertions, 53 deletions
diff --git a/StoneIsland/platforms/ios/Stone Island.xcodeproj/project.pbxproj b/StoneIsland/platforms/ios/Stone Island.xcodeproj/project.pbxproj
index 18ba30a6..d6872ec7 100755
--- a/StoneIsland/platforms/ios/Stone Island.xcodeproj/project.pbxproj
+++ b/StoneIsland/platforms/ios/Stone Island.xcodeproj/project.pbxproj
@@ -5,7 +5,6 @@
};
objectVersion = 46;
objects = {
-
/* Begin PBXBuildFile section */
04679954946B416BAF5109F4 /* AppDelegate+notification.m in Sources */ = {isa = PBXBuildFile; fileRef = E281A1AF5CAC496486193F7D /* AppDelegate+notification.m */; };
0D43DE7D3F4F4D2CA1143CCD /* CDVLogger.m in Sources */ = {isa = PBXBuildFile; fileRef = 02EC23045EE24BFE9394BE84 /* CDVLogger.m */; };
@@ -60,6 +59,16 @@
E507737F3A0941E68A569F9B /* CDVViewController+SplashScreen.m in Sources */ = {isa = PBXBuildFile; fileRef = 4F1FF1ED80D34C91A03C18FD /* CDVViewController+SplashScreen.m */; };
E9AB3A7C5BC846C8877B780D /* CDVInAppBrowser.m in Sources */ = {isa = PBXBuildFile; fileRef = 9DA5A6FCAA884998901EF477 /* CDVInAppBrowser.m */; };
F7CC7E6030524635AC59C0A0 /* MessageUI.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 900B1AD106FC41E3BFA9FE3C /* MessageUI.framework */; settings = {ATTRIBUTES = (Weak, ); }; };
+ CE2E2F6D58504A0EA2470AEE /* CDVParsePlugin.m in Sources */ = {isa = PBXBuildFile; fileRef = 3048B836F3BD467E83BFF217 /* CDVParsePlugin.m */; };
+ 3102D8D9D718447EA83756B0 /* Accounts.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = DBAC083B6EEF4FB38ED1C4B2 /* Accounts.framework */; };
+ F15FEE33CBCA427DA2D787F4 /* CFNetwork.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 581F34F5A1784D4D9A99F383 /* CFNetwork.framework */; };
+ A7F71F118E604F32AE765DFD /* QuartzCore.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 38EE2AA2E4DD46CEA0DA5F7C /* QuartzCore.framework */; };
+ 68795A6B86504E52812A115C /* Security.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = E164C253C9004A0898A7606E /* Security.framework */; };
+ 93F9C9374ABA4745AF40DA08 /* StoreKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 983FEA48E6A049E8BAF9C572 /* StoreKit.framework */; };
+ 12F814F101B54B69BBBCC136 /* libz.dylib in Frameworks */ = {isa = PBXBuildFile; fileRef = 2A4EF415F441417C98D8794B /* libz.dylib */; };
+ 5F8DBCF934714D4D8F58F78C /* libsqlite3.dylib in Frameworks */ = {isa = PBXBuildFile; fileRef = 7084D4977636441A9FCB146A /* libsqlite3.dylib */; };
+ 571B90B51E784D48BDAE8EB8 /* Bolts.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 1045410447CE4A2EA0F38BDD /* Bolts.framework */; };
+ 6E6F1C559C9840249E48D92E /* Parse.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = EDCE0392D0524C77B377854D /* Parse.framework */; };
/* End PBXBuildFile section */
/* Begin PBXContainerItemProxy section */
@@ -157,6 +166,17 @@
EB87FDF41871DAF40020F90C /* config.xml */ = {isa = PBXFileReference; lastKnownFileType = text.xml; name = config.xml; path = ../../config.xml; sourceTree = "<group>"; };
F0AAFF41056245EFBF8D4D8F /* CDVLocation.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = CDVLocation.m; path = "cordova-plugin-geolocation/CDVLocation.m"; sourceTree = "<group>"; };
F840E1F0165FE0F500CFE078 /* config.xml */ = {isa = PBXFileReference; lastKnownFileType = text.xml; name = config.xml; path = "Stone Island/config.xml"; sourceTree = "<group>"; };
+ 3048B836F3BD467E83BFF217 /* CDVParsePlugin.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; name = "CDVParsePlugin.m"; path = "com.parse.cordova.core.pushplugin/CDVParsePlugin.m"; sourceTree = "<group>"; fileEncoding = 4; };
+ 48C0A6981FEE47D091E9781C /* CDVParsePlugin.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; name = "CDVParsePlugin.h"; path = "com.parse.cordova.core.pushplugin/CDVParsePlugin.h"; sourceTree = "<group>"; fileEncoding = 4; };
+ DBAC083B6EEF4FB38ED1C4B2 /* Accounts.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = "Accounts.framework"; path = "System/Library/Frameworks/Accounts.framework"; sourceTree = SDKROOT; fileEncoding = 4; };
+ 581F34F5A1784D4D9A99F383 /* CFNetwork.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = "CFNetwork.framework"; path = "System/Library/Frameworks/CFNetwork.framework"; sourceTree = SDKROOT; fileEncoding = 4; };
+ 38EE2AA2E4DD46CEA0DA5F7C /* QuartzCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = "QuartzCore.framework"; path = "System/Library/Frameworks/QuartzCore.framework"; sourceTree = SDKROOT; fileEncoding = 4; };
+ E164C253C9004A0898A7606E /* Security.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = "Security.framework"; path = "System/Library/Frameworks/Security.framework"; sourceTree = SDKROOT; fileEncoding = 4; };
+ 983FEA48E6A049E8BAF9C572 /* StoreKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = "StoreKit.framework"; path = "System/Library/Frameworks/StoreKit.framework"; sourceTree = SDKROOT; fileEncoding = 4; };
+ 2A4EF415F441417C98D8794B /* libz.dylib */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.dylib"; name = "libz.dylib"; path = "usr/lib/libz.dylib"; sourceTree = SDKROOT; fileEncoding = 4; };
+ 7084D4977636441A9FCB146A /* libsqlite3.dylib */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.dylib"; name = "libsqlite3.dylib"; path = "usr/lib/libsqlite3.dylib"; sourceTree = SDKROOT; fileEncoding = 4; };
+ 1045410447CE4A2EA0F38BDD /* Bolts.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = "Bolts.framework"; path = "Stone Island/Plugins/com.parse.cordova.core.pushplugin/Bolts.framework"; sourceTree = "<group>"; };
+ EDCE0392D0524C77B377854D /* Parse.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = "Parse.framework"; path = "Stone Island/Plugins/com.parse.cordova.core.pushplugin/Parse.framework"; sourceTree = "<group>"; };
/* End PBXFileReference section */
/* Begin PBXFrameworksBuildPhase section */
@@ -173,6 +193,15 @@
32C7881E372548B8B10FCD81 /* SystemConfiguration.framework in Frameworks */,
C520CB1888FA4F4E963A4605 /* Social.framework in Frameworks */,
F7CC7E6030524635AC59C0A0 /* MessageUI.framework in Frameworks */,
+ 3102D8D9D718447EA83756B0 /* Accounts.framework in Frameworks */,
+ F15FEE33CBCA427DA2D787F4 /* CFNetwork.framework in Frameworks */,
+ A7F71F118E604F32AE765DFD /* QuartzCore.framework in Frameworks */,
+ 68795A6B86504E52812A115C /* Security.framework in Frameworks */,
+ 93F9C9374ABA4745AF40DA08 /* StoreKit.framework in Frameworks */,
+ 12F814F101B54B69BBBCC136 /* libz.dylib in Frameworks */,
+ 5F8DBCF934714D4D8F58F78C /* libsqlite3.dylib in Frameworks */,
+ 571B90B51E784D48BDAE8EB8 /* Bolts.framework in Frameworks */,
+ 6E6F1C559C9840249E48D92E /* Parse.framework in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
};
@@ -251,6 +280,15 @@
C5E8712951F2426B9EC42E16 /* SystemConfiguration.framework */,
34ADAA286CAF455C830BBC5A /* Social.framework */,
900B1AD106FC41E3BFA9FE3C /* MessageUI.framework */,
+ DBAC083B6EEF4FB38ED1C4B2 /* Accounts.framework */,
+ 581F34F5A1784D4D9A99F383 /* CFNetwork.framework */,
+ 38EE2AA2E4DD46CEA0DA5F7C /* QuartzCore.framework */,
+ E164C253C9004A0898A7606E /* Security.framework */,
+ 983FEA48E6A049E8BAF9C572 /* StoreKit.framework */,
+ 2A4EF415F441417C98D8794B /* libz.dylib */,
+ 7084D4977636441A9FCB146A /* libsqlite3.dylib */,
+ 1045410447CE4A2EA0F38BDD /* Bolts.framework */,
+ EDCE0392D0524C77B377854D /* Parse.framework */,
);
name = Frameworks;
sourceTree = "<group>";
@@ -294,6 +332,8 @@
E0289321840940989600F684 /* PushPlugin.h */,
9DA5A6FCAA884998901EF477 /* CDVInAppBrowser.m */,
B3F3C58C9BDE42978CEB4933 /* CDVInAppBrowser.h */,
+ 3048B836F3BD467E83BFF217 /* CDVParsePlugin.m */,
+ 48C0A6981FEE47D091E9781C /* CDVParsePlugin.h */,
);
name = Plugins;
path = "Stone Island/Plugins";
@@ -503,6 +543,7 @@
04679954946B416BAF5109F4 /* AppDelegate+notification.m in Sources */,
A51DA261CB3F4B89BC98FFDE /* PushPlugin.m in Sources */,
E9AB3A7C5BC846C8877B780D /* CDVInAppBrowser.m in Sources */,
+ CE2E2F6D58504A0EA2470AEE /* CDVParsePlugin.m in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
@@ -548,6 +589,11 @@
PRODUCT_NAME = "Stone Island";
PROVISIONING_PROFILE = "";
TARGETED_DEVICE_FAMILY = 1;
+ FRAMEWORK_SEARCH_PATHS = (
+ "$(inherited)",
+ "\"Stone Island/Plugins/com.parse.cordova.core.pushplugin\"",
+ "\"Stone Island/Plugins/com.parse.cordova.core.pushplugin\"",
+ );
};
name = Debug;
};
@@ -580,6 +626,11 @@
PRODUCT_NAME = "Stone Island";
PROVISIONING_PROFILE = "";
TARGETED_DEVICE_FAMILY = 1;
+ FRAMEWORK_SEARCH_PATHS = (
+ "$(inherited)",
+ "\"Stone Island/Plugins/com.parse.cordova.core.pushplugin\"",
+ "\"Stone Island/Plugins/com.parse.cordova.core.pushplugin\"",
+ );
};
name = Release;
};
diff --git a/StoneIsland/platforms/ios/Stone Island/config.xml b/StoneIsland/platforms/ios/Stone Island/config.xml
index 1114ca1f..e2b86e33 100755
--- a/StoneIsland/platforms/ios/Stone Island/config.xml
+++ b/StoneIsland/platforms/ios/Stone Island/config.xml
@@ -46,6 +46,9 @@
<feature name="InAppBrowser">
<param name="ios-package" value="CDVInAppBrowser" />
</feature>
+ <feature name="ParsePlugin">
+ <param name="ios-package" value="CDVParsePlugin" />
+ </feature>
<allow-intent href="itms:*" />
<allow-intent href="itms-apps:*" />
<preference name="KeyboardDisplayRequiresUserAction" value="false" />
diff --git a/StoneIsland/platforms/ios/frameworks.json b/StoneIsland/platforms/ios/frameworks.json
index 1b8fc309..615b5f0b 100755
--- a/StoneIsland/platforms/ios/frameworks.json
+++ b/StoneIsland/platforms/ios/frameworks.json
@@ -1,7 +1,14 @@
{
- "AudioToolbox.framework": 1,
- "CoreLocation.framework": 1,
- "SystemConfiguration.framework": 1,
- "Social.framework": 1,
- "MessageUI.framework": 1
+ "AudioToolbox.framework": 2,
+ "CoreLocation.framework": 2,
+ "SystemConfiguration.framework": 2,
+ "Social.framework": 2,
+ "MessageUI.framework": 1,
+ "Accounts.framework": 1,
+ "CFNetwork.framework": 1,
+ "QuartzCore.framework": 1,
+ "Security.framework": 1,
+ "StoreKit.framework": 1,
+ "libz.dylib": 1,
+ "libsqlite3.dylib": 1
} \ No newline at end of file
diff --git a/StoneIsland/platforms/ios/ios.json b/StoneIsland/platforms/ios/ios.json
index 774d6f81..08b0488c 100755
--- a/StoneIsland/platforms/ios/ios.json
+++ b/StoneIsland/platforms/ios/ios.json
@@ -47,6 +47,10 @@
{
"xml": "<feature name=\"InAppBrowser\"><param name=\"ios-package\" value=\"CDVInAppBrowser\" /></feature>",
"count": 1
+ },
+ {
+ "xml": "<feature name=\"ParsePlugin\"><param name=\"ios-package\" value=\"CDVParsePlugin\" /></feature>",
+ "count": 1
}
]
}
@@ -112,6 +116,9 @@
},
"cordova-plugin-inappbrowser": {
"PACKAGE_NAME": "us.okfoc.stoneisland"
+ },
+ "com.parse.cordova.core.pushplugin": {
+ "PACKAGE_NAME": "us.okfoc.stoneisland"
}
},
"dependent_plugins": {},
@@ -245,6 +252,14 @@
"cordova.InAppBrowser.open",
"window.open"
]
+ },
+ {
+ "file": "plugins/com.parse.cordova.core.pushplugin/www/cdv-plugin-parse.js",
+ "id": "com.parse.cordova.core.pushplugin.ParsePlugin",
+ "pluginId": "com.parse.cordova.core.pushplugin",
+ "clobbers": [
+ "window.parsePlugin"
+ ]
}
],
"plugin_metadata": {
@@ -259,6 +274,7 @@
"cordova-plugin-whitelist": "1.0.0",
"cordova-plugin-x-socialsharing": "5.0.7",
"phonegap-plugin-push": "1.4.4",
- "cordova-plugin-inappbrowser": "1.1.0"
+ "cordova-plugin-inappbrowser": "1.1.0",
+ "com.parse.cordova.core.pushplugin": "0.1.0"
}
} \ No newline at end of file
diff --git a/StoneIsland/platforms/ios/platform_www/cordova_plugins.js b/StoneIsland/platforms/ios/platform_www/cordova_plugins.js
index fabd1474..ba2c072d 100755
--- a/StoneIsland/platforms/ios/platform_www/cordova_plugins.js
+++ b/StoneIsland/platforms/ios/platform_www/cordova_plugins.js
@@ -129,6 +129,14 @@ module.exports = [
"cordova.InAppBrowser.open",
"window.open"
]
+ },
+ {
+ "file": "plugins/com.parse.cordova.core.pushplugin/www/cdv-plugin-parse.js",
+ "id": "com.parse.cordova.core.pushplugin.ParsePlugin",
+ "pluginId": "com.parse.cordova.core.pushplugin",
+ "clobbers": [
+ "window.parsePlugin"
+ ]
}
];
module.exports.metadata =
@@ -145,7 +153,8 @@ module.exports.metadata =
"cordova-plugin-whitelist": "1.0.0",
"cordova-plugin-x-socialsharing": "5.0.7",
"phonegap-plugin-push": "1.4.4",
- "cordova-plugin-inappbrowser": "1.1.0"
+ "cordova-plugin-inappbrowser": "1.1.0",
+ "com.parse.cordova.core.pushplugin": "0.1.0"
}
// BOTTOM OF METADATA
}); \ No newline at end of file
diff --git a/StoneIsland/platforms/ios/www/cordova_plugins.js b/StoneIsland/platforms/ios/www/cordova_plugins.js
index fabd1474..ba2c072d 100755
--- a/StoneIsland/platforms/ios/www/cordova_plugins.js
+++ b/StoneIsland/platforms/ios/www/cordova_plugins.js
@@ -129,6 +129,14 @@ module.exports = [
"cordova.InAppBrowser.open",
"window.open"
]
+ },
+ {
+ "file": "plugins/com.parse.cordova.core.pushplugin/www/cdv-plugin-parse.js",
+ "id": "com.parse.cordova.core.pushplugin.ParsePlugin",
+ "pluginId": "com.parse.cordova.core.pushplugin",
+ "clobbers": [
+ "window.parsePlugin"
+ ]
}
];
module.exports.metadata =
@@ -145,7 +153,8 @@ module.exports.metadata =
"cordova-plugin-whitelist": "1.0.0",
"cordova-plugin-x-socialsharing": "5.0.7",
"phonegap-plugin-push": "1.4.4",
- "cordova-plugin-inappbrowser": "1.1.0"
+ "cordova-plugin-inappbrowser": "1.1.0",
+ "com.parse.cordova.core.pushplugin": "0.1.0"
}
// BOTTOM OF METADATA
}); \ No newline at end of file
diff --git a/StoneIsland/platforms/ios/www/css/nav.css b/StoneIsland/platforms/ios/www/css/nav.css
index 923dd85f..f76fb744 100755
--- a/StoneIsland/platforms/ios/www/css/nav.css
+++ b/StoneIsland/platforms/ios/www/css/nav.css
@@ -303,6 +303,7 @@ padding-bottom:0px;
#selector {
display: none;
position: absolute;
+ bottom: 0; left: 0;
background: #fff;
z-index: 2;
width:100%;
diff --git a/StoneIsland/platforms/ios/www/js/lib/account/PaymentView.js b/StoneIsland/platforms/ios/www/js/lib/account/PaymentView.js
index 03dc8cbf..8b49ed1d 100755
--- a/StoneIsland/platforms/ios/www/js/lib/account/PaymentView.js
+++ b/StoneIsland/platforms/ios/www/js/lib/account/PaymentView.js
@@ -34,7 +34,7 @@ var PaymentView = FormView.extend({
show: function(){
if (! auth.logged_in()) { return app.router.go("intro") }
- app.footer.show("SAVE", "CANCEL")
+ app.footer.show("SAVE")
document.body.className = "payment"
this.deferScrollToTop()
// this.preload()
diff --git a/StoneIsland/platforms/ios/www/js/lib/account/ProfileView.js b/StoneIsland/platforms/ios/www/js/lib/account/ProfileView.js
index ed2f3536..f370c055 100755
--- a/StoneIsland/platforms/ios/www/js/lib/account/ProfileView.js
+++ b/StoneIsland/platforms/ios/www/js/lib/account/ProfileView.js
@@ -15,7 +15,7 @@ var ProfileView = FormView.extend({
show: function(){
if (! auth.logged_in()) { return app.router.go("intro") }
- app.footer.show("SAVE", "CANCEL")
+ app.footer.show("SAVE")
document.body.className = "profile"
this.preload(auth.user)
this.deferScrollToTop()
diff --git a/StoneIsland/platforms/ios/www/js/lib/account/SettingsView.js b/StoneIsland/platforms/ios/www/js/lib/account/SettingsView.js
index 7f96bb88..0de80048 100755
--- a/StoneIsland/platforms/ios/www/js/lib/account/SettingsView.js
+++ b/StoneIsland/platforms/ios/www/js/lib/account/SettingsView.js
@@ -13,7 +13,7 @@ var SettingsView = FormView.extend({
show: function(){
if (! auth.logged_in()) { return app.router.go("intro") }
- app.footer.show("SAVE", "CANCEL")
+ app.footer.show("SAVE")
document.body.className = "settings"
this.deferScrollToTop()
},
diff --git a/StoneIsland/platforms/ios/www/js/lib/account/ShippingView.js b/StoneIsland/platforms/ios/www/js/lib/account/ShippingView.js
index 39baf2aa..0bf88025 100755
--- a/StoneIsland/platforms/ios/www/js/lib/account/ShippingView.js
+++ b/StoneIsland/platforms/ios/www/js/lib/account/ShippingView.js
@@ -33,7 +33,7 @@ var ShippingView = FormView.extend({
show: function(){
if (! auth.logged_in()) { return app.router.go("intro") }
// this.preload( this.data || this.test_data )
- app.footer.show("SAVE", "CANCEL")
+ app.footer.show("SAVE")
document.body.className = "shipping"
this.deferScrollToTop()
},
diff --git a/StoneIsland/platforms/ios/www/js/lib/auth/LoginView.js b/StoneIsland/platforms/ios/www/js/lib/auth/LoginView.js
index 1f7438cc..8a002632 100755
--- a/StoneIsland/platforms/ios/www/js/lib/auth/LoginView.js
+++ b/StoneIsland/platforms/ios/www/js/lib/auth/LoginView.js
@@ -21,7 +21,7 @@ var LoginView = FormView.extend({
return
}
var msg = "* Your personal and payment<br>information will always remain private"
- app.footer.show("SUBMIT", "CANCEL")
+ app.footer.show("SUBMIT")
this.$form.get(0).reset()
this.$msg.html(msg)
document.body.className = "login"
diff --git a/StoneIsland/platforms/ios/www/js/lib/auth/SignupView.js b/StoneIsland/platforms/ios/www/js/lib/auth/SignupView.js
index afbb8877..ff5fa6bb 100755
--- a/StoneIsland/platforms/ios/www/js/lib/auth/SignupView.js
+++ b/StoneIsland/platforms/ios/www/js/lib/auth/SignupView.js
@@ -36,7 +36,7 @@ var SignupView = FormView.extend({
return
}
var msg = "* Your personal and payment<br>information will always remain private"
- app.footer.show("SUBMIT", "CANCEL")
+ app.footer.show("SUBMIT")
this.$form.get(0).reset()
this.$msg.html(msg)
document.body.className = "signup"
diff --git a/StoneIsland/platforms/ios/www/js/lib/cart/CartConfirm.js b/StoneIsland/platforms/ios/www/js/lib/cart/CartConfirm.js
index f6c7f1f5..b7eb8828 100755
--- a/StoneIsland/platforms/ios/www/js/lib/cart/CartConfirm.js
+++ b/StoneIsland/platforms/ios/www/js/lib/cart/CartConfirm.js
@@ -28,7 +28,7 @@ var CartConfirm = FormView.extend({
show: function(){
document.body.className = "cart"
app.cart.el.className = "confirm"
- app.footer.show("PLACE ORDER", "CANCEL")
+ app.footer.show("PLACE ORDER")
window.location.hash = "#/cart/confirm"
this.deferScrollToTop()
diff --git a/StoneIsland/platforms/ios/www/js/lib/cart/CartPayment.js b/StoneIsland/platforms/ios/www/js/lib/cart/CartPayment.js
index f3c54d55..ab454246 100755
--- a/StoneIsland/platforms/ios/www/js/lib/cart/CartPayment.js
+++ b/StoneIsland/platforms/ios/www/js/lib/cart/CartPayment.js
@@ -41,7 +41,7 @@ var CartPayment = FormView.extend({
show: function(){
document.body.className = "cart"
app.cart.el.className = "payment"
- app.footer.show("CONFIRM &gt;", "CANCEL")
+ app.footer.show("CONFIRM &gt;")
window.location.hash = "#/cart/payment"
this.populate()
diff --git a/StoneIsland/platforms/ios/www/js/lib/cart/CartShipping.js b/StoneIsland/platforms/ios/www/js/lib/cart/CartShipping.js
index f17d42d2..1f60307e 100755
--- a/StoneIsland/platforms/ios/www/js/lib/cart/CartShipping.js
+++ b/StoneIsland/platforms/ios/www/js/lib/cart/CartShipping.js
@@ -28,7 +28,7 @@ var CartShipping = FormView.extend({
show: function(){
document.body.className = "cart"
app.cart.el.className = "shipping"
- app.footer.show("PAYMENT &gt;", "CANCEL")
+ app.footer.show("PAYMENT &gt;")
window.location.hash = "#/cart/shipping"
this.populate()
this.deferScrollToTop()
diff --git a/StoneIsland/platforms/ios/www/js/lib/cart/CartSummary.js b/StoneIsland/platforms/ios/www/js/lib/cart/CartSummary.js
index 21fc27dc..01887d95 100755
--- a/StoneIsland/platforms/ios/www/js/lib/cart/CartSummary.js
+++ b/StoneIsland/platforms/ios/www/js/lib/cart/CartSummary.js
@@ -38,7 +38,7 @@ var CartSummary = ScrollableView.extend({
load: function(){
this.el.className = "loading"
- app.footer.show("SHIPPING &gt;", "CANCEL")
+ app.footer.show("SHIPPING &gt;")
app.curtain.show("loading")
sdk.cart.get_status({
success: this.populate.bind(this),
diff --git a/StoneIsland/platforms/ios/www/js/lib/nav/SearchView.js b/StoneIsland/platforms/ios/www/js/lib/nav/SearchView.js
index f21634a5..b477d72f 100755
--- a/StoneIsland/platforms/ios/www/js/lib/nav/SearchView.js
+++ b/StoneIsland/platforms/ios/www/js/lib/nav/SearchView.js
@@ -6,7 +6,7 @@ var SearchView = View.extend({
},
show: function(){
- app.footer.show("SEARCH", "CANCEL")
+ app.footer.show("SEARCH")
document.body.className = "search"
},
diff --git a/StoneIsland/platforms/ios/www/js/lib/products/ProductView.js b/StoneIsland/platforms/ios/www/js/lib/products/ProductView.js
index 6893f88c..285e551d 100755
--- a/StoneIsland/platforms/ios/www/js/lib/products/ProductView.js
+++ b/StoneIsland/platforms/ios/www/js/lib/products/ProductView.js
@@ -29,12 +29,21 @@ var ProductView = ScrollableView.extend({
},
show: function(){
- app.footer.show("ADD TO CART", "BUY NOW")
+ this.showFooter()
document.body.className = "product"
},
hide: function(){
},
+ showFooter: function(){
+ if (this.not_available) {
+ app.footer.show("SOLD OUT")
+ }
+ else {
+ app.footer.show("ADD TO CART", "BUY NOW")
+ }
+ },
+
item: null,
details: null,
size: null,
@@ -87,7 +96,6 @@ var ProductView = ScrollableView.extend({
}
window.location.href = "#/store/" + code
- console.log(data)
if (data) {
app.collection.items[code] = data
}
@@ -113,38 +121,46 @@ var ProductView = ScrollableView.extend({
var body = descriptions['EditorialDescription'].replace(/<br>/g, "<br><br>")
var default_color_id = this.populate_selectors(data, details)
-
- var color = this.colors[default_color_id]
- var color_label = color.label
- var sizes = this.find_sizes_for_color(default_color_id)
- var size = sizes[0]
- var size_label = this.sizes[size].label
- this.is_onesize = !! this.sizes[1]
+ if (this.not_available) {
+ this.$color.html("NOT AVAILABLE")
+ this.$size.hide()
+ }
+ else {
+ var color = this.colors[default_color_id]
+ var color_label = color.label
+ var sizes = this.find_sizes_for_color(default_color_id)
+ var size = sizes[0]
+ var size_label = this.sizes[size].label
+
+ this.color = color
+ this.size = size
+
+ this.is_onesize = !! this.sizes[1]
+ this.$size.show().html(size_label)
+ if (color_label) {
+ this.$color.html(color_label)
+ }
+ else {
+ this.$color.hide()
+ }
+ }
+
// console.log(color, color_label, size, size_label)
this.item = data
this.details = details['Item']
this.code = data['DefaultCode10']
- this.color = color
- this.size = size
-
this.$num.html(num)
this.$title.html(title)
this.$type.html(type)
this.$price.html(price)
this.$body.html(body)
-
- this.$size.html(size_label)
- if (color_label) {
- this.$color.show().html(color_label)
- }
- else {
- this.$color.hide()
- }
+ this.showFooter()
+
this.deferScrollToTop()
},
@@ -167,6 +183,15 @@ var ProductView = ScrollableView.extend({
populate_selectors: function(data, details){
var sizes = {}, colors = {}, size_lookup = {}, default_color
+ console.log(details['Item']['ModelColors'].length)
+ if (! details['Item']['ModelColors'].length) {
+ this.not_available = true
+ return
+ }
+ else {
+ this.not_available = false
+ }
+
details['Item']['ModelColors'].forEach(function(color, index){
if (! default_color || color['Code10'] == data['DefaultCode10']) {
default_color = color['ColorId']
@@ -203,7 +228,7 @@ var ProductView = ScrollableView.extend({
},
select_size: function(){
-
+ if (this.not_available) { return }
if (this.is_onesize) { return this.select_color() }
if (this.item['Sizes'].length == 0) { return }
var sizes = Object.keys(this.sizes).map(function(key){
@@ -217,6 +242,7 @@ var ProductView = ScrollableView.extend({
},
select_color: function(){
+ if (this.not_available) { return }
if (this.item['Colors'].length == 0) { return }
var colors = Object.keys(this.colors).map(function(key){
return this.colors[key]
@@ -224,15 +250,19 @@ var ProductView = ScrollableView.extend({
app.selector.select("style", colors, function(color){
this.code = color.code
this.$color.html(color.label)
+
+ // UPDATE GALLERY
}.bind(this))
},
// ADD TO CART
save: function(){
+ if (this.not_available) { return }
this.add_to_cart({ route: false })
},
// BUY NOW
cancel: function(){
+ if (this.not_available) { return }
this.add_to_cart({ route: true })
},
diff --git a/StoneIsland/platforms/ios/www/js/lib/products/Selector.js b/StoneIsland/platforms/ios/www/js/lib/products/Selector.js
index 69bb1186..17278a06 100755
--- a/StoneIsland/platforms/ios/www/js/lib/products/Selector.js
+++ b/StoneIsland/platforms/ios/www/js/lib/products/Selector.js
@@ -27,17 +27,13 @@ var Selector = View.extend({
this.$el.show()
app.curtain.show("white")
this.visible = true
- var selectionXY = $("." + origin).offset()
- var selectionWidth = $("." + origin).width()
- var selectorHeight = $('#selector').height()
- console.log(selectionXY.left)
- console.log(selectionXY.top)
-
- $("#selector").css({"top":(selectionXY.top - selectorHeight),"left":selectionXY.left})
-
-
-
-
+// var selectionXY = $("." + origin).offset()
+// var selectionWidth = $("." + origin).width()
+// var selectorHeight = $('#selector').height()
+// console.log(selectionXY.left)
+// console.log(selectionXY.top)
+//
+// $("#selector").css({"top":(selectionXY.top - selectorHeight),"left":selectionXY.left})
},
hide: function(){
diff --git a/StoneIsland/platforms/ios/www/js/sdk/_sdk.js b/StoneIsland/platforms/ios/www/js/sdk/_sdk.js
index b7880e50..017df015 100755
--- a/StoneIsland/platforms/ios/www/js/sdk/_sdk.js
+++ b/StoneIsland/platforms/ios/www/js/sdk/_sdk.js
@@ -26,7 +26,7 @@ var sdk = (function(){
}
sdk.image = function(code, size){
- return "http://cdn.yoox.biz/" + code.substr(0,2) + "/" + code.substr(0,8) + "_" + size + ".jpg"
+ return "http://cdn.yoox.biz/" + code.substr(0,2) + "/" + code + "_" + size + ".jpg"
}
$.ajaxSetup({