mirror of
https://gitee.com/vant-contrib/vant.git
synced 2025-04-06 03:57:59 +08:00
fix(Dialog): should reset loading when close (#4352)
This commit is contained in:
parent
beb4036572
commit
6a0bef37ca
@ -55,10 +55,12 @@ export default createComponent({
|
||||
if (this.beforeClose) {
|
||||
this.loading[action] = true;
|
||||
this.beforeClose(action, state => {
|
||||
if (state !== false) {
|
||||
if (state !== false && this.loading[action]) {
|
||||
this.onClose(action);
|
||||
}
|
||||
this.loading[action] = false;
|
||||
|
||||
this.loading.confirm = false;
|
||||
this.loading.cancel = false;
|
||||
});
|
||||
} else {
|
||||
this.onClose(action);
|
||||
|
Loading…
x
Reference in New Issue
Block a user