sync and create change
This commit is contained in:
parent
5f434c943e
commit
e1ad491e68
16 changed files with 285 additions and 39 deletions
101
src/migrations/1728999487170-protocolTableTypes.ts
Normal file
101
src/migrations/1728999487170-protocolTableTypes.ts
Normal file
|
@ -0,0 +1,101 @@
|
|||
import { MigrationInterface, QueryRunner, TableColumn } from "typeorm";
|
||||
|
||||
export class ProtocolTableTypes1728999487170 implements MigrationInterface {
|
||||
name = "ProtocolTableTypes1728999487170";
|
||||
|
||||
public async up(queryRunner: QueryRunner): Promise<void> {
|
||||
await queryRunner.changeColumn(
|
||||
"protocol",
|
||||
"summary",
|
||||
new TableColumn({
|
||||
name: "summary",
|
||||
type: "text",
|
||||
default: "''",
|
||||
isNullable: false,
|
||||
})
|
||||
);
|
||||
|
||||
await queryRunner.changeColumn(
|
||||
"protocol_agenda",
|
||||
"context",
|
||||
new TableColumn({
|
||||
name: "context",
|
||||
type: "text",
|
||||
default: "''",
|
||||
isNullable: false,
|
||||
})
|
||||
);
|
||||
|
||||
await queryRunner.changeColumn(
|
||||
"protocol_decision",
|
||||
"context",
|
||||
new TableColumn({
|
||||
name: "context",
|
||||
type: "text",
|
||||
default: "''",
|
||||
isNullable: false,
|
||||
})
|
||||
);
|
||||
|
||||
await queryRunner.changeColumn(
|
||||
"protocol_voting",
|
||||
"context",
|
||||
new TableColumn({
|
||||
name: "context",
|
||||
type: "text",
|
||||
default: "''",
|
||||
isNullable: false,
|
||||
})
|
||||
);
|
||||
}
|
||||
|
||||
public async down(queryRunner: QueryRunner): Promise<void> {
|
||||
await queryRunner.changeColumn(
|
||||
"protocol",
|
||||
"summary",
|
||||
new TableColumn({
|
||||
name: "summary",
|
||||
type: "varchar",
|
||||
length: "255",
|
||||
default: "''",
|
||||
isNullable: false,
|
||||
})
|
||||
);
|
||||
|
||||
await queryRunner.changeColumn(
|
||||
"protocol_agenda",
|
||||
"context",
|
||||
new TableColumn({
|
||||
name: "context",
|
||||
type: "varchar",
|
||||
length: "255",
|
||||
default: "''",
|
||||
isNullable: false,
|
||||
})
|
||||
);
|
||||
|
||||
await queryRunner.changeColumn(
|
||||
"protocol_decision",
|
||||
"context",
|
||||
new TableColumn({
|
||||
name: "context",
|
||||
type: "varchar",
|
||||
length: "255",
|
||||
default: "''",
|
||||
isNullable: false,
|
||||
})
|
||||
);
|
||||
|
||||
await queryRunner.changeColumn(
|
||||
"protocol_voting",
|
||||
"context",
|
||||
new TableColumn({
|
||||
name: "context",
|
||||
type: "varchar",
|
||||
length: "255",
|
||||
default: "''",
|
||||
isNullable: false,
|
||||
})
|
||||
);
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue