Jun 29 - Update: Fail2ban, welcome email, dunning sequence, escalation

This commit is contained in:
2026-06-29 13:47:57 -04:00
parent c133b5d419
commit b00bbba2da
14 changed files with 414 additions and 1 deletions
@@ -0,0 +1,43 @@
{% extends "billing/email/base.html" %}
{% set subject = "Final Notice: Your JQC account will be cancelled soon" %}
{% block body %}
<h2 style="margin:0 0 8px;font-size:1.2rem;color:#b91c1c;">Final Notice — Action Required</h2>
<p style="margin:0 0 20px;color:#6b7280;font-size:.9rem;">
Your JQC subscription payment has been outstanding for 14 days.
Your account will be <strong>cancelled within 24 hours</strong> if payment is not received.
</p>
<table width="100%" cellpadding="12" cellspacing="0" style="background:#fef2f2;border-radius:6px;margin-bottom:24px;border:1px solid #fca5a5;">
<tr>
<td>
<p style="margin:0;font-size:.9rem;color:#7f1d1d;line-height:1.6;">
<strong>&#10007; Account cancellation is imminent.</strong><br>
Update your payment method now to prevent losing access to all your inspection data,
reports, and workspace.
</p>
</td>
</tr>
</table>
<table width="100%" cellpadding="0" cellspacing="0" style="margin-bottom:24px;">
<tr>
<td align="center">
<a href="{{ portal_url }}"
style="display:inline-block;background:#dc2626;color:#fff;text-decoration:none;
padding:14px 32px;border-radius:6px;font-size:1rem;font-weight:700;
letter-spacing:.02em;">
Pay Now — Keep My Account
</a>
</td>
</tr>
</table>
<p style="margin:0 0 12px;font-size:.85rem;color:#374151;line-height:1.6;">
Once cancelled, your workspace data is retained for 30 days before permanent deletion.
You can reactivate during this window by contacting support.
</p>
<p style="margin:0;font-size:.85rem;color:#9ca3af;">
Questions? Contact us at <a href="mailto:support@jqc.app" style="color:#1a56db;">support@jqc.app</a>.
</p>
{% endblock %}
@@ -0,0 +1,37 @@
{% extends "billing/email/base.html" %}
{% set subject = "Reminder: Payment still needed for your JQC subscription" %}
{% block body %}
<h2 style="margin:0 0 8px;font-size:1.2rem;color:#111827;">Payment reminder</h2>
<p style="margin:0 0 20px;color:#6b7280;font-size:.9rem;">
Your JQC subscription payment is still outstanding. Please update your payment
method to restore full access to your workspace.
</p>
<table width="100%" cellpadding="12" cellspacing="0" style="background:#fefce8;border-radius:6px;margin-bottom:24px;border:1px solid #fde68a;">
<tr>
<td>
<p style="margin:0;font-size:.9rem;color:#92400e;line-height:1.6;">
<strong>&#9888; Your workspace access is limited</strong> until payment is received.
Update your payment method to remove this restriction.
</p>
</td>
</tr>
</table>
<table width="100%" cellpadding="0" cellspacing="0" style="margin-bottom:24px;">
<tr>
<td align="center">
<a href="{{ portal_url }}"
style="display:inline-block;background:#1a56db;color:#fff;text-decoration:none;
padding:12px 28px;border-radius:6px;font-size:.95rem;font-weight:600;">
Update Payment Method
</a>
</td>
</tr>
</table>
<p style="margin:0;font-size:.85rem;color:#9ca3af;">
If you have any questions, reply to this email or contact
<a href="mailto:support@jqc.app" style="color:#1a56db;">support@jqc.app</a>.
</p>
{% endblock %}
+45
View File
@@ -0,0 +1,45 @@
{% extends "billing/email/base.html" %}
{% set subject = "Welcome to JQC — your workspace is ready" %}
{% block body %}
<h2 style="margin:0 0 8px;font-size:1.2rem;color:#111827;">Welcome to Janitorial QC!</h2>
<p style="margin:0 0 20px;color:#6b7280;font-size:.9rem;">Your workspace <strong>{{ tenant_name }}</strong> is ready. You're on a free trial — no credit card needed until {{ trial_ends_at }}.</p>
<table width="100%" cellpadding="12" cellspacing="0" style="background:#f0fdf4;border-radius:6px;margin-bottom:24px;">
<tr>
<td>
<p style="margin:0;font-size:.9rem;color:#15803d;line-height:1.6;">
<strong>&#10003; Workspace:</strong> <a href="{{ login_url }}" style="color:#15803d;">{{ login_url }}</a><br>
<strong>&#10003; Free trial:</strong> {{ trial_days }} days (expires {{ trial_ends_at }})<br>
<strong>&#10003; Plan:</strong> {{ plan_name }}
</p>
</td>
</tr>
</table>
<p style="margin:0 0 16px;font-size:.9rem;color:#374151;line-height:1.6;">
Here's what you can do right now:
</p>
<ul style="margin:0 0 24px;padding-left:1.25rem;font-size:.9rem;color:#374151;line-height:1.8;">
<li>Add your facilities and areas</li>
<li>Create inspection templates</li>
<li>Invite your team members</li>
<li>Run your first inspection</li>
</ul>
<table width="100%" cellpadding="0" cellspacing="0" style="margin-bottom:24px;">
<tr>
<td align="center">
<a href="{{ login_url }}"
style="display:inline-block;background:#1a56db;color:#fff;text-decoration:none;
padding:12px 28px;border-radius:6px;font-size:.95rem;font-weight:600;">
Go to My Workspace
</a>
</td>
</tr>
</table>
<p style="margin:0;font-size:.85rem;color:#9ca3af;">
Your login URL: <a href="{{ login_url }}" style="color:#1a56db;word-break:break-all;">{{ login_url }}</a><br>
Need help? Reply to this email or visit <a href="mailto:support@jqc.app" style="color:#1a56db;">support@jqc.app</a>.
</p>
{% endblock %}