Add invoice void with ledger reversal, required reason, and voided badge
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -432,7 +432,8 @@ export const invoiceStatusEnum = pgEnum('invoice_status', [
|
||||
'sent',
|
||||
'paid',
|
||||
'overdue',
|
||||
'cancelled'
|
||||
'cancelled',
|
||||
'voided'
|
||||
]);
|
||||
|
||||
export const invoices = pgTable(
|
||||
@@ -460,6 +461,8 @@ export const invoices = pgTable(
|
||||
}),
|
||||
notes: text('notes'),
|
||||
pdfPath: text('pdf_path'),
|
||||
voidedAt: timestamp('voided_at', { withTimezone: true }),
|
||||
voidReason: text('void_reason'),
|
||||
createdAt: timestamp('created_at', { withTimezone: true }).notNull().defaultNow(),
|
||||
updatedAt: timestamp('updated_at', { withTimezone: true }).notNull().defaultNow()
|
||||
},
|
||||
@@ -1199,6 +1202,7 @@ export const companyLogEventEnum = pgEnum('company_log_event', [
|
||||
'invoice_created',
|
||||
'invoice_sent',
|
||||
'invoice_paid',
|
||||
'invoice_voided',
|
||||
'integration_connected',
|
||||
'integration_disconnected',
|
||||
'transaction_matched',
|
||||
|
||||
Reference in New Issue
Block a user