Commit e5e06030c1b08933b0a43e81a42382e5b72f6108
1 parent
7bb4edae
预售的优化
Showing
2 changed files
with
5 additions
and
4 deletions
packageC/pages/presell/cart/cart.js
| @@ -1917,7 +1917,7 @@ Page({ | @@ -1917,7 +1917,7 @@ Page({ | ||
| 1917 | var back_data = null; | 1917 | var back_data = null; |
| 1918 | 1918 | ||
| 1919 | //-- 判断是不是包邮 -- | 1919 | //-- 判断是不是包邮 -- |
| 1920 | - if (this.data.pre_arr.is_post_temp && (!prom_ord || !prom_ord.is_ord_prom_post)) { | 1920 | + if (this.data.act.is_post_temp && (!prom_ord || prom_ord.is_post_temp)) { |
| 1921 | 1921 | ||
| 1922 | await getApp().request.promisePost("/api/weshop/order/areaFreight", { | 1922 | await getApp().request.promisePost("/api/weshop/order/areaFreight", { |
| 1923 | is_json: 1, data: req_d | 1923 | is_json: 1, data: req_d |
| @@ -2104,6 +2104,7 @@ Page({ | @@ -2104,6 +2104,7 @@ Page({ | ||
| 2104 | //如果同意参与订单优惠 | 2104 | //如果同意参与订单优惠 |
| 2105 | if (ord_prom) { | 2105 | if (ord_prom) { |
| 2106 | //th.check_is_order_prom(o_condition,async function (ord_price) { | 2106 | //th.check_is_order_prom(o_condition,async function (ord_price) { |
| 2107 | + var ord_price=o_condition; | ||
| 2107 | var bn_pick = th.data.pickup.pickup_id | 2108 | var bn_pick = th.data.pickup.pickup_id |
| 2108 | var order_prom_amount = 0; | 2109 | var order_prom_amount = 0; |
| 2109 | var order_prom_id = 0; | 2110 | var order_prom_id = 0; |
packageC/pages/presell/cart/cart2.js
| @@ -931,7 +931,7 @@ Page({ | @@ -931,7 +931,7 @@ Page({ | ||
| 931 | 931 | ||
| 932 | var order_prom_txt1 = "formData.order_prom_id"; | 932 | var order_prom_txt1 = "formData.order_prom_id"; |
| 933 | var order_prom_txt2 = "formData.order_prom_amount"; | 933 | var order_prom_txt2 = "formData.order_prom_amount"; |
| 934 | - th.setData({ [order_prom_txt1]: 0, [order_prom_txt2]: 0 }) | 934 | + th.setData({ [order_prom_txt1]: order_prom_id, [order_prom_txt2]: order_prom_amount }) |
| 935 | 935 | ||
| 936 | 936 | ||
| 937 | //判断是否同城配送,而且没有调用过 | 937 | //判断是否同城配送,而且没有调用过 |
| @@ -1133,12 +1133,12 @@ Page({ | @@ -1133,12 +1133,12 @@ Page({ | ||
| 1133 | 1133 | ||
| 1134 | var order_prom_list = {}; | 1134 | var order_prom_list = {}; |
| 1135 | //--判断有没有优惠活动-- | 1135 | //--判断有没有优惠活动-- |
| 1136 | - if (th.data.order_prom[item.pickup_id]) { | 1136 | + //if (th.data.order_prom[item.pickup_id]) { |
| 1137 | if (th.data.formData.order_prom_amount > 0) { | 1137 | if (th.data.formData.order_prom_amount > 0) { |
| 1138 | order_prom_list.order_prom_id = th.data.formData.order_prom_id; | 1138 | order_prom_list.order_prom_id = th.data.formData.order_prom_id; |
| 1139 | order_prom_list.order_prom_amount = th.data.formData.order_prom_amount; | 1139 | order_prom_list.order_prom_amount = th.data.formData.order_prom_amount; |
| 1140 | } | 1140 | } |
| 1141 | - } | 1141 | + //} |
| 1142 | 1142 | ||
| 1143 | //--判断优惠活动的提交-- | 1143 | //--判断优惠活动的提交-- |
| 1144 | if (th.data.formData.cut_price > 0) { | 1144 | if (th.data.formData.cut_price > 0) { |