From 5e792ab96f45dc33098cd915d020c7d0e4d86ec1 Mon Sep 17 00:00:00 2001 From: Andreas Knuth Date: Wed, 25 Mar 2026 18:01:45 -0500 Subject: [PATCH] click if sent --- public/js/views/invoice-view.js | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/public/js/views/invoice-view.js b/public/js/views/invoice-view.js index c4e505a..7409528 100644 --- a/public/js/views/invoice-view.js +++ b/public/js/views/invoice-view.js @@ -245,6 +245,12 @@ function renderInvoiceRow(invoice) { else if (daysUntil <= 3) sendDateDisplay += ` (in ${daysUntil}d)`; } } + + // Send Date cell — only clickable if actually sent + const sendDateClickable = sentDates.length > 0; + const sendDateCell = sendDateClickable + ? `${sendDateDisplay}` + : sendDateDisplay; // Amount column — show balance when partially paid let amountDisplay; @@ -302,9 +308,7 @@ function renderInvoiceRow(invoice) { ${invoice.customer_name || 'N/A'} ${formatDate(invoice.invoice_date)} - - ${sendDateDisplay} - + ${sendDateCell} ${invoice.terms} ${amountDisplay}