fix: delete reload

This commit is contained in:
xingyu 2022-11-29 19:53:19 +08:00
parent cf4d1be55d
commit 1570e38792

View File

@ -196,16 +196,12 @@ export const useVxeGrid = <T = any>(config?: UseVxeGridConfig<T>) => {
} }
await nextTick() await nextTick()
return new Promise(async () => { return new Promise(async () => {
message message.delConfirm().then(async () => {
.delConfirm() await (config?.deleteApi && config?.deleteApi(ids))
.then(() => { message.success(t('common.delSuccess'))
config?.deleteApi && config?.deleteApi(ids) // 刷新列表
message.success(t('common.delSuccess')) ref.value.commitProxy('query')
}) })
.finally(async () => {
// 刷新列表
ref.value.commitProxy('query')
})
}) })
} }
/** /**