feat: expose foreign key (#2505)
* fix: typo * feat: expose foreign key * fix: foreign key exposition * fix: be able to filter by foreign key * feat: add `isSystem` on field metadata * feat: update all seeds * fix: seed issues * fix: sync metadata generated files * fix: squash metadata migrations * Fix conflicts --------- Co-authored-by: Charles Bochet <charles@twenty.com>
This commit is contained in:
@ -8,6 +8,7 @@ import {
|
||||
|
||||
import {
|
||||
Authorize,
|
||||
FilterableField,
|
||||
IDField,
|
||||
QueryOptions,
|
||||
Relation,
|
||||
@ -29,7 +30,6 @@ registerEnumType(FieldMetadataType, {
|
||||
})
|
||||
@QueryOptions({
|
||||
defaultResultSize: 10,
|
||||
disableFilter: true,
|
||||
disableSort: true,
|
||||
maxResultsSize: 1000,
|
||||
})
|
||||
@ -61,12 +61,15 @@ export class FieldMetadataDTO {
|
||||
@Field({ nullable: true, deprecationReason: 'Use label name instead' })
|
||||
placeholder?: string;
|
||||
|
||||
@Field()
|
||||
@FilterableField()
|
||||
isCustom: boolean;
|
||||
|
||||
@Field()
|
||||
@FilterableField()
|
||||
isActive: boolean;
|
||||
|
||||
@FilterableField()
|
||||
isSystem: boolean;
|
||||
|
||||
@Field()
|
||||
isNullable: boolean;
|
||||
|
||||
|
||||
@ -77,6 +77,9 @@ export class FieldMetadataEntity implements FieldMetadataInterface {
|
||||
@Column({ default: false })
|
||||
isActive: boolean;
|
||||
|
||||
@Column({ default: false })
|
||||
isSystem: boolean;
|
||||
|
||||
@Column({ nullable: true, default: true })
|
||||
isNullable: boolean;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user