xiaoe_mp_npm 0.5.44-test5 → 0.5.44-test6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -24,17 +24,21 @@ Component({
24
24
  originalPrice: data?.original_price,
25
25
  goodsPrice: data?.goods_price
26
26
  })
27
- // if(!this.data.setCoupon) {
28
- // console.log('this.data.chooseCouponList',this.data.chooseCouponList)
29
- // let chooseCouponList = this.changeCouponId(this.data.chooseCouponList)
30
- // this.setPricingInfoFirst(chooseCouponList, this.data.usedPromoCode)
31
- // this.setData({
32
- // setCoupon: true
33
- // })
34
- // }
35
- console.log('this.data.chooseCouponList',this.data.chooseCouponList)
36
- let chooseCouponList = this.changeCouponId(this.data.chooseCouponList)
37
- this.setPricingInfo(chooseCouponList, this.data.usedPromoCode);
27
+ if(!this.data.setCoupon) {
28
+ console.log('this.data.chooseCouponList',this.data.chooseCouponList)
29
+ let chooseCouponList = this.changeCouponId(this.data.chooseCouponList)
30
+ this.setPricingInfoFirst(chooseCouponList, this.data.usedPromoCode)
31
+ this.setData({
32
+ setCoupon: true
33
+ })
34
+ }
35
+ }
36
+ },
37
+ 'usedPromoCode, couponList': function(new1,new2) {
38
+ console.log('new1,new2',new1,new2)
39
+ if(new1 || new2){
40
+ let chooseCouponList = this.changeCouponId(this.data.couponList)
41
+ this.setPricingInfo(chooseCouponList, this.data.usedPromoCode)
38
42
  }
39
43
  },
40
44
  },
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "xiaoe_mp_npm",
3
- "version": "0.5.44-test5",
3
+ "version": "0.5.44-test6",
4
4
  "description": "",
5
5
  "main": "miniprogram_dist/index.js",
6
6
  "scripts": {
@@ -24,17 +24,21 @@ Component({
24
24
  originalPrice: data?.original_price,
25
25
  goodsPrice: data?.goods_price
26
26
  })
27
- // if(!this.data.setCoupon) {
28
- // console.log('this.data.chooseCouponList',this.data.chooseCouponList)
29
- // let chooseCouponList = this.changeCouponId(this.data.chooseCouponList)
30
- // this.setPricingInfoFirst(chooseCouponList, this.data.usedPromoCode)
31
- // this.setData({
32
- // setCoupon: true
33
- // })
34
- // }
35
- console.log('this.data.chooseCouponList',this.data.chooseCouponList)
36
- let chooseCouponList = this.changeCouponId(this.data.chooseCouponList)
37
- this.setPricingInfo(chooseCouponList, this.data.usedPromoCode);
27
+ if(!this.data.setCoupon) {
28
+ console.log('this.data.chooseCouponList',this.data.chooseCouponList)
29
+ let chooseCouponList = this.changeCouponId(this.data.chooseCouponList)
30
+ this.setPricingInfoFirst(chooseCouponList, this.data.usedPromoCode)
31
+ this.setData({
32
+ setCoupon: true
33
+ })
34
+ }
35
+ }
36
+ },
37
+ 'usedPromoCode, couponList': function(new1,new2) {
38
+ console.log('new1,new2',new1,new2)
39
+ if(new1 || new2){
40
+ let chooseCouponList = this.changeCouponId(this.data.couponList)
41
+ this.setPricingInfo(chooseCouponList, this.data.usedPromoCode)
38
42
  }
39
43
  },
40
44
  },