feat: link deposits to bill payment
This commit is contained in:
@@ -33,6 +33,9 @@ export class Bill {
|
||||
@Column({ name: 'total_amount', type: 'decimal', precision: 10, scale: 2, default: 0 })
|
||||
totalAmount: number;
|
||||
|
||||
@Column({ name: 'deposit_deducted_amount', type: 'decimal', precision: 10, scale: 2, default: 0 })
|
||||
depositDeductedAmount: number;
|
||||
|
||||
@Column({ type: 'varchar', length: 20, default: 'draft' })
|
||||
status: string;
|
||||
|
||||
|
||||
@@ -21,7 +21,7 @@ export class Deposit {
|
||||
@Column({ type: 'decimal', precision: 10, scale: 2, default: 500 })
|
||||
amount: number;
|
||||
|
||||
// paid: 已缴 | refunded: 已退 | deducted: 已扣除(部分或全部)
|
||||
// paid: 有可用余额 | refunded: 余额已全部退还 | depleted: 余额已被账单扣完
|
||||
@Column({ type: 'varchar', length: 20, default: 'paid' })
|
||||
status: string;
|
||||
|
||||
@@ -43,8 +43,8 @@ export class Deposit {
|
||||
@Column({ type: 'text', nullable: true })
|
||||
notes: string;
|
||||
|
||||
@Column({ name: 'recorded_by', nullable: true })
|
||||
recordedBy: number;
|
||||
@Column({ name: 'recorded_by', type: 'integer', nullable: true })
|
||||
recordedBy: number | null;
|
||||
|
||||
@Column({ name: 'refunded_by', type: 'integer', nullable: true })
|
||||
refundedBy: number | null;
|
||||
|
||||
Reference in New Issue
Block a user