build: update plugins

This commit is contained in:
kailong321200875
2022-03-13 10:31:42 +08:00
parent 1456fd49ec
commit 0b525c8750
9 changed files with 404 additions and 375 deletions

View File

@@ -129,23 +129,24 @@ const loading = ref(false)
const save = async () => {
const write = unref(writeRef)
const validate = await write?.elFormRef?.validate()?.catch(() => {})
if (validate) {
loading.value = true
const data = (await write?.getFormData()) as TableData
const res = await saveTableApi({
data
})
.catch(() => {})
.finally(() => {
loading.value = false
await write?.elFormRef?.validate(async (isValid) => {
if (isValid) {
loading.value = true
const data = (await write?.getFormData()) as TableData
const res = await saveTableApi({
data
})
if (res) {
dialogVisible.value = false
tableObject.currentPage = 1
getList()
.catch(() => {})
.finally(() => {
loading.value = false
})
if (res) {
dialogVisible.value = false
tableObject.currentPage = 1
getList()
}
}
}
})
}
</script>