Commit b131abf821dfbd174feb693daf8b6b8e551a24eb
Merge branch 'dev' of http://git.vipzhuang.cn/wxd/MShopWeApp into dev
Showing
2 changed files
with
36 additions
and
23 deletions
pages/order/refund_order/refund_order.js
| ... | ... | @@ -12,28 +12,32 @@ Page({ |
| 12 | 12 | order_sn:"", |
| 13 | 13 | back_money: 0, |
| 14 | 14 | reasonSelect: 0, |
| 15 | - reasonList: [ "订单不能按预计时间送达", "操作有误(商品、地址等选错)", "重复下单/误下单", "其他渠道价格更低", "该商品降价了", "不想买了", "其他原因" ] | |
| 15 | + reasonList: [ "订单不能按预计时间送达", "操作有误(商品、地址等选错)", "重复下单/误下单", "其他渠道价格更低", "该商品降价了", "不想买了", "其他原因" ], | |
| 16 | + return_type:0, | |
| 16 | 17 | }, |
| 17 | 18 | onLoad: function(t) { |
| 18 | - var th = this; | |
| 19 | - e.getUserInfo(function(e) { | |
| 20 | - console.log('onload'); | |
| 21 | - console.log(e); | |
| 22 | - th.setData({ | |
| 23 | - orderId: t.order_id, | |
| 24 | - user: e | |
| 25 | - }), | |
| 26 | - rq.get("/api/weshop/order/get/" + os.stoid + "/" + t.order_id,{ | |
| 27 | - success:function(ed){ | |
| 28 | - var bm = ed.data.data.order_amount + ed.data.data.user_money | |
| 29 | - + ed.data.data.pt_tail_money | |
| 30 | - th.setData({ | |
| 31 | - order_sn: ed.data.data.order_sn, | |
| 32 | - back_money: bm | |
| 33 | - }) | |
| 34 | - } | |
| 35 | - }) | |
| 36 | - }); | |
| 19 | + var th=this; | |
| 20 | + getApp().getConfig2(function (em) { | |
| 21 | + th.data.return_type = em.return_type; | |
| 22 | + e.getUserInfo(function(e) { | |
| 23 | + console.log('onload'); | |
| 24 | + console.log(e); | |
| 25 | + th.setData({ | |
| 26 | + orderId: t.order_id, | |
| 27 | + user: e, | |
| 28 | + }), | |
| 29 | + rq.get("/api/weshop/order/get/" + os.stoid + "/" + t.order_id,{ | |
| 30 | + success:function(ed){ | |
| 31 | + var bm = ed.data.data.order_amount + ed.data.data.user_money | |
| 32 | + + ed.data.data.pt_tail_money | |
| 33 | + th.setData({ | |
| 34 | + order_sn: ed.data.data.order_sn, | |
| 35 | + back_money: bm | |
| 36 | + }) | |
| 37 | + } | |
| 38 | + }) | |
| 39 | + }); | |
| 40 | + }) | |
| 37 | 41 | }, |
| 38 | 42 | |
| 39 | 43 | //------提交退款申请------- |
| ... | ... | @@ -63,6 +67,7 @@ Page({ |
| 63 | 67 | goods_id_list: glist, |
| 64 | 68 | addtime: ut.gettimestamp(), |
| 65 | 69 | type:2, |
| 70 | + return_type: th.data.return_type, | |
| 66 | 71 | }, |
| 67 | 72 | success: function (e) { |
| 68 | 73 | wx.showToast({ | ... | ... |
pages/user/return_goods/return_goods.js
| ... | ... | @@ -21,18 +21,25 @@ Page({ |
| 21 | 21 | causeList: [ "订单不能按预计时间送达", "操作有误(商品、地址等选错)", "重复下单/误下单", "其他渠道价格更低", "该商品降价了", "不想买了" ], |
| 22 | 22 | checkCauseIndex: -1, |
| 23 | 23 | popState: !0, |
| 24 | - description: "" | |
| 24 | + description: "", | |
| 25 | + return_type:0, | |
| 25 | 26 | }, |
| 26 | 27 | onLoad: function(e) { |
| 27 | 28 | var a = this; |
| 29 | + | |
| 30 | + getApp().getConfig2(function (em) { | |
| 31 | + a.data.return_type = em.return_type; | |
| 32 | + }); | |
| 33 | + | |
| 28 | 34 | this.setData({ |
| 29 | 35 | recId: e.rec_id |
| 30 | 36 | }), this.requestReturnGoods(e), t.getConfig(function(t) { |
| 31 | 37 | a.setData({ |
| 32 | - "config.address": t.store_address, | |
| 33 | - "config.phone": t.store_tel, | |
| 38 | + "config.address": t.store_address, | |
| 39 | + "config.phone": t.store_tel, | |
| 34 | 40 | }); |
| 35 | 41 | }); |
| 42 | + | |
| 36 | 43 | }, |
| 37 | 44 | requestReturnGoods: function(t) { |
| 38 | 45 | var e = this; |
| ... | ... | @@ -147,6 +154,7 @@ Page({ |
| 147 | 154 | goods_id: th.data.order.goods_id, |
| 148 | 155 | addtime: ut.gettimestamp(), |
| 149 | 156 | type:2, |
| 157 | + return_type: th.data.return_type, | |
| 150 | 158 | }, |
| 151 | 159 | success: function(t) { |
| 152 | 160 | wx.showToast({ | ... | ... |