Authored by hongweigao

切换保留选择过的尺码

... ... @@ -1457,6 +1457,7 @@ $('.package-box').on('click', '#buy-detail', function() {
var $pkgColor = $pkType.find('.chose-done .pkg-color');
var $pkgSize = $pkType.find('.chose-done .pkg-size');
var $pkgSizeWarn = $pkType.find('.pkg-sizes .size-warn');
var selectedSize = '';
if ($this.hasClass('focus') || $this.hasClass('disable')) {
return;
... ... @@ -1464,13 +1465,15 @@ $('.package-box').on('click', '#buy-detail', function() {
$this.addClass('focus').siblings('.focus').removeClass('focus');
// 取消尺码的选择
$pkSizesUl.find('li').removeClass('focus');
$pkgColor.html('"' + $colorName.html() + '"');
$pkgSize.html('');
$pkSizesUl.addClass('hide').eq(index).removeClass('hide');
$pkgSizeWarn.addClass('hide');
$pkgColor.html('"' + $colorName.html() + '"');
if($pkSizesUl.eq(index).find('li.focus').length > 0) {
selectedSize = '"' + $pkSizesUl.eq(index).find('li.focus').html() + '码"';
}
$pkgSize.html(selectedSize);
});
// 选择尺码
... ...