Merge pull request #7213 from Budibase/fix/executequery-datasources
fixing wrong filter, excluding just bb_internal
This commit is contained in:
commit
39a33290d2
|
@ -3,7 +3,7 @@
|
|||
import { datasources, integrations, queries } from "stores/backend"
|
||||
import BindingBuilder from "components/integration/QueryBindingBuilder.svelte"
|
||||
import IntegrationQueryEditor from "components/integration/index.svelte"
|
||||
import { IntegrationTypes } from "constants/backend"
|
||||
import { BUDIBASE_DATASOURCE_ID } from "constants/backend"
|
||||
|
||||
export let parameters
|
||||
export let bindings = []
|
||||
|
@ -12,11 +12,9 @@
|
|||
$: datasource = $datasources.list.find(
|
||||
ds => ds._id === parameters.datasourceId
|
||||
)
|
||||
// Executequery action just works on PostgreSQL and MongoDB datasources
|
||||
// Executequery must exclude budibase datasource
|
||||
$: executeQueryDatasources = $datasources.list.filter(
|
||||
x =>
|
||||
x.source === IntegrationTypes.POSTGRES ||
|
||||
x.source === IntegrationTypes.MONGODB
|
||||
x => x._id !== BUDIBASE_DATASOURCE_ID
|
||||
)
|
||||
|
||||
function fetchQueryDefinition(query) {
|
||||
|
|
|
@ -163,6 +163,8 @@ export const SWITCHABLE_TYPES = [
|
|||
...ALLOWABLE_NUMBER_TYPES,
|
||||
]
|
||||
|
||||
export const BUDIBASE_DATASOURCE_ID = "bb_internal"
|
||||
|
||||
export const IntegrationTypes = {
|
||||
POSTGRES: "POSTGRES",
|
||||
MONGODB: "MONGODB",
|
||||
|
|
Loading…
Reference in New Issue