Skip to content

Commit

Permalink
update timestamp to bigint in the DB
Browse files Browse the repository at this point in the history
  • Loading branch information
ae2079 committed Nov 25, 2024
1 parent 3d2839d commit 46996f6
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
import { MigrationInterface, QueryRunner } from 'typeorm';

export class AddScoreTimestampToUser1732494017630
export class AddScoreTimestampToUser1732495066795
implements MigrationInterface
{
name = 'AddScoreTimestampToUser1732494017630';
name = 'AddScoreTimestampToUser1732495066795';

public async up(queryRunner: QueryRunner): Promise<void> {
await queryRunner.query(
`ALTER TABLE "user" ADD "passportScoreUpdateTimestamp" integer`,
`ALTER TABLE "user" ADD "passportScoreUpdateTimestamp" bigint`,
);
}

Expand Down
4 changes: 2 additions & 2 deletions src/entities/user.ts
Original file line number Diff line number Diff line change
Expand Up @@ -117,8 +117,8 @@ export class User extends BaseEntity {
@Column({ type: 'real', nullable: true, default: null })
passportScore?: number;

@Field(_type => Number, { nullable: true })
@Column({ nullable: true, default: null })
@Field(_type => BigInt, { nullable: true })
@Column('bigint', { nullable: true, default: null })
passportScoreUpdateTimestamp?: number;

@Field(_type => Number, { nullable: true })
Expand Down

0 comments on commit 46996f6

Please sign in to comment.