แก้ไขสิทธิ์
This commit is contained in:
parent
4641362b95
commit
0024ed9414
9 changed files with 154 additions and 27 deletions
31
src/entities/CommandSendCC.ts
Normal file
31
src/entities/CommandSendCC.ts
Normal file
|
|
@ -0,0 +1,31 @@
|
|||
import { Entity, Column, JoinColumn, ManyToOne } from "typeorm";
|
||||
import { EntityBase } from "./base/Base";
|
||||
import { CommandSend } from "./CommandSend";
|
||||
|
||||
@Entity("commandSendCC")
|
||||
export class CommandSendCC extends EntityBase {
|
||||
@Column({
|
||||
nullable: true,
|
||||
comment: "เพศ",
|
||||
length: 255,
|
||||
default: null,
|
||||
})
|
||||
name: string;
|
||||
|
||||
@Column({
|
||||
length: 40,
|
||||
comment: "คีย์นอก(FK)ของตาราง commandSend",
|
||||
})
|
||||
commandSendId: string;
|
||||
|
||||
@ManyToOne(() => CommandSend, (commandSend) => commandSend.commandSendCCs)
|
||||
@JoinColumn({ name: "commandSendId" })
|
||||
commandSend: CommandSend;
|
||||
}
|
||||
|
||||
export class CreateCommandSendCC {
|
||||
@Column()
|
||||
name: string;
|
||||
}
|
||||
|
||||
export type UpdateCommandSendCC = Partial<CreateCommandSendCC>;
|
||||
Loading…
Add table
Add a link
Reference in a new issue