mirror of
https://github.com/SyncrowIOT/backend.git
synced 2025-11-26 08:54:54 +00:00
make spaceType nullable false
This commit is contained in:
@ -12,11 +12,6 @@ export class SpaceEntity extends AbstractEntity<SpaceDto> {
|
|||||||
})
|
})
|
||||||
public uuid: string;
|
public uuid: string;
|
||||||
|
|
||||||
@Column({
|
|
||||||
nullable: false,
|
|
||||||
})
|
|
||||||
parentUuid: string;
|
|
||||||
|
|
||||||
@Column({
|
@Column({
|
||||||
nullable: false,
|
nullable: false,
|
||||||
})
|
})
|
||||||
@ -26,7 +21,9 @@ export class SpaceEntity extends AbstractEntity<SpaceDto> {
|
|||||||
|
|
||||||
@OneToMany(() => SpaceEntity, (space) => space.parent)
|
@OneToMany(() => SpaceEntity, (space) => space.parent)
|
||||||
children: SpaceEntity[];
|
children: SpaceEntity[];
|
||||||
@ManyToOne(() => SpaceTypeEntity, (spaceType) => spaceType.spaces)
|
@ManyToOne(() => SpaceTypeEntity, (spaceType) => spaceType.spaces, {
|
||||||
|
nullable: false,
|
||||||
|
})
|
||||||
spaceType: SpaceTypeEntity;
|
spaceType: SpaceTypeEntity;
|
||||||
|
|
||||||
constructor(partial: Partial<SpaceEntity>) {
|
constructor(partial: Partial<SpaceEntity>) {
|
||||||
|
|||||||
Reference in New Issue
Block a user