Commit 5508f6eb7f1f0bddea046f553d8060f359c89117
1 parent
4fcb9f9b
1。 小程序立即购买,设置全程包邮,主商品不包邮,会影响赠品也不包邮,其实赠品是不在不包邮列表中,应该包邮
2。 分类列表的等级名称最多要显示6个自以上 3。 商品详情页的积分分享标题的修改 4。 商品搜索列表和商品列表的排序默认要按 sort排序 5。 商品取消退款的功能
Showing
13 changed files
with
94 additions
and
36 deletions
pages/cart/cart2/cart2.js
... | ... | @@ -3136,9 +3136,9 @@ Page({ |
3136 | 3136 | } |
3137 | 3137 | //如果有设置不包邮商品 |
3138 | 3138 | if(no_by_data && no_by_data.goods_list && gift_freight_free){ |
3139 | - if(th.check_by_goods(no_by_data.goods_list)){ | |
3139 | + if(th.check_by_goods(no_by_data.goods_list,good.goods_id)){ | |
3140 | 3140 | gift_freight_free=0; |
3141 | - th.data.is_no_by[th.data.bn_pick]=1; | |
3141 | + //th.data.is_no_by[th.data.bn_pick]=1; | |
3142 | 3142 | } |
3143 | 3143 | } |
3144 | 3144 | var t_shipping_price= |
... | ... | @@ -3174,7 +3174,6 @@ Page({ |
3174 | 3174 | } |
3175 | 3175 | } |
3176 | 3176 | return is_use; |
3177 | - | |
3178 | 3177 | }, |
3179 | 3178 | //检查是不是有其他门店的订单在选择了包邮券 |
3180 | 3179 | check_other_use_by:function (iter,pkid) { | ... | ... |
pages/goods/categoryList/categoryList.js
... | ... | @@ -164,7 +164,7 @@ Page({ |
164 | 164 | //--- 判断是等级会员,且在有效期范围内 --- |
165 | 165 | if (user.card_field && now < end) { |
166 | 166 | var card_name = ob.name_map.get(user.card_field); |
167 | - if (card_name.length > 4) card_name = card_name.substring(0, 4); | |
167 | + //if (card_name.length > 4) card_name = card_name.substring(0, 4); | |
168 | 168 | th.setData({ card_field: user.card_field, card_name: card_name, card_list: ob.card_list }); |
169 | 169 | } |
170 | 170 | } |
... | ... | @@ -344,9 +344,9 @@ Page({ |
344 | 344 | for(var i=0;i<arr.length;i++){ |
345 | 345 | arr[i]['items']['is_show_class'] = false; |
346 | 346 | var mobile_name = arr[i]['items']['name'] |
347 | - if(mobile_name.length > 4){ | |
348 | - arr[i]['items']['name'] = mobile_name.substring(0, 4) | |
349 | - } | |
347 | + //if(mobile_name.length > 4){ | |
348 | + //arr[i]['items']['name'] = mobile_name.substring(0, 4) | |
349 | + //} | |
350 | 350 | } |
351 | 351 | if(t.data.is_show_pl==1 && t.data.is_show_pp != 1 && t.data.is_show_gb != 1){ |
352 | 352 | arr[0]['items']['is_show_class'] = true; | ... | ... |
pages/goods/categoryList/categoryList.wxml
... | ... | @@ -435,7 +435,7 @@ |
435 | 435 | <block wx:if="{{item[card_field]>0}}"> |
436 | 436 | <view class="flex ai_and"> |
437 | 437 | <view class="price">¥{{item[card_field]}}</view> |
438 | - <view class="card_bg"> | |
438 | + <view class="card_bg ellipsis-1"> | |
439 | 439 | <image src="{{url}}/miniapp/images/plus/dj_icon.png"></image> |
440 | 440 | <view class="card_name">{{card_name}}</view> |
441 | 441 | </view> |
... | ... | @@ -463,9 +463,9 @@ |
463 | 463 | <view class="comment flex jc_sb"> |
464 | 464 | <view class="flex ai-center"> |
465 | 465 | <view class="">¥{{g_filter.get_card_price(item,card_list,0)}}</view> |
466 | - <view class="card_bg flex ai-center"> | |
466 | + <view class="card_bg ellipsis-1"> | |
467 | 467 | <image src="{{url}}/miniapp/images/plus/dj_icon.png"></image> |
468 | - <text>{{g_filter.get_card_price(item,card_list,1)}}</text> | |
468 | + <view class="card_name">{{g_filter.get_card_price(item,card_list,1)}}</view> | |
469 | 469 | </view> |
470 | 470 | </view> |
471 | 471 | </view> | ... | ... |
pages/goods/goodsInfo/goodsInfo.js
... | ... | @@ -297,8 +297,7 @@ Page({ |
297 | 297 | gid=gid_str[0]; |
298 | 298 | if(gid_str.length>1){ |
299 | 299 | first_leader=gid_str[1]; |
300 | - } | |
301 | - | |
300 | + } | |
302 | 301 | //-- 如果有room_id的获取 -- |
303 | 302 | if(gid_str.length>2 && gid_str[2]){ |
304 | 303 | room_id=gid_str[2]; |
... | ... | @@ -1813,7 +1812,15 @@ Page({ |
1813 | 1812 | //如果是积分购的时候 |
1814 | 1813 | if(th.data.prom_type==4){ |
1815 | 1814 | var name = th.data.prom_act.name; |
1816 | - ob.title=name; | |
1815 | + //-- 积分购的 -- | |
1816 | + var pri0 = th.data.prom_act.addmoney; | |
1817 | + var integral=th.data.prom_act.integral; | |
1818 | + var text=""; | |
1819 | + if(integral){text=integral+"积分"; } | |
1820 | + if(pri0 && integral){ text+="+";} | |
1821 | + if(pri0){ text+="¥"+pri0;} | |
1822 | + | |
1823 | + ob.title= text+" "+name; | |
1817 | 1824 | } |
1818 | 1825 | |
1819 | 1826 | return ob; | ... | ... |
pages/goods/goodsList/goodsList.js
... | ... | @@ -163,7 +163,7 @@ Page({ |
163 | 163 | this.data.requestUrl = t; |
164 | 164 | |
165 | 165 | //不是商品分组的,不是默认排序的 |
166 | - if(t.indexOf("group_id")==-1 || e.data.tabname!="goods_id" ){ | |
166 | + if(t.indexOf("group_id")==-1 || e.data.tabname!="sort" ){ | |
167 | 167 | t += "&orderField=" + e.data.tabname; |
168 | 168 | t += "&orderType=" + e.data.adname; |
169 | 169 | } | ... | ... |
pages/goods/goodsList/goodsList.wxml
... | ... | @@ -15,8 +15,8 @@ |
15 | 15 | </view> |
16 | 16 | |
17 | 17 | <view class="nav"> |
18 | - <navigator bindtap="changeTab" class="nav-item" data-href="goods_id" data-ad="{{adname}}">综合 | |
19 | - <view class="ico-dg" wx:if="{{tabname=='goods_id'}}"> | |
18 | + <navigator bindtap="changeTab" class="nav-item" data-href="sort" data-ad="{{adname}}">综合 | |
19 | + <view class="ico-dg" wx:if="{{tabname=='sort'}}"> | |
20 | 20 | <image class="wh100" src="{{iurl}}/miniapp/images/dg.png" wx:if="{{adname=='desc'}}"></image> |
21 | 21 | <image class="wh100" src="{{iurl}}/miniapp/images/up_s.png" wx:if="{{adname=='asc'}}"></image> |
22 | 22 | </view> | ... | ... |
pages/goods/goodsList/goodsList.wxss
pages/goods/search/search.wxml
1 | 1 | <wxs module="g_filter" src="g_filter.wxs"></wxs> |
2 | 2 | <view class="container"> |
3 | 3 | <view class="nav"> |
4 | - <navigator bindtap="changeTab" class="nav-item" data-href="goods_id" data-ad="{{adname}}">综合 | |
5 | - <view class="ico-dg" wx:if="{{tabname=='goods_id'}}"> | |
4 | + <navigator bindtap="changeTab" class="nav-item" data-href="sort" data-ad="{{adname}}">综合 | |
5 | + <view class="ico-dg" wx:if="{{tabname=='sort'}}"> | |
6 | 6 | <image class="wh100" src="{{url}}/miniapp/images/dg.png" wx:if="{{adname=='desc'}}"></image> |
7 | 7 | <image class="wh100" src="{{url}}/miniapp/images/up_s.png" wx:if="{{adname=='asc'}}"></image> |
8 | 8 | </view> | ... | ... |
pages/user/return_goods_info/return_goods_info.js
... | ... | @@ -10,7 +10,7 @@ Page({ |
10 | 10 | url: r.url, |
11 | 11 | resourceUrl: r.imghost, |
12 | 12 | return_goods: null, |
13 | - goods: null | |
13 | + goods: null, | |
14 | 14 | }, |
15 | 15 | onLoad: function(e) { |
16 | 16 | if (e.order_id!=undefined){ |
... | ... | @@ -130,16 +130,27 @@ Page({ |
130 | 130 | }); |
131 | 131 | }, |
132 | 132 | cancelReturn: function() { |
133 | - var e = this, t = this.data.return_goods.id; | |
133 | + var e = this, | |
134 | + id = this.data.return_goods.id; | |
134 | 135 | wx.showModal({ |
135 | 136 | title: "确定取消售后服务?", |
136 | 137 | success: function(r) { |
137 | - r.confirm && o.post("/api/order/return_goods_cancel", { | |
138 | + r.confirm && o.put("/api/weshop/order/returngoods/update", { | |
138 | 139 | data: { |
139 | - id: t | |
140 | + id: id, | |
141 | + store_id:os.stoid, | |
142 | + status:3, | |
143 | + remark:'客户取消' | |
140 | 144 | }, |
141 | 145 | success: function(r) { |
142 | - wx.setStorageSync("user:return_goods_list:update", !0), e.requestReturnGoods(t); | |
146 | + if(r.data.code==0){ | |
147 | + getApp().showWarning('取消成功'); | |
148 | + setTimeout(function(){ | |
149 | + wx.setStorageSync("user:return_goods_list:update", !0), e.requestReturnGoods(id); | |
150 | + },1000) | |
151 | + } | |
152 | + | |
153 | + | |
143 | 154 | } |
144 | 155 | }); |
145 | 156 | } | ... | ... |
pages/user/return_goods_info/return_goods_info.wxml
1 | 1 | <wxs module="filters" src="../../../utils/filter.wxs"></wxs> |
2 | +<wxs module="fil" src="fil.wxs"></wxs> | |
2 | 3 | <view class="order-mes"> |
3 | 4 | <view class="order-name"> |
4 | 5 | <view>订单编号:{{return_goods.order_sn}}</view> |
... | ... | @@ -54,12 +55,12 @@ |
54 | 55 | </view> |
55 | 56 | <view class="apply-state"> |
56 | 57 | <view class="state-item"> |
57 | - <view class="item-wrap"> | |
58 | + <view wx:if="{{return_goods.status==0}}" class="item-wrap"> | |
58 | 59 | <view class="state-title">您的服务单已申请成功,等待售后审核中</view> |
59 | 60 | <view class="state-time">{{return_goods.addTimeFormat}}</view> |
60 | - <view class="state-user">操作人:系统</view> | |
61 | + <view class="state-user">操作人:客户</view> | |
61 | 62 | </view> |
62 | - <view class="item-wrap" wx:if="{{return_goods.status==2}}"> | |
63 | + <view class="item-wrap" wx:if="{{return_goods.status==1}}"> | |
63 | 64 | <view class="state-title">亲爱的客户,您的服务正在处理中</view> |
64 | 65 | <view class="state-time">{{filters.format_time(return_goods.handle_time,1)}}</view> |
65 | 66 | <view class="state-user">操作人:卖家</view> |
... | ... | @@ -70,8 +71,19 @@ |
70 | 71 | <view class="state-user">操作人:卖家</view> |
71 | 72 | </view> |
72 | 73 | <view class="item-wrap" wx:if="{{return_goods.status==3}}"> |
73 | - <view class="state-title">亲爱的客户,商家已经拒绝退款</view> | |
74 | - <view class="state-user">操作人:卖家</view> | |
74 | + <block wx:if="{{fil.is_cancle(return_goods.remark)}}"> | |
75 | + <view class="state-title">亲爱的客户,你已取消退款</view> | |
76 | + <view class="state-user" >操作人:客户</view> | |
77 | + </block> | |
78 | + <block wx:else> | |
79 | + <view class="state-title">亲爱的客户,商家已经拒绝退款</view> | |
80 | + <view class="state-user" >操作人:卖家</view> | |
81 | + </block> | |
75 | 82 | </view> |
76 | 83 | </view> |
84 | + | |
85 | + <view bindtap='cancelReturn' wx:if="{{return_goods.status==0 || return_goods.status==1}}" class="btn-wrap"> | |
86 | + <view class="submit-btn">取消退款</view> | |
87 | + </view> | |
88 | + | |
77 | 89 | </view> | ... | ... |
pages/user/return_goods_info/return_goods_info.wxss
... | ... | @@ -143,3 +143,17 @@ |
143 | 143 | .state-time { |
144 | 144 | padding-bottom: 20rpx; |
145 | 145 | } |
146 | + | |
147 | +.btn-wrap { | |
148 | + padding: 20rpx 0; | |
149 | +} | |
150 | +.submit-btn { | |
151 | + width: 320rpx; | |
152 | + height: 80rpx; | |
153 | + line-height: 80rpx; | |
154 | + text-align: center; | |
155 | + background-color: #f15353; | |
156 | + color: #fff; | |
157 | + margin: auto; | |
158 | +} | |
159 | +.cred{color: #f15353} | |
146 | 160 | \ No newline at end of file | ... | ... |
pages/user/return_goods_list/return_goods_list.js
... | ... | @@ -92,16 +92,28 @@ Page({ |
92 | 92 | }); |
93 | 93 | }, |
94 | 94 | cancelReturn: function(t) { |
95 | - var e = this, s = t.currentTarget.dataset.id; | |
95 | + var e = this, | |
96 | + s = t.currentTarget.dataset.id; | |
96 | 97 | wx.showModal({ |
97 | 98 | title: "确定取消售后服务?", |
98 | 99 | success: function(t) { |
99 | - t.confirm && r.post("/api/order/return_goods_cancel", { | |
100 | + t.confirm && r.put("/api/weshop/order/returngoods/update", { | |
100 | 101 | data: { |
101 | - id: s | |
102 | + id: s, | |
103 | + store_id:os.stoid, | |
104 | + status:3, | |
105 | + remark:'客户取消' | |
102 | 106 | }, |
103 | 107 | success: function(t) { |
104 | - e.resetData(), e.requestReturnGoods(); | |
108 | + if(t.data.code==0){ | |
109 | + | |
110 | + getApp().showWarning('取消成功'); | |
111 | + setTimeout(function(){ | |
112 | + e.resetData(), e.requestReturnGoods(); | |
113 | + },1000); | |
114 | + } | |
115 | + | |
116 | + | |
105 | 117 | } |
106 | 118 | }); |
107 | 119 | } | ... | ... |
pages/user/return_goods_list/return_goods_list.wxml
1 | +<wxs module="fil" src="fil.wxs"></wxs> | |
1 | 2 | <view class="container"> |
2 | 3 | <view class="return-box" wx:for="{{list}}" wx:key="{{index}}"> |
3 | 4 | <view class="item"> |
... | ... | @@ -7,7 +8,8 @@ |
7 | 8 | <block wx:if="{{item.status==0}}">已申请成功,待售后审核中</block> |
8 | 9 | <block wx:elif="{{item.status==1}}">处理中</block> |
9 | 10 | <block wx:elif="{{item.status==2}}">退款完成</block> |
10 | - <block wx:elif="{{item.status==3}}">卖家已经拒绝退款</block> | |
11 | + <block wx:elif="{{item.status==3}}">{{fil.set_word(item.remark)}}</block> | |
12 | + | |
11 | 13 | <image class="wh100 arrow" src="{{iurl}}/miniapp/images/icon-arrowdown.png"></image> |
12 | 14 | </navigator> |
13 | 15 | <view class="item return-goods" wx:for="{{item.goodslist}}" wx:for-item="goods"> |
... | ... | @@ -19,7 +21,7 @@ |
19 | 21 | </view> |
20 | 22 | <navigator class="return-btn" url="/pages/user/return_goods_info/return_goods_info?id={{item.id}}">进度查询</navigator> |
21 | 23 | <!-- <view bindtap="receiveOrder" class="return-btn" data-id="{{item.id}}" hidden="{{!(item.status==2&&item.type==1)}}">确认收货</view> --> |
22 | - <!-- <view bindtap="cancelReturn" class="return-btn" data-id="{{item.id}}" hidden="{{!(item.status!=-2&&item.status<1)}}">取消申请</view> --> | |
24 | + <view bindtap="cancelReturn" class="return-btn" data-id="{{item.id}}" wx:if="{{item.status<=1}}">取消申请</view> | |
23 | 25 | </view> |
24 | 26 | <view class="no-data" wx:if="{{!list||list.length==0}}"> |
25 | 27 | <image class="cart-image" src="{{iurl}}/miniapp/images/cart-null.png"></image> | ... | ... |