|
@@ -148,10 +148,10 @@ Page({
|
|
// it.active = !it.active
|
|
// it.active = !it.active
|
|
if(it.active){
|
|
if(it.active){
|
|
it.active = false
|
|
it.active = false
|
|
- that.setData({total_price: (parseFloat(that.data.total_price) + parseFloat((it.price.start_time && it.price.end_time)?it.price.sale_price*it.stock:it.price.price*it.stock)).toFixed(2)})
|
|
|
|
|
|
+ that.setData({total_price: (parseFloat(that.data.total_price) - parseFloat((it.price.start_time && it.price.end_time)?it.price.sale_price*it.stock:it.price.price*it.stock)).toFixed(2)})
|
|
}else{
|
|
}else{
|
|
it.active = true
|
|
it.active = true
|
|
- that.setData({total_price: (parseFloat(that.data.total_price) - parseFloat((it.price.start_time && it.price.end_time)?it.price.sale_price*it.stock:it.price.price*it.stock)).toFixed(2)})
|
|
|
|
|
|
+ that.setData({total_price: (parseFloat(that.data.total_price) + parseFloat((it.price.start_time && it.price.end_time)?it.price.sale_price*it.stock:it.price.price*it.stock)).toFixed(2)})
|
|
}
|
|
}
|
|
}
|
|
}
|
|
})
|
|
})
|