添加注释

This commit is contained in:
wangsongsole 2022-06-17 15:48:11 +08:00
parent 677191c586
commit b5ac3c6d75
2 changed files with 26 additions and 21 deletions

View File

@ -29,6 +29,24 @@ export default ({ data, onChangeMoney }) => {
Notify.success('加款成功') Notify.success('加款成功')
setIsCount(true) setIsCount(true)
setTimeout(() => { setTimeout(() => {
setOrigin()
onChangeMoney(false, Number(stateData.addNew))
}, 1000)
},
(err) => {
Notify.error(err)
}
)
}
)
} else {
Notify.error('加款失败,加款后总充值批次金额不允许大于总预算')
}
}
}
//
function setOrigin() {
const newData = _.cloneDeep(stateData) const newData = _.cloneDeep(stateData)
newData.recharge_amount = ( newData.recharge_amount = (
Number(stateData.addNew) + Number(stateData.recharge_amount) Number(stateData.addNew) + Number(stateData.recharge_amount)
@ -49,20 +67,6 @@ export default ({ data, onChangeMoney }) => {
} }
sessionStorage.setItem('addMoneyData', JSON.stringify(origin)) sessionStorage.setItem('addMoneyData', JSON.stringify(origin))
onChangeMoney(false, Number(stateData.addNew))
}, 1000)
},
(err) => {
Notify.error(err)
}
)
}
)
} else {
Notify.error('加款失败,加款后总充值批次金额不允许大于总预算')
}
}
} }
return ( return (

View File

@ -311,6 +311,7 @@ export default class exchangedit extends React.Component {
} }
} }
// 立减金 加款后 商品范围列表数据进行变动
getTableList() { getTableList() {
if (sessionStorage.getItem('addMoneyData')) { if (sessionStorage.getItem('addMoneyData')) {
const addMoneyData = JSON.parse(sessionStorage.getItem('addMoneyData')) const addMoneyData = JSON.parse(sessionStorage.getItem('addMoneyData'))