Merge branch 'feature/mars-limit' into 'release/6.8.2'
mars 商品详情 See merge request !1592
Showing
2 changed files
with
13 additions
and
7 deletions
@@ -101,7 +101,7 @@ module.exports = class extends global.yoho.BaseModel { | @@ -101,7 +101,7 @@ module.exports = class extends global.yoho.BaseModel { | ||
101 | break; | 101 | break; |
102 | case 4: // 开售后,立即购买(用户已领取限购码) | 102 | case 4: // 开售后,立即购买(用户已领取限购码) |
103 | data.gotCode = true; | 103 | data.gotCode = true; |
104 | - data.cartInfo.canNotBuy = true; | 104 | + data.cartInfo.appBuy = 'limitProduct'; |
105 | break; | 105 | break; |
106 | case 5: // 开售前,限购码已被抢光(用户未领取限购码) | 106 | case 5: // 开售前,限购码已被抢光(用户未领取限购码) |
107 | data.codeEmpty = true; | 107 | data.codeEmpty = true; |
@@ -615,9 +615,7 @@ module.exports = class extends global.yoho.BaseModel { | @@ -615,9 +615,7 @@ module.exports = class extends global.yoho.BaseModel { | ||
615 | let isBeginSale = (result.data.saleStatus === 1); | 615 | let isBeginSale = (result.data.saleStatus === 1); |
616 | 616 | ||
617 | // 限购商品有关的展示状态 | 617 | // 限购商品有关的展示状态 |
618 | - let showStatus = 1; | ||
619 | - | ||
620 | - origin.showStatus && (showStatus = parseInt(result.data.showStatus, 10)); | 618 | + let showStatus = parseInt(result.data.showStatus, 10); |
621 | 619 | ||
622 | // 处理限购商品有关的按钮状态 | 620 | // 处理限购商品有关的按钮状态 |
623 | dest = this._procShowStatus(dest, showStatus, isBeginSale); | 621 | dest = this._procShowStatus(dest, showStatus, isBeginSale); |
@@ -330,9 +330,17 @@ setTimeout(() => { | @@ -330,9 +330,17 @@ setTimeout(() => { | ||
330 | 330 | ||
331 | $('.mars-jump-min-app').on('click', function() { | 331 | $('.mars-jump-min-app').on('click', function() { |
332 | if (yoho && yoho.isMarsApp) { | 332 | if (yoho && yoho.isMarsApp) { |
333 | - yoho.invokeMethod('go.minAppGoodsDetail', { | ||
334 | - url: '/pages/goodsDetail/goodsDetail?productSkn=' + productSkn | ||
335 | - }); | 333 | + let Limitcode = $('#limitProductCode').val(); |
334 | + | ||
335 | + if (Limitcode) { | ||
336 | + yoho.invokeMethod('go.minAppLimitDetail', { | ||
337 | + url: '/pages/product/detail/detail?limitProductCode=' + Limitcode // eslint-disable-line | ||
338 | + }); | ||
339 | + } else { | ||
340 | + yoho.invokeMethod('go.minAppGoodsDetail', { | ||
341 | + url: '/pages/goodsDetail/goodsDetail?productSkn=' + productSkn | ||
342 | + }); | ||
343 | + } | ||
336 | } | 344 | } |
337 | }); | 345 | }); |
338 | 346 |
-
Please register or login to post a comment