เพิ่มฟิว orgPublishDate
This commit is contained in:
parent
5b5970cda2
commit
7cd4ae2b5f
2 changed files with 21 additions and 0 deletions
|
|
@ -32,6 +32,13 @@ export class OrgRevision extends EntityBase {
|
||||||
})
|
})
|
||||||
orgRevisionCreatedAt: Date;
|
orgRevisionCreatedAt: Date;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
type: "datetime",
|
||||||
|
comment: "เวลาเผยแพร่",
|
||||||
|
})
|
||||||
|
orgPublishDate: Date;
|
||||||
|
|
||||||
@Column({
|
@Column({
|
||||||
nullable: true,
|
nullable: true,
|
||||||
comment: "",
|
comment: "",
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,14 @@
|
||||||
|
import { MigrationInterface, QueryRunner } from "typeorm";
|
||||||
|
|
||||||
|
export class UpdateTableOrgRevisionAddOrgPublishDate1706511716494 implements MigrationInterface {
|
||||||
|
name = 'UpdateTableOrgRevisionAddOrgPublishDate1706511716494'
|
||||||
|
|
||||||
|
public async up(queryRunner: QueryRunner): Promise<void> {
|
||||||
|
await queryRunner.query(`ALTER TABLE \`orgRevision\` ADD \`orgPublishDate\` datetime NULL COMMENT 'เวลาเผยแพร่'`);
|
||||||
|
}
|
||||||
|
|
||||||
|
public async down(queryRunner: QueryRunner): Promise<void> {
|
||||||
|
await queryRunner.query(`ALTER TABLE \`orgRevision\` DROP COLUMN \`orgPublishDate\``);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
Loading…
Add table
Add a link
Reference in a new issue