Add QuoteApprovedByCustomer notification type; fix wrong type logged on approval

QuoteDeclinedByCustomer was used for both approve and decline responses,
so approval notifications showed the wrong type in the log. Added a distinct
QuoteApprovedByCustomer = 16 enum value, wired up the correct type in
NotificationService, added default templates in both the service fallback
dictionary and SeedData, and updated placeholder hints in CompanySettings.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-05-06 17:13:34 -04:00
parent 4085ff7c73
commit d3863c713b
4 changed files with 39 additions and 4 deletions
@@ -2610,7 +2610,7 @@ public class CompanySettingsController : Controller
// Quote types
if (type is NotificationType.QuoteSent or NotificationType.QuoteApproved
or NotificationType.QuoteDeclinedByCustomer)
or NotificationType.QuoteApprovedByCustomer or NotificationType.QuoteDeclinedByCustomer)
list.Add(("{{quoteNumber}}", "Quote number (e.g. QT-2501-0001)"));
if (type == NotificationType.QuoteSent)
@@ -2620,9 +2620,13 @@ public class CompanySettingsController : Controller
list.Add(("{{approvalUrl}}", "Unique URL for the customer to view and approve the quote online"));
}
if (type == NotificationType.QuoteDeclinedByCustomer)
if (type is NotificationType.QuoteApprovedByCustomer or NotificationType.QuoteDeclinedByCustomer)
{
list.Add(("{{response}}", "Customer's response — either \"APPROVED\" or \"DECLINED\""));
}
if (type == NotificationType.QuoteDeclinedByCustomer)
{
list.Add(("{{declineReasonSection}}", "HTML block containing the decline reason — blank when the customer approved"));
}