summaryrefslogtreecommitdiff
path: root/StoneIsland/platforms/ios/www/js
diff options
context:
space:
mode:
Diffstat (limited to 'StoneIsland/platforms/ios/www/js')
-rwxr-xr-xStoneIsland/platforms/ios/www/js/lib/blogs/BlogView.js4
-rwxr-xr-xStoneIsland/platforms/ios/www/js/lib/products/ProductView.js13
2 files changed, 15 insertions, 2 deletions
diff --git a/StoneIsland/platforms/ios/www/js/lib/blogs/BlogView.js b/StoneIsland/platforms/ios/www/js/lib/blogs/BlogView.js
index 5263bee5..c5d77536 100755
--- a/StoneIsland/platforms/ios/www/js/lib/blogs/BlogView.js
+++ b/StoneIsland/platforms/ios/www/js/lib/blogs/BlogView.js
@@ -13,7 +13,7 @@ var BlogView = View.extend({
fetch: function(fn){
$.ajax({
method: "GET",
- url: sdk.env === 'test' ? '/db.json' : sdk.cms() + '/db.json',
+ url: (sdk.env === 'test' || sdk.env === 'development') ? '/db.json' : sdk.cms() + '/db.json',
// url: "https://stone.giraffe.life/db.json",
success: function(data){
this.success(data)
@@ -37,7 +37,7 @@ var BlogView = View.extend({
// sdk.env = 'test'
- if (sdk.env === 'test') {
+ if (sdk.env === 'test' || sdk.env === 'development') {
app.store = data.store[1]
}
else {
diff --git a/StoneIsland/platforms/ios/www/js/lib/products/ProductView.js b/StoneIsland/platforms/ios/www/js/lib/products/ProductView.js
index 071a804d..34f7927e 100755
--- a/StoneIsland/platforms/ios/www/js/lib/products/ProductView.js
+++ b/StoneIsland/platforms/ios/www/js/lib/products/ProductView.js
@@ -5,6 +5,7 @@ var ProductView = ScrollableView.extend({
events: {
"click .fit": "scroll_to_bottom",
"click .notAvailableInCanada": "scroll_to_bottom",
+ "click .extraMessage": "scroll_to_bottom",
"change select[name=size]": "select_size",
"change select[name=color]": "select_color",
// "click .size": "select_size",
@@ -33,6 +34,7 @@ var ProductView = ScrollableView.extend({
this.$fit = this.$(".fit")
this.$fitHeader = this.$('.fitHeader')
this.$notAvailableInCanada = this.$(".notAvailableInCanada")
+ this.$extraMessage = this.$(".extraMessage")
this.$sizing = this.$(".sizing")
this.$style = this.$(".style")
},
@@ -233,6 +235,17 @@ var ProductView = ScrollableView.extend({
this.$sizing.hide()
}
+ this.$extraMessage.hide()
+ if (data['C10Attributes'] && data['C10Attributes'].length) {
+ data['C10Attributes'].forEach(function(attr){
+ if (attr['Key'] === 'Limited_Edition') {
+ this.$extraMessage.html(stripHTML( attr['Value'] ))
+ this.$extraMessage.show()
+ app.footer.show(stripHTML( attr['Value'] ))
+ }
+ }.bind(this))
+ }
+
this.populate_sizes()
this.populate_colors()