bugfix on message
This commit is contained in:
parent
55b608a6b8
commit
17628aab7b
2 changed files with 7 additions and 2 deletions
|
@ -29,7 +29,10 @@ Notification.newInstance = properties => {
|
|||
},
|
||||
component: notification,
|
||||
destroy () {
|
||||
document.body.removeChild(document.getElementsByClassName('ivu-message')[0].parentElement);
|
||||
notification.closeAll();
|
||||
setTimeout(function() {
|
||||
document.body.removeChild(document.getElementsByClassName('ivu-message')[0].parentElement);
|
||||
}, 500);
|
||||
}
|
||||
};
|
||||
};
|
||||
|
|
|
@ -81,13 +81,15 @@
|
|||
},
|
||||
close (name) {
|
||||
const notices = this.notices;
|
||||
|
||||
for (let i = 0; i < notices.length; i++) {
|
||||
if (notices[i].name === name) {
|
||||
this.notices.splice(i, 1);
|
||||
break;
|
||||
}
|
||||
}
|
||||
},
|
||||
closeAll () {
|
||||
this.notices = [];
|
||||
}
|
||||
}
|
||||
};
|
||||
|
|
Loading…
Add table
Reference in a new issue