This commit is contained in:
Adria Navarro 2024-08-21 17:43:31 +02:00
parent 3405484977
commit e8f33e5fd8
2 changed files with 6 additions and 14 deletions

View File

@ -25,16 +25,13 @@ interface BaseRelationshipFieldMetadata
tableId: string tableId: string
tableRev?: string tableRev?: string
subtype?: AutoFieldSubType.CREATED_BY | AutoFieldSubType.UPDATED_BY subtype?: AutoFieldSubType.CREATED_BY | AutoFieldSubType.UPDATED_BY
schema?: RelationFieldSchema schema?: Record<string, RelationSchemaField>
} }
export type RelationFieldSchema = Record< export type RelationSchemaField = {
string,
{
visible?: boolean visible?: boolean
readonly?: boolean readonly?: boolean
} }
>
// External tables use junction tables, internal tables don't require them // External tables use junction tables, internal tables don't require them
type ManyToManyJunctionTableMetadata = type ManyToManyJunctionTableMetadata =

View File

@ -1,5 +1,5 @@
import { SearchFilter, SortOrder, SortType } from "../../api" import { SearchFilter, SortOrder, SortType } from "../../api"
import { UIFieldMetadata } from "./table" import { RelationSchemaField, UIFieldMetadata } from "./table"
import { Document } from "../document" import { Document } from "../document"
import { DBView } from "../../sdk" import { DBView } from "../../sdk"
@ -33,11 +33,6 @@ export interface View {
groupBy?: string groupBy?: string
} }
export type RelationSchemaField = {
visible?: boolean
readonly?: boolean
}
export type ViewFieldMetadata = UIFieldMetadata & { export type ViewFieldMetadata = UIFieldMetadata & {
readonly?: boolean readonly?: boolean
schema?: Record<string, RelationSchemaField> schema?: Record<string, RelationSchemaField>