From 552005e2a482e95e36cd37579b75fc5a1a13d8b2 Mon Sep 17 00:00:00 2001 From: Ulf Gebhardt Date: Sat, 5 Mar 2022 12:43:44 +0100 Subject: [PATCH] fixed database error --- database/entity/0028-decimal_types/Transaction.ts | 4 ++-- database/entity/0029-clean_transaction_table/Transaction.ts | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/database/entity/0028-decimal_types/Transaction.ts b/database/entity/0028-decimal_types/Transaction.ts index e53508c61..9352e6335 100644 --- a/database/entity/0028-decimal_types/Transaction.ts +++ b/database/entity/0028-decimal_types/Transaction.ts @@ -10,8 +10,8 @@ export class Transaction extends BaseEntity { @Column({ name: 'user_id', unsigned: true, nullable: false }) userId: number - @Column({ unsigned: true, nullable: true, default: null }) - previous: number + @Column({ type: 'int', unsigned: true, nullable: true, default: null }) + previous: number | null @Column({ name: 'type_id', unsigned: true, nullable: false }) typeId: number diff --git a/database/entity/0029-clean_transaction_table/Transaction.ts b/database/entity/0029-clean_transaction_table/Transaction.ts index 1212d62ce..5931c153f 100644 --- a/database/entity/0029-clean_transaction_table/Transaction.ts +++ b/database/entity/0029-clean_transaction_table/Transaction.ts @@ -10,7 +10,7 @@ export class Transaction extends BaseEntity { @Column({ name: 'user_id', unsigned: true, nullable: false }) userId: number - @Column({ unsigned: true, nullable: true, default: null }) + @Column({ type: 'int', unsigned: true, nullable: true, default: null }) previous: number | null @Column({ name: 'type_id', unsigned: true, nullable: false })