Add TCPA-compliant SMS consent tracking for prospect quotes

- Quote entity: ProspectSmsConsent (bool) + ProspectSmsConsentedAt (DateTime?) fields
- QuoteDtos: consent fields on Create/Update/Convert DTOs with TCPA guidance text
- Quote Create/Edit views: SMS consent checkbox shown when mobile number is entered
- Quote ConvertToCustomer view: staff must re-confirm consent carries over to customer record
- QuoteApproval: consent state exposed in ViewModel and ApprovalPage for transparency
- Consent timestamp cleared when prospect quote is linked to an existing customer
- Migration: AddProspectSmsConsent

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-05-08 20:47:04 -04:00
parent fb979bc88d
commit f40d58ac2e
10 changed files with 9776 additions and 3 deletions
@@ -207,6 +207,47 @@
</div>
</div>
<!-- SMS Notifications -->
<div class="card mb-4 border-info">
<div class="card-header bg-info bg-opacity-10">
<h5 class="mb-0">
<i class="bi bi-phone me-2"></i>SMS Notifications
</h5>
</div>
<div class="card-body">
<input type="hidden" asp-for="ProspectSmsConsentedAt" />
@if (Model.SmsConsent)
{
<div class="alert alert-success alert-permanent mb-3 py-2">
<i class="bi bi-check-circle me-1"></i>
<strong>SMS consent was recorded on the quote</strong>
@if (Model.ProspectSmsConsentedAt.HasValue)
{
<span>on @Model.ProspectSmsConsentedAt.Value.ToLocalTime().ToString("MM/dd/yyyy")</span>
}
</div>
}
else
{
<div class="alert alert-warning alert-permanent mb-3 py-2">
<i class="bi bi-exclamation-triangle me-1"></i>
<strong>No SMS consent was recorded on the quote.</strong>
</div>
}
<div class="form-check">
<input asp-for="SmsConsent" class="form-check-input" id="SmsConsent" />
<label class="form-check-label fw-semibold" for="SmsConsent">
Customer has given verbal consent to receive SMS notifications
</label>
</div>
<small class="text-muted d-block mt-1">
<i class="bi bi-shield-check me-1"></i>
Only check if the customer has explicitly agreed to receive text messages (TCPA compliance).
If checked, the new customer record will have SMS enabled and a confirmation text will be sent.
</small>
</div>
</div>
<!-- Form Actions -->
<div class="mb-4">
<button type="submit" class="btn btn-success btn-lg">