We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 5f49187 commit 3c46d46Copy full SHA for 3c46d46
frontend/src/views/ds/DatasourceForm.vue
@@ -341,16 +341,13 @@ const check = () => {
341
}
342
})
343
344
-
345
-const getSchema = () => {
+const getSchema = debounce(() => {
346
schemaList.value = []
347
const requestObj = buildConf()
348
datasourceApi.getSchema(requestObj).then((res: any) => {
349
- for (let item of res) {
350
- schemaList.value.push({ label: item, value: item })
351
- }
+ schemaList.value = (res || []).map((item: any) => ({ label: item, value: item }))
352
353
-}
+}, 300)
354
355
onBeforeUnmount(() => (saveLoading.value = false))
356
0 commit comments