generated from HenriqueAmorim20/GEROcuidadoAPITemplate
-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #8 from fga-eps-mds/feature/#170-crud-idoso-backend
Feature/#170 crud idoso backend
- Loading branch information
Showing
9 changed files
with
66 additions
and
39 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
import { MigrationInterface, QueryRunner } from "typeorm"; | ||
|
||
export class AlterTableIdoso1699572747760 implements MigrationInterface { | ||
name = 'AlterTableIdoso1699572747760' | ||
|
||
public async up(queryRunner: QueryRunner): Promise<void> { | ||
await queryRunner.query(`ALTER TABLE "idoso" ALTER COLUMN "tipoSanguineo" DROP NOT NULL`); | ||
await queryRunner.query(`ALTER TABLE "idoso" ALTER COLUMN "descricao" DROP NOT NULL`); | ||
} | ||
|
||
public async down(queryRunner: QueryRunner): Promise<void> { | ||
await queryRunner.query(`ALTER TABLE "idoso" ALTER COLUMN "descricao" SET NOT NULL`); | ||
await queryRunner.query(`ALTER TABLE "idoso" ALTER COLUMN "tipoSanguineo" SET NOT NULL`); | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
import { MigrationInterface, QueryRunner } from "typeorm"; | ||
|
||
export class AddDataHoraTableIdoso1699904482169 implements MigrationInterface { | ||
name = 'AddDataHoraTableIdoso1699904482169' | ||
|
||
public async up(queryRunner: QueryRunner): Promise<void> { | ||
await queryRunner.query(`ALTER TABLE "idoso" ADD "dataHora" TIMESTAMP`); | ||
} | ||
|
||
public async down(queryRunner: QueryRunner): Promise<void> { | ||
await queryRunner.query(`ALTER TABLE "idoso" DROP COLUMN "dataHora"`); | ||
} | ||
|
||
} |