diff options
Diffstat (limited to 'StoneIsland/www/js/lib/products/ProductView.js')
| -rwxr-xr-x | StoneIsland/www/js/lib/products/ProductView.js | 19 |
1 files changed, 16 insertions, 3 deletions
diff --git a/StoneIsland/www/js/lib/products/ProductView.js b/StoneIsland/www/js/lib/products/ProductView.js index 81ad536d..4ae77c1f 100755 --- a/StoneIsland/www/js/lib/products/ProductView.js +++ b/StoneIsland/www/js/lib/products/ProductView.js @@ -118,7 +118,9 @@ var ProductView = ScrollableView.extend({ var title = name_partz.join(' ') var type = title_case( data['MicroCategory'] ) var price = "$" + data['DiscountedPrice'] + ".00" - var body = descriptions['Details'] + " " + descriptions['EditorialDescription'] + var details = descriptions['Details'] || "" + var editorial = descriptions['EditorialDescription'] || "" + var body = details + " " + editorial // body = body.replace(/<br>/g, "<br><br>").replace(/(<br>)+$/, "") var default_color_id = this.populate_selectors(data, details) @@ -218,10 +220,21 @@ var ProductView = ScrollableView.extend({ }) details['Item']['ModelSizes'].forEach(function(size){ - var label = SIZE_LOOKUP[ size['Default']['Text'] ] - if (! label && ! size['Default']['Labeled']) { + var label = "" + if (details['Item']['SizeTypeId'] == 412) { // shoes label = size['Default']['Text'] + " " + size['Default']['ClassFamily'] + console.log("shoes?", label) } + else { // everything else + label = SIZE_LOOKUP[ size['Default']['Text'] ] + } + if (! label) { + label = size['Default']['Text'] + if (size['Default']['Labeled']) { + label += " " + size['Default']['ClassFamily'] + } + } + console.log(size) size_lookup[ label ] = size['SizeId'] console.log( label ) sizes[ size['SizeId'] ] = { |
