tabel OrgGroup

This commit is contained in:
AdisakKanthawilang 2024-01-24 17:22:41 +07:00
parent 688e94e26a
commit 0069c3f491
7 changed files with 71 additions and 37 deletions

View file

@ -12,7 +12,7 @@ enum OrgChild2Rank {
DIVISION = "division",
SECTION = "section",
}
@Entity("orgChild2")
export class OrgChild2 extends EntityBase {
// @Column({
// comment: "",
@ -100,9 +100,9 @@ export class OrgChild2 extends EntityBase {
})
fkOrgChild1Id: string;
@ManyToOne(() => OrgRoot, orgRoot => orgRoot.orgChild2s)
@JoinColumn({ name: "fkOrgRootId" })
orgRoot: OrgRoot;
// @ManyToOne(() => OrgRoot, orgRoot => orgRoot.orgChild2s)
// @JoinColumn({ name: "fkOrgRootId" })
// orgRoot: OrgRoot;
@ManyToOne(() => OrgChild1, orgChild1 => orgChild1.orgChild2s)
@JoinColumn({ name: "fkOrgChild1Id" })
@ -112,8 +112,8 @@ export class OrgChild2 extends EntityBase {
@OneToMany(() => OrgChild3, orgChild3 => orgChild3.orgChild2)
orgChild3s: OrgChild3[];
@OneToMany(() => OrgChild4, orgChild4 => orgChild4.orgChild2)
orgChild4s: OrgChild4[];
// @OneToMany(() => OrgChild4, orgChild4 => orgChild4.orgChild2)
// orgChild4s: OrgChild4[];
}
export type UpdateOrgChild2 = Partial<OrgChild2>;