Commit 86c301d84bf5b038900ab37b7bf302ddb7d4d839
1 parent
ed2e1228
oa优化
Showing
2 changed files
with
13 additions
and
9 deletions
pages/cart/cart/cart.js
| @@ -3854,6 +3854,7 @@ Page({ | @@ -3854,6 +3854,7 @@ Page({ | ||
| 3854 | //主要判断有没有促销活动 | 3854 | //主要判断有没有促销活动 |
| 3855 | var is_sele_prom = 0; | 3855 | var is_sele_prom = 0; |
| 3856 | var is_gift_del = 0; | 3856 | var is_gift_del = 0; |
| 3857 | + | ||
| 3857 | for (var i = 0; i < list.goods.length; i++) { | 3858 | for (var i = 0; i < list.goods.length; i++) { |
| 3858 | var item = list.goods[i]; | 3859 | var item = list.goods[i]; |
| 3859 | if (item.prom_type == 3 && item.selected && !item.is_gift) { | 3860 | if (item.prom_type == 3 && item.selected && !item.is_gift) { |
| @@ -3927,6 +3928,7 @@ Page({ | @@ -3927,6 +3928,7 @@ Page({ | ||
| 3927 | limit_num=prom.limit_num; | 3928 | limit_num=prom.limit_num; |
| 3928 | user_pre_buynum = await this.getUserBuyPromNum_pre(prom.id) | 3929 | user_pre_buynum = await this.getUserBuyPromNum_pre(prom.id) |
| 3929 | } | 3930 | } |
| 3931 | + | ||
| 3930 | //如果活动已经结束 | 3932 | //如果活动已经结束 |
| 3931 | if (!prom || prom.is_end || prom.end_time < ut.gettimestamp()) { | 3933 | if (!prom || prom.is_end || prom.end_time < ut.gettimestamp()) { |
| 3932 | for (var ii in list.goods) { | 3934 | for (var ii in list.goods) { |
| @@ -3992,6 +3994,8 @@ Page({ | @@ -3992,6 +3994,8 @@ Page({ | ||
| 3992 | } | 3994 | } |
| 3993 | } | 3995 | } |
| 3994 | } | 3996 | } |
| 3997 | + }else{ | ||
| 3998 | + continue; | ||
| 3995 | } | 3999 | } |
| 3996 | 4000 | ||
| 3997 | 4001 | ||
| @@ -4147,7 +4151,7 @@ Page({ | @@ -4147,7 +4151,7 @@ Page({ | ||
| 4147 | //优惠促销用户参与次数 | 4151 | //优惠促销用户参与次数 |
| 4148 | async getUserBuyPromNum_pre(prom_id){ | 4152 | async getUserBuyPromNum_pre(prom_id){ |
| 4149 | var userInfo = getApp().globalData.userInfo; | 4153 | var userInfo = getApp().globalData.userInfo; |
| 4150 | - var url = `/api/weshop/ordergoods/getUserBuyPromNum?store_id=${os.stoid}&user_id=${userInfo.user_id}&prom_type=3&prom_id=${prom_id}`; | 4154 | + var url = `/api/weshop/ordergoods/getUserBuyPromNum?is_all=1&store_id=${os.stoid}&user_id=${userInfo.user_id}&prom_type=3&prom_id=${prom_id}`; |
| 4151 | let res = await getApp().request.promiseGet(url, { | 4155 | let res = await getApp().request.promiseGet(url, { |
| 4152 | data:{} | 4156 | data:{} |
| 4153 | }); | 4157 | }); |
| @@ -4529,7 +4533,7 @@ Page({ | @@ -4529,7 +4533,7 @@ Page({ | ||
| 4529 | store_id: os.stoid, goodsidlist: gd, is_detail: 1, user_id: user_id | 4533 | store_id: os.stoid, goodsidlist: gd, is_detail: 1, user_id: user_id |
| 4530 | }; | 4534 | }; |
| 4531 | 4535 | ||
| 4532 | - //获取秒杀的多规格 | 4536 | + //获取秒杀的多规格 |
| 4533 | getApp().request.promiseGet(url, { data: req_data }).then(res => { | 4537 | getApp().request.promiseGet(url, { data: req_data }).then(res => { |
| 4534 | if (res.data.code == 0 && res.data.data) { | 4538 | if (res.data.code == 0 && res.data.data) { |
| 4535 | if (res.data.data.length == 1) { | 4539 | if (res.data.data.length == 1) { |
pages/goods/goodsList/goodsList.wxml
| @@ -119,7 +119,7 @@ | @@ -119,7 +119,7 @@ | ||
| 119 | </view> | 119 | </view> |
| 120 | </view> | 120 | </view> |
| 121 | <view class="comment"> | 121 | <view class="comment"> |
| 122 | - <view wx:if="{{is_retail_price}}" class="word-line xc-ash rmb">{{item.market_price}}</view> | 122 | + <view wx:if="{{is_retail_price}}" class="word-line xc-ash rmb no_line_x">{{item.market_price}}</view> |
| 123 | <view class="fs24 t-r"> | 123 | <view class="fs24 t-r"> |
| 124 | <span>评论{{item.comment_count}}</span> | 124 | <span>评论{{item.comment_count}}</span> |
| 125 | <span class="pdl30">已售{{item.sales_sum}}</span> | 125 | <span class="pdl30">已售{{item.sales_sum}}</span> |
| @@ -160,7 +160,7 @@ | @@ -160,7 +160,7 @@ | ||
| 160 | <block wx:else> | 160 | <block wx:else> |
| 161 | <view> | 161 | <view> |
| 162 | <view class="price rmb">{{item.shop_price}}</view> | 162 | <view class="price rmb">{{item.shop_price}}</view> |
| 163 | - <view wx:if="{{is_retail_price}}" class="word-line xc-ash rmb">{{item.market_price}}</view> | 163 | + <view wx:if="{{is_retail_price}}" class="word-line xc-ash rmb no_line_x">{{item.market_price}}</view> |
| 164 | </view> | 164 | </view> |
| 165 | <!-- <view class="price">¥{{item.shop_price}}</view> --> | 165 | <!-- <view class="price">¥{{item.shop_price}}</view> --> |
| 166 | <view class="comment pdt10"> | 166 | <view class="comment pdt10"> |
| @@ -175,7 +175,7 @@ | @@ -175,7 +175,7 @@ | ||
| 175 | <view wx:else> | 175 | <view wx:else> |
| 176 | <view class="flex ai-center"> | 176 | <view class="flex ai-center"> |
| 177 | <view class="price rmb">{{item.shop_price}}</view> | 177 | <view class="price rmb">{{item.shop_price}}</view> |
| 178 | - <view wx:if="{{is_retail_price}}" class="word-line xc-ash rmb fs24 mgl10">{{item.market_price}}</view> | 178 | + <view wx:if="{{is_retail_price}}" class="word-line xc-ash rmb fs24 mgl10 no_line_x">{{item.market_price}}</view> |
| 179 | </view> | 179 | </view> |
| 180 | 180 | ||
| 181 | <view class="comment pdt10"> | 181 | <view class="comment pdt10"> |
| @@ -234,7 +234,7 @@ | @@ -234,7 +234,7 @@ | ||
| 234 | </view> | 234 | </view> |
| 235 | </view> | 235 | </view> |
| 236 | <view class="comment"> | 236 | <view class="comment"> |
| 237 | - <view wx:if="{{is_retail_price}}" class="word-line xc-ash rmb">{{item.market_price}}</view> | 237 | + <view wx:if="{{is_retail_price}}" class="word-line xc-ash rmb no_line_x">{{item.market_price}}</view> |
| 238 | <view class="fs24 t-r"> | 238 | <view class="fs24 t-r"> |
| 239 | <span>评论{{item.comment_count}}</span> | 239 | <span>评论{{item.comment_count}}</span> |
| 240 | <span class="pdl30">已售{{item.sales_sum}}</span> | 240 | <span class="pdl30">已售{{item.sales_sum}}</span> |
| @@ -275,7 +275,7 @@ | @@ -275,7 +275,7 @@ | ||
| 275 | <block wx:else> | 275 | <block wx:else> |
| 276 | <view> | 276 | <view> |
| 277 | <view class="price rmb">{{item.shop_price}}</view> | 277 | <view class="price rmb">{{item.shop_price}}</view> |
| 278 | - <view wx:if="{{is_retail_price}}" class="word-line xc-ash rmb">{{item.market_price}}</view> | 278 | + <view wx:if="{{is_retail_price}}" class="word-line xc-ash rmb no_line_x">{{item.market_price}}</view> |
| 279 | </view> | 279 | </view> |
| 280 | <!-- <view class="price">¥{{item.shop_price}}</view> --> | 280 | <!-- <view class="price">¥{{item.shop_price}}</view> --> |
| 281 | <view class="comment pdt10"> | 281 | <view class="comment pdt10"> |
| @@ -290,8 +290,8 @@ | @@ -290,8 +290,8 @@ | ||
| 290 | <view wx:else> | 290 | <view wx:else> |
| 291 | <view class=""> | 291 | <view class=""> |
| 292 | <view class="price rmb">{{item.shop_price}}</view> | 292 | <view class="price rmb">{{item.shop_price}}</view> |
| 293 | - <view wx:if="{{is_retail_price}}" class="word-line xc-ash rmb fs24 mgl10">{{item.market_price}}</view> | ||
| 294 | - </view> | 293 | + <view wx:if="{{is_retail_price}}" class="word-line xc-ash rmb fs24 mgl10 no_line_x">{{item.market_price}}</view> |
| 294 | + </view> | ||
| 295 | 295 | ||
| 296 | <view class="comment pdt10"> | 296 | <view class="comment pdt10"> |
| 297 | <view class="fs24 t-r"> | 297 | <view class="fs24 t-r"> |