...
|
...
|
@@ -317,10 +317,12 @@ class ChosePanel { |
|
|
return false;
|
|
|
}
|
|
|
}
|
|
|
if (this.modes.tickets && buyNum > this.maxBuyNum) {
|
|
|
tip.show(`每人只可购买${this.maxBuyNum}张当日门票`);
|
|
|
if (this.modes.tickets && buyNum > selectSku.limitNum) {
|
|
|
if (selectSku.limitNum) {
|
|
|
tip.show(`每人只可购买${selectSku.limitNum}张此门票`);
|
|
|
return false;
|
|
|
}
|
|
|
}
|
|
|
if (this.modes.limit && buyNum > this.maxBuyNum) {
|
|
|
tip.show('您选择数量大于限购数量~');
|
|
|
return false;
|
...
|
...
|
@@ -445,13 +447,13 @@ class ChosePanel { |
|
|
return $(ele).text();
|
|
|
}));
|
|
|
|
|
|
if (this.modes.tickets) {
|
|
|
let $chosed = $('.block.chosed');
|
|
|
// if (this.modes.tickets) {
|
|
|
// let $chosed = $('.block.chosed');
|
|
|
|
|
|
valueList = Array.from($chosed.not('.hide').map((index, ele) => {
|
|
|
return $(ele).text();
|
|
|
}));
|
|
|
}
|
|
|
// valueList = Array.from($chosed.not('.hide').map((index, ele) => {
|
|
|
// return $(ele).text();
|
|
|
// }));
|
|
|
// }
|
|
|
|
|
|
if (valueList.length) {
|
|
|
$noChoose.addClass('hide');
|
...
|
...
|
@@ -464,11 +466,16 @@ class ChosePanel { |
|
|
|
|
|
if (selectSku) {
|
|
|
// 设置left-num文字
|
|
|
let cartInfo = this.data.cartInfo,
|
|
|
numText;
|
|
|
// let cartInfo = this.data.cartInfo,
|
|
|
// numText;
|
|
|
let numText;
|
|
|
|
|
|
if (this.modes.limit) {
|
|
|
numText = `限购${cartInfo.limit}件`;
|
|
|
if (selectSku.limitNum) {
|
|
|
if (selectSku.limitNum) {
|
|
|
numText = `限购${selectSku.limitNum}件`;
|
|
|
} else {
|
|
|
numText = '';
|
|
|
}
|
|
|
} else if (this.modes.soonSoldOut) {
|
|
|
numText = '即将售罄';
|
|
|
} else if (selectSku.storage < 4 && selectSku.storage > 0) {
|
...
|
...
|
|