|
@@ -521,15 +521,18 @@ const deselectTimePrice = () => {
|
|
|
|
|
|
//可调量失去焦点
|
|
|
const changeTotalBlur = (row) => {
|
|
|
- const { meterTotal, changeTotal } = deepClone(row)
|
|
|
- console.log(meterTotal, changeTotal, new BigNumber(changeTotal).comparedTo(new BigNumber(meterTotal)))
|
|
|
+ const { meterTotal, changeTotal, adjustFactor } = deepClone(row)
|
|
|
if (!isNumberReg(changeTotal)) {
|
|
|
row.changeTotal = meterTotal
|
|
|
window.$message.warning('请输入正确的可调量')
|
|
|
+ return
|
|
|
} else if (new BigNumber(changeTotal).comparedTo(new BigNumber(meterTotal)) === 1) {
|
|
|
row.changeTotal = meterTotal
|
|
|
window.$message.warning('只能小于等于计量数量')
|
|
|
+ return
|
|
|
}
|
|
|
+ //调差数量 = 可调量 * 调差系数
|
|
|
+ row.adjustTotal = new BigNumber(changeTotal).multipliedBy(adjustFactor).toString()
|
|
|
}
|
|
|
|
|
|
//上传附件
|