factory and restructure view models
This commit is contained in:
parent
fcbfe560c3
commit
117ced38ab
33 changed files with 479 additions and 46 deletions
|
@ -29,7 +29,7 @@ export class wearable {
|
|||
wearableTypeId: string;
|
||||
|
||||
@Column()
|
||||
wearerId: string;
|
||||
wearerId?: string;
|
||||
|
||||
@ManyToOne(() => wearableType, {
|
||||
nullable: false,
|
||||
|
@ -39,11 +39,11 @@ export class wearable {
|
|||
wearableType: wearableType;
|
||||
|
||||
@ManyToOne(() => member, {
|
||||
nullable: false,
|
||||
nullable: true,
|
||||
onDelete: "SET NULL",
|
||||
onUpdate: "RESTRICT",
|
||||
})
|
||||
wearer: member;
|
||||
wearer?: member;
|
||||
|
||||
@OneToMany(() => damageReport, (d) => d.wearable, { cascade: ["insert"] })
|
||||
reports: damageReport[];
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue