From c3e8cf92bd748f4b7ce1e7e5cd264e6ace7165d8 Mon Sep 17 00:00:00 2001 From: Sony Surahmn Date: Wed, 31 Dec 2025 16:43:50 +0700 Subject: [PATCH] Add FinanceBankAccount entity and update schema exports --- src/entity/finance/finance_bank_account.ts | 77 ++++++++++++++++++++++ src/schema/finances.ts | 1 + 2 files changed, 78 insertions(+) create mode 100644 src/entity/finance/finance_bank_account.ts diff --git a/src/entity/finance/finance_bank_account.ts b/src/entity/finance/finance_bank_account.ts new file mode 100644 index 0000000..ea2f0da --- /dev/null +++ b/src/entity/finance/finance_bank_account.ts @@ -0,0 +1,77 @@ +import { Entity, PrimaryGeneratedColumn, Column, OneToMany, PrimaryColumn, CreateDateColumn, UpdateDateColumn, DeleteDateColumn } from "typeorm"; +import { Status } from "../../types/status"; + +@Entity("finance_bank_account", { schema: "finances" }) +export class FinanceBankAccount { + @PrimaryGeneratedColumn("uuid") + id: string; + + @Column({ + nullable: false, + unique: false, + length: 64, + }) + code: string; + + @Column({ + nullable: false, + unique: false, + length: 255, + }) + bank: string; + + @Column({ + nullable: false, + unique: false, + length: 255, + }) + bank_acc_number: string; + + @Column({ + nullable: false, + unique: false, + length: 255, + }) + bank_acc_name: string; + + @Column({ + nullable: true, + unique: false, + length: 255, + }) + iban_swift_code: string; + + @Column({ + nullable: true, + unique: false, + length: 255, + }) + description: string; + + @Column({ + nullable: false, + length: 64, + }) + status: Status; + + @Column() + @CreateDateColumn() + created_at: Date; + + @Column({ nullable: true, length: 256 }) + created_by: string; + + @Column({ nullable: true }) + @UpdateDateColumn() + updated_at: Date; + + @Column({ nullable: true, length: 256 }) + updated_by: string; + + @Column({ nullable: true }) + @DeleteDateColumn() + deleted_at: Date; + + @Column({ nullable: true, length: 256 }) + deleted_by: string; +} diff --git a/src/schema/finances.ts b/src/schema/finances.ts index 1f78516..6809625 100644 --- a/src/schema/finances.ts +++ b/src/schema/finances.ts @@ -2,3 +2,4 @@ export * from "../entity/finance/finance_funding_sources"; export * from "../entity/finance/finance_agencia"; export * from "../entity/finance/finance_atividade"; export * from "../entity/finance/finance_company"; +export * from "../entity/finance/finance_bank_account";