reset totp
This commit is contained in:
parent
48a8d1fb45
commit
fa1eb6a5f0
14 changed files with 354 additions and 83 deletions
24
src/migrations/1732358596823-resetToken.ts
Normal file
24
src/migrations/1732358596823-resetToken.ts
Normal file
|
@ -0,0 +1,24 @@
|
|||
import { MigrationInterface, QueryRunner, Table } from "typeorm";
|
||||
|
||||
export class ResetToken1732358596823 implements MigrationInterface {
|
||||
name = "ResetToken1732358596823";
|
||||
|
||||
public async up(queryRunner: QueryRunner): Promise<void> {
|
||||
await queryRunner.createTable(
|
||||
new Table({
|
||||
name: "reset",
|
||||
columns: [
|
||||
{ name: "mail", type: "varchar", length: "255", isPrimary: true, isNullable: false },
|
||||
{ name: "token", type: "varchar", length: "255", isNullable: false },
|
||||
{ name: "username", type: "varchar", length: "255", isNullable: false },
|
||||
{ name: "secret", type: "varchar", length: "255", isNullable: false },
|
||||
],
|
||||
}),
|
||||
true
|
||||
);
|
||||
}
|
||||
|
||||
public async down(queryRunner: QueryRunner): Promise<void> {
|
||||
await queryRunner.dropTable("reset");
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue