|
|
@@ -32,8 +32,17 @@
|
|
|
}
|
|
|
},
|
|
|
onLoad(e) {
|
|
|
+ this.shop_id = uni.getStorageSync('shop_id')
|
|
|
+ if(this.shop_id == 299){
|
|
|
+ this.upData();
|
|
|
+ }
|
|
|
+
|
|
|
if(e.discount*1 > 0){
|
|
|
this.totalPrice = (((e.money*1)*(e.discount*1)*100).toFixed(2)/100).toFixed(2);
|
|
|
+ let num1 = e.money*1
|
|
|
+ let num2 = e.discount*1
|
|
|
+ this.totalPrice = (((num1*num2*10000)/100).toFixed(0)/100).toFixed(2)
|
|
|
+
|
|
|
}else{
|
|
|
this.totalPrice = e.money;
|
|
|
}
|
|
|
@@ -42,10 +51,7 @@
|
|
|
this.invite_code = e.invite_code;
|
|
|
this.discount = e.discount;
|
|
|
|
|
|
- this.shop_id = uni.getStorageSync('shop_id')
|
|
|
- if(this.shop_id == 299){
|
|
|
- this.upData();
|
|
|
- }
|
|
|
+
|
|
|
},
|
|
|
methods:{
|
|
|
buy(){
|