Showing
1 changed file
with
8 additions
and
5 deletions
@@ -1457,6 +1457,7 @@ $('.package-box').on('click', '#buy-detail', function() { | @@ -1457,6 +1457,7 @@ $('.package-box').on('click', '#buy-detail', function() { | ||
1457 | var $pkgColor = $pkType.find('.chose-done .pkg-color'); | 1457 | var $pkgColor = $pkType.find('.chose-done .pkg-color'); |
1458 | var $pkgSize = $pkType.find('.chose-done .pkg-size'); | 1458 | var $pkgSize = $pkType.find('.chose-done .pkg-size'); |
1459 | var $pkgSizeWarn = $pkType.find('.pkg-sizes .size-warn'); | 1459 | var $pkgSizeWarn = $pkType.find('.pkg-sizes .size-warn'); |
1460 | + var selectedSize = ''; | ||
1460 | 1461 | ||
1461 | if ($this.hasClass('focus') || $this.hasClass('disable')) { | 1462 | if ($this.hasClass('focus') || $this.hasClass('disable')) { |
1462 | return; | 1463 | return; |
@@ -1464,13 +1465,15 @@ $('.package-box').on('click', '#buy-detail', function() { | @@ -1464,13 +1465,15 @@ $('.package-box').on('click', '#buy-detail', function() { | ||
1464 | 1465 | ||
1465 | $this.addClass('focus').siblings('.focus').removeClass('focus'); | 1466 | $this.addClass('focus').siblings('.focus').removeClass('focus'); |
1466 | 1467 | ||
1467 | - // 取消尺码的选择 | ||
1468 | - $pkSizesUl.find('li').removeClass('focus'); | ||
1469 | - $pkgColor.html('"' + $colorName.html() + '"'); | ||
1470 | - $pkgSize.html(''); | ||
1471 | - | ||
1472 | $pkSizesUl.addClass('hide').eq(index).removeClass('hide'); | 1468 | $pkSizesUl.addClass('hide').eq(index).removeClass('hide'); |
1473 | $pkgSizeWarn.addClass('hide'); | 1469 | $pkgSizeWarn.addClass('hide'); |
1470 | + | ||
1471 | + $pkgColor.html('"' + $colorName.html() + '"'); | ||
1472 | + | ||
1473 | + if($pkSizesUl.eq(index).find('li.focus').length > 0) { | ||
1474 | + selectedSize = '"' + $pkSizesUl.eq(index).find('li.focus').html() + '码"'; | ||
1475 | + } | ||
1476 | + $pkgSize.html(selectedSize); | ||
1474 | }); | 1477 | }); |
1475 | 1478 | ||
1476 | // 选择尺码 | 1479 | // 选择尺码 |
-
Please register or login to post a comment