This commit is contained in:
2026-04-14 14:22:04 +03:30
parent 510fbea3b1
commit eca144a6c6
19 changed files with 317 additions and 23 deletions
@@ -0,0 +1,20 @@
import Decimal from "decimal.js";
import { Column, Entity, ManyToOne } from "typeorm";
import { BaseEntity } from "../../../common/entities/base.entity";
import { DecimalTransformer } from "../../../common/transformers/decimal.transformer";
import { User } from "../../users/entities/user.entity";
@Entity()
export class RewardWithdrawRequest extends BaseEntity {
@ManyToOne(() => User, (user) => user.referralRewards)
user: User;
@Column({ type: "decimal", precision: 10, scale: 2, nullable: true, transformer: new DecimalTransformer() })
requestedAmount?: Decimal;
@Column({ type: "timestamp", nullable: true })
paidAt: Date;
@Column({ type: "varchar", length: 255, nullable: true })
transactionId?: string;
}