chore: normalize the payment and payment transaction

This commit is contained in:
mahyargdz
2025-02-06 13:08:51 +03:30
parent f3f47a80a1
commit e216937dd9
23 changed files with 547 additions and 90 deletions
@@ -0,0 +1,17 @@
import { Column, Entity, ManyToOne } from "typeorm";
import { BankAccount } from "./bank-account.entity";
import { BaseEntity } from "../../../common/entities/base.entity";
import { User } from "../../users/entities/user.entity";
@Entity()
export class DepositRequest extends BaseEntity {
@ManyToOne(() => BankAccount, (bankAccount) => bankAccount.depositRequests, { nullable: false, onDelete: "RESTRICT" })
bankAccount: BankAccount;
@ManyToOne(() => User, { nullable: false, onDelete: "RESTRICT" })
user: User;
@Column({ type: "varchar", length: 250, nullable: false })
receiptUrl: string;
}