...
|
...
|
@@ -61,6 +61,10 @@ function checkColorSizeNum() { |
|
|
function show(html, cb) {
|
|
|
if (html) {
|
|
|
$chosePanel.html(html);
|
|
|
if ($('#promotionId').val() !== '') {
|
|
|
$yohoPage.off('touchstart', '.btn-minus');
|
|
|
$yohoPage.off('touchstart', '.btn-plus');
|
|
|
}
|
|
|
init();
|
|
|
}
|
|
|
$('.chose-panel').show();
|
...
|
...
|
@@ -288,6 +292,10 @@ $yohoPage.on('touchstart', '.btn-minus', function() { |
|
|
}
|
|
|
|
|
|
//TODO:库存数验证
|
|
|
if (num > leftNum) {
|
|
|
$num.val(leftNum);
|
|
|
return;
|
|
|
}
|
|
|
$num.val(num + 1);
|
|
|
}).on('touchstart', '#chose-btn-sure', function() {
|
|
|
|
...
|
...
|
@@ -303,6 +311,10 @@ $yohoPage.on('touchstart', '.btn-minus', function() { |
|
|
if (!checkColorSizeNum()) {
|
|
|
return;
|
|
|
}
|
|
|
if (isNaN(num)) {
|
|
|
tip.show('您选择的数量不是一个数字~');
|
|
|
return;
|
|
|
}
|
|
|
|
|
|
//TODO status change
|
|
|
if ($('#chose-btn-sure').html() === '已售罄') {
|
...
|
...
|
|