Commit e5bcde966da6eeb54cba48d8b53dc5cb0dd38c8c

Authored by yvan.ni
1 parent 1f0cf8f8

预售商品不使用优惠券的优化

商品活动的优化
packageC/pages/presell/goodsInfo/goodsInfo.js
... ... @@ -574,8 +574,11 @@ Page({
574 574 fir_quan = res1.data.data.pageData;
575 575 })
576 576 }
  577 +
  578 +
  579 + let arr = []
577 580 //过滤不是本商品的单品优惠券-------------------
578   - if (fir_quan.length > 0) {
  581 + if (fir_quan && fir_quan.length > 0) {
579 582 let goodInfo = th.data.data || {}
580 583 console.log('商品++++++++++++++++++++++');
581 584 console.log(goodInfo);
... ... @@ -586,14 +589,13 @@ Page({
586 589 }
587 590 }
588 591 }
589   - }
590   -
591   - let arr = []
592   - let length = fir_quan.length
593   - if (length <= 3) {
594   - arr = fir_quan
595   - } else {
596   - arr = fir_quan.splice(0, 3);
  592 +
  593 + let length = fir_quan.length
  594 + if (length <= 3) {
  595 + arr = fir_quan
  596 + } else {
  597 + arr = fir_quan.splice(0, 3);
  598 + }
597 599 }
598 600 //--------获取视频图片---------
599 601 await getApp().request.promiseGet("/api/weshop/goodsVideos/get/" + os.stoid + "/" + ee.data.gid, {
... ...
pages/goods/goodsInfo/goodsInfo.js
... ... @@ -7874,7 +7874,9 @@ Page({
7874 7874 }
7875 7875  
7876 7876 }
7877   -
  7877 + else{
  7878 + func()
  7879 + }
7878 7880 }
7879 7881 });
7880 7882 },
... ...