update 待审批数量不可小于0
This commit is contained in:
@@ -164,7 +164,8 @@ const getApproveNum = async () => {
|
|||||||
approveNum.value = res.data.total;
|
approveNum.value = res.data.total;
|
||||||
};
|
};
|
||||||
mittBus.on('updateApproveNum', (value) => {
|
mittBus.on('updateApproveNum', (value) => {
|
||||||
approveNum.value = Number(approveNum.value) + Number(value);
|
const res = Number(approveNum.value) + Number(value);
|
||||||
|
approveNum.value = res < 0 ? 0 : res;
|
||||||
});
|
});
|
||||||
// 定时刷新
|
// 定时刷新
|
||||||
const timer = setInterval(() => {
|
const timer = setInterval(() => {
|
||||||
|
|||||||
Reference in New Issue
Block a user