Net 14
This commit is contained in:
@@ -229,11 +229,11 @@ function renderModalContent() {
|
||||
// Dynamischer Text für die Fälligkeit
|
||||
let paymentText = '';
|
||||
if (currentInvoice.terms && currentInvoice.terms.toLowerCase().includes('receipt')) {
|
||||
paymentText = 'Our terms are Net 30.';
|
||||
paymentText = 'Our terms are Net 14.';
|
||||
} else if (dueDateStr !== 'Upon Receipt') {
|
||||
paymentText = `payable by <strong>${dueDateStr}</strong>.`;
|
||||
} else {
|
||||
paymentText = 'Our terms are Net 30.';
|
||||
paymentText = 'Our terms are Net 14.';
|
||||
}
|
||||
|
||||
let defaultHtml = '';
|
||||
@@ -256,7 +256,7 @@ function renderModalContent() {
|
||||
// Standard template
|
||||
defaultHtml = `
|
||||
<p>Dear ${customerName},</p>
|
||||
<p>Attached is invoice <strong>#${invoiceNum}</strong> for service performed at your location. The total amount due is <strong>$${totalDue}</strong>, ${paymentText}</p>
|
||||
<p>Attached is invoice <strong>#${invoiceNum}</strong> for service performed at your location. The total amount due is <strong>$${totalDue}</strong>., ${paymentText}</p>
|
||||
<p>Please pay at your earliest convenience. We appreciate your continued business.</p>
|
||||
<p>If you have any questions about the invoice, feel free to reply to this email.</p>
|
||||
<p>Best regards,</p>
|
||||
|
||||
@@ -117,8 +117,8 @@ function getTermDays(inv) {
|
||||
return parseInt(match[1], 10);
|
||||
}
|
||||
|
||||
// Default in deiner App ist Net 30
|
||||
return 30;
|
||||
// Default in deiner App ist Net 14
|
||||
return 14;
|
||||
}
|
||||
|
||||
function addDays(dateValue, days) {
|
||||
@@ -150,7 +150,7 @@ function getEffectiveDueDate(inv) {
|
||||
|
||||
// WICHTIG:
|
||||
// Für Overdue zählt der erste tatsächliche Versand.
|
||||
// Bei Net 30 also first_sent_date + 30 Tage.
|
||||
// Bei Net 14 also first_sent_date + 30 Tage.
|
||||
return addDays(firstSentDate, getTermDays(inv));
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user