diff options
Diffstat (limited to 'StoneIsland/www/js/lib')
| -rwxr-xr-x | StoneIsland/www/js/lib/blogs/BlogView.js | 2 | ||||
| -rwxr-xr-x | StoneIsland/www/js/lib/products/ProductView.js | 12 |
2 files changed, 13 insertions, 1 deletions
diff --git a/StoneIsland/www/js/lib/blogs/BlogView.js b/StoneIsland/www/js/lib/blogs/BlogView.js index 5263bee5..a6711f3e 100755 --- a/StoneIsland/www/js/lib/blogs/BlogView.js +++ b/StoneIsland/www/js/lib/blogs/BlogView.js @@ -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/www/js/lib/products/ProductView.js b/StoneIsland/www/js/lib/products/ProductView.js index 071a804d..31a64273 100755 --- a/StoneIsland/www/js/lib/products/ProductView.js +++ b/StoneIsland/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,16 @@ var ProductView = ScrollableView.extend({ this.$sizing.hide() } + this.$extraMessage.hide() + if (item['C10Attributes'] && item['C10Attributes'].length) { + item['C10Attributes'].forEach(function(attr){ + if (attr['key'] === 'Limited_Edition') { + this.$extraMessage.html(stripHTML( attr['value'] )) + this.$extraMessage.show() + } + }.bind(this)) + } + this.populate_sizes() this.populate_colors() |
