update database

This commit is contained in:
AdisakKanthawilang 2025-04-18 17:53:39 +07:00
parent 880ba36978
commit b782c76ccb
2 changed files with 51 additions and 0 deletions

View file

@ -0,0 +1,47 @@
import { Entity, Column, ManyToOne, JoinColumn, OneToOne } from "typeorm";
import { EntityBase } from "./base/Base";
import { Evaluation } from "./Evaluation";
@Entity("performance")
export class Performance extends EntityBase {
@Column({
comment: "Id การทำรายการระบบประเมิน",
length: 40,
default: "00000000-0000-0000-0000-000000000000",
})
evaluationId: string;
@Column({
nullable: true,
comment: "ปีที่ประเมิน",
default: null,
})
year: number;
@Column({
nullable: true,
comment: "ประเภทที่ร้องขอประเมิน",
default: null,
})
type: string;
@Column({
nullable: true,
comment: "ชื่อผลงาน",
default: null,
})
subject: string;
@Column({
nullable: true,
comment: "ผลการประเมิน",
default: null,
})
evaluationResult: string;
@ManyToOne(() => Evaluation, (Evaluation) => Evaluation.performances)
@JoinColumn({ name: "evaluationId" })
evaluation: Evaluation;
}
export type UpdatePerformance = Partial<Performance>;