Browse Source

no message

feature/v1.1
xpz2018 5 years ago
parent
commit
980c44b559
2 changed files with 3 additions and 3 deletions
  1. 2
      app.js
  2. 4
      pages/process/order-price/index.js

2
app.js

@ -1,6 +1,6 @@
//app.js
App({
evn: 2, // 0: 开发版本;1:测试版本;2:生产版本
evn: 0, // 0: 开发版本;1:测试版本;2:生产版本
tmplIds: [''],
version: 152,
xAppId: '503258978847953926',

4
pages/process/order-price/index.js

@ -77,13 +77,13 @@ Page({
if(util.isEmpty(e.detail.value) || Number(e.detail.value) <= 0){
this.setData({ ['form.deductWeight']: null })
} else {
this.setData({ ['form.deductWeight']: math.divide(math.times(this.form.totalWeight, Number(e.detail.value)), 100).toFixed(3) })
this.setData({ ['form.deductWeight']: math.divide(math.times(this.data.form.totalWeight, Number(e.detail.value)), 100).toFixed(3) })
}
} else if(e.target.id == 'deductWeight'){
if(util.isEmpty(e.detail.value) || Number(e.detail.value) <= 0){
this.setData({ ['form.deductPercent']: null })
} else {
this.setData({ ['form.deductPercent']: math.times(math.divide(Number(e.detail.value), this.form.totalWeight), 100).toFixed(2) })
this.setData({ ['form.deductPercent']: math.times(math.divide(Number(e.detail.value), this.data.form.totalWeight), 100).toFixed(2) })
}
}
},

Loading…
Cancel
Save