\
\
\
'
+ '' + indicatorText + '
\
\
\
';
$('div#schartContainer').html(htmlIndicator);
}
InventoryIndicator.data = data;
InventoryIndicator.buildVariantName = function() {
var options = [];
$('.single-option-selector:visible').each(function(){
options.push($(this).val());
});
var name = options.join(' / ');
return name;
}
$('.single-option-selector').bind('change', function() {
if ($('.single-option-selector').length == 1) {
InventoryIndicator.show($('.single-option-selector option:selected').val());
} else {
InventoryIndicator.show(InventoryIndicator.buildVariantName());
}
});
if ($('.single-option-selector').length) {
$('.single-option-selector:first').trigger('change');
} else {
InventoryIndicator.show('XS');
}
}
window.attachEvent ? window.attachEvent('onload', asyncInventoryIndicatorLoad) : window.addEventListener('load', asyncInventoryIndicatorLoad, false);
})(jQuery);
//]]>