Fix types
This commit is contained in:
parent
95d3238d1e
commit
83bc2e17db
|
@ -73,7 +73,7 @@ export const deriveStores = (context: StoreContext): DerivedDatasourceStore => {
|
||||||
const schema = derived(definition, $definition => {
|
const schema = derived(definition, $definition => {
|
||||||
const schema: Record<string, any> | null | undefined = getDatasourceSchema({
|
const schema: Record<string, any> | null | undefined = getDatasourceSchema({
|
||||||
API,
|
API,
|
||||||
datasource: get(datasource),
|
datasource: get(datasource) as any,
|
||||||
definition: $definition ?? undefined,
|
definition: $definition ?? undefined,
|
||||||
})
|
})
|
||||||
if (!schema) {
|
if (!schema) {
|
||||||
|
@ -184,7 +184,7 @@ export const createActions = (context: StoreContext): ActionDatasourceStore => {
|
||||||
const refreshDefinition = async () => {
|
const refreshDefinition = async () => {
|
||||||
const def = await getDatasourceDefinition({
|
const def = await getDatasourceDefinition({
|
||||||
API,
|
API,
|
||||||
datasource: get(datasource),
|
datasource: get(datasource) as any,
|
||||||
})
|
})
|
||||||
definition.set((def as any) ?? null)
|
definition.set((def as any) ?? null)
|
||||||
}
|
}
|
||||||
|
|
|
@ -254,7 +254,7 @@ export const createActions = (context: StoreContext): RowActionStore => {
|
||||||
|
|
||||||
// Reset state properties when dataset changes
|
// Reset state properties when dataset changes
|
||||||
if (!$instanceLoaded || resetRows) {
|
if (!$instanceLoaded || resetRows) {
|
||||||
definition.set($fetch.definition)
|
definition.set($fetch.definition as any)
|
||||||
}
|
}
|
||||||
|
|
||||||
// Reset scroll state when data changes
|
// Reset scroll state when data changes
|
||||||
|
|
Loading…
Reference in New Issue