diff --git a/packages/nc-gui/components/dlg/QuickImport.vue b/packages/nc-gui/components/dlg/QuickImport.vue index 43b7d9d5f0..6d98a74341 100644 --- a/packages/nc-gui/components/dlg/QuickImport.vue +++ b/packages/nc-gui/components/dlg/QuickImport.vue @@ -172,7 +172,9 @@ const disablePreImportButton = computed(() => { } }) -const disableImportButton = computed(() => !templateEditorRef.value?.isValid) +const isError = ref(false) + +const disableImportButton = computed(() => !templateEditorRef.value?.isValid || isError.value) const disableFormatJsonButton = computed(() => !jsonEditorRef.value?.isValid) @@ -530,6 +532,14 @@ async function parseAndExtractData(val: UploadFile[] | ArrayBuffer | string) { preImportLoading.value = false } } + +const onError = () => { + isError.value = true +} + +const onChange = () => { + isError.value = false +}