update : invoice entity

This commit is contained in:
2026-02-02 15:21:23 +03:30
parent 00f96f6b33
commit b3f9457c78
2 changed files with 16 additions and 2 deletions
@@ -70,9 +70,9 @@ export class Invoice extends BaseEntity {
@Column({
type: 'enum',
enum: InvoicePurpose,
nullable: false,
nullable: true,
})
purpose: InvoicePurpose;
purpose?: InvoicePurpose;
get isOverdue(): boolean {
return this.status === InvoiceStatus.PENDING && new Date() > this.dueDate;