แก้ไขประเภทคำสั่ง

This commit is contained in:
kittapath 2024-09-11 18:13:48 +07:00
parent 057298cddd
commit d6d4fbf8cc
3 changed files with 145 additions and 4 deletions

View file

@ -28,6 +28,36 @@ export class CommandType extends EntityBase {
})
code: string;
@Column({
nullable: true,
comment: "เนื้อหาคำสั่งส่วนต้น",
type: "text",
default: null,
})
detailHeader: string;
@Column({
nullable: true,
comment: "เนื้อหาคำสั่งส่วนกลาง",
type: "text",
default: null,
})
detailBody: string;
@Column({
nullable: true,
comment: "เนื้อหาคำสั่งส่วนท้าย",
type: "text",
default: null,
})
detailFooter: string;
@Column({
comment: "สถานะการใช้งาน",
default: true,
})
isActive: boolean;
@OneToMany(() => Command, (command) => command.commandType)
commands: Command[];
}
@ -40,7 +70,7 @@ export class CreateCommandType {
type: string;
@Column()
code: string;
isActive: boolean;
}
export type UpdateCommandType = Partial<CreateCommandType>;