Files
famlaw/activeblue_familylaw/data/mail_templates.xml
Carlos Garcia 7c865c8c22 Phase 2: Deadlines + Calendar integration
Full fl_deadline.py:
- Calendar event creation/update on every deadline (all-day events)
- _cron_check_default_judgment: FL 12.922 — if respondent misses Day 20
  answer deadline, auto-creates Motion for Default deadline (5 days),
  project task, and urgent chatter alert
- _cron_deadline_alerts: 7/3/1-day and overdue chatter alerts
- Complete service-anchored deadline set: response (Day 20), financial
  disclosure + mandatory disclosure cert (Day 45), discovery opens (Day 20),
  respondent parenting class (Day 60), 120-day service max
- context-flag pattern (_no_calendar_sync) to prevent recursive write loops

Full fl_hearing.py:
- Calendar event sync (show_as=busy, confidential)
- Pre-hearing checklist computed fields: parenting class (FL 61.21),
  discovery cutoff (hearing -30 days), financial disclosure status
- Workflow buttons: Mark Completed, Mark Continued, Cancel
- _create_hearing_deadline: creates fl.deadline record for each hearing

New data/fl_deadline_rules.xml:
- ir.cron: Daily Deadline Alerts (fl_deadline._cron_deadline_alerts)
- ir.cron: Default Judgment Check (fl_deadline._cron_check_default_judgment)
- ir.cron: Emancipation Alerts (fl_child._cron_emancipation_alerts)

New data/mail_templates.xml:
- Deadline Alert Upcoming (EN)
- Deadline Alert OVERDUE (EN)
- Portal Welcome (EN + ES bilingual)
- Default Judgment Window Alert (EN)

Enhanced views: deadline + hearing now have calendar view, search view
with filters (overdue, due this week, by type), and group-by options.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-04 23:16:24 -04:00

299 lines
18 KiB
XML

<?xml version="1.0" encoding="utf-8"?>
<odoo>
<data noupdate="1">
<!-- ══════════════════════════════════════════════════════
DEADLINE ALERT — UPCOMING (English)
══════════════════════════════════════════════════════ -->
<record id="mail_template_deadline_upcoming" model="mail.template">
<field name="name">FL: Deadline Alert — Upcoming</field>
<field name="model_id" ref="model_fl_deadline"/>
<field name="subject">⏰ Deadline Alert: ${object.name} — Due ${object.due_date}</field>
<field name="body_html"><![CDATA[
<div style="font-family: Arial, sans-serif; max-width: 600px; margin: 0 auto;">
<div style="background: #003366; color: #fff; padding: 16px; border-radius: 6px 6px 0 0;">
<h2 style="margin: 0;">⏰ Upcoming Deadline Alert</h2>
<p style="margin: 4px 0 0 0; font-size: 0.9em;">ActiveBlue Family Law Case Management</p>
</div>
<div style="padding: 20px; background: #f8f9fa; border: 1px solid #dee2e6;">
<p>You have an upcoming deadline on your family law case.</p>
<table style="width: 100%; border-collapse: collapse; margin: 16px 0;">
<tr>
<td style="padding: 8px; font-weight: bold; width: 40%;">Case:</td>
<td style="padding: 8px;">${object.case_id.name}</td>
</tr>
<tr style="background: #fff;">
<td style="padding: 8px; font-weight: bold;">Deadline:</td>
<td style="padding: 8px;">${object.name}</td>
</tr>
<tr>
<td style="padding: 8px; font-weight: bold;">Due Date:</td>
<td style="padding: 8px; color: #dc3545; font-weight: bold;">${object.due_date}</td>
</tr>
<tr style="background: #fff;">
<td style="padding: 8px; font-weight: bold;">Days Remaining:</td>
<td style="padding: 8px;">${object.days_until_due} days</td>
</tr>
<tr>
<td style="padding: 8px; font-weight: bold;">Statute:</td>
<td style="padding: 8px;">${object.statute_reference or 'N/A'}</td>
</tr>
</table>
% if object.notes:
<div style="background: #fff3cd; border: 1px solid #ffc107; padding: 12px; border-radius: 4px; margin-top: 12px;">
<strong>Notes:</strong> ${object.notes}
</div>
% endif
<div style="background: #d4edda; border: 1px solid #28a745; padding: 12px; border-radius: 4px; margin-top: 16px;">
<strong>Action Required:</strong> Please complete this deadline by the due date.
Missed deadlines in family law cases can result in default judgments
or dismissal of your case.
</div>
</div>
<div style="padding: 12px; background: #e9ecef; border-radius: 0 0 6px 6px; font-size: 0.8em; color: #6c757d;">
<strong>DISCLAIMER:</strong> This is an automated reminder from ActiveBlue Family Law
case management software. This is NOT legal advice. If you have questions about
this deadline, consult a licensed Florida family law attorney.<br/><br/>
Legal Services of Greater Miami: (305) 576-0080 |
Florida Courts Self-Help: <a href="https://www.flcourts.gov">flcourts.gov</a>
</div>
</div>
]]></field>
<field name="auto_delete" eval="True"/>
</record>
<!-- ══════════════════════════════════════════════════════
DEADLINE ALERT — OVERDUE (English)
══════════════════════════════════════════════════════ -->
<record id="mail_template_deadline_overdue" model="mail.template">
<field name="name">FL: Deadline Alert — OVERDUE</field>
<field name="model_id" ref="model_fl_deadline"/>
<field name="subject">🔴 OVERDUE DEADLINE: ${object.name} — Case ${object.case_id.name}</field>
<field name="body_html"><![CDATA[
<div style="font-family: Arial, sans-serif; max-width: 600px; margin: 0 auto;">
<div style="background: #dc3545; color: #fff; padding: 16px; border-radius: 6px 6px 0 0;">
<h2 style="margin: 0;">🔴 OVERDUE DEADLINE — URGENT ACTION REQUIRED</h2>
<p style="margin: 4px 0 0 0; font-size: 0.9em;">ActiveBlue Family Law Case Management</p>
</div>
<div style="padding: 20px; background: #f8d7da; border: 1px solid #f5c6cb;">
<p style="font-size: 1.1em; font-weight: bold; color: #721c24;">
A deadline on your family law case is PAST DUE. Immediate action may be required.
</p>
<table style="width: 100%; border-collapse: collapse; margin: 16px 0;">
<tr>
<td style="padding: 8px; font-weight: bold; width: 40%;">Case:</td>
<td style="padding: 8px;">${object.case_id.name}</td>
</tr>
<tr style="background: #fff;">
<td style="padding: 8px; font-weight: bold;">Deadline:</td>
<td style="padding: 8px; color: #dc3545; font-weight: bold;">${object.name}</td>
</tr>
<tr>
<td style="padding: 8px; font-weight: bold;">Was Due:</td>
<td style="padding: 8px; color: #dc3545; font-weight: bold;">${object.due_date}</td>
</tr>
<tr style="background: #fff;">
<td style="padding: 8px; font-weight: bold;">Statute:</td>
<td style="padding: 8px;">${object.statute_reference or 'N/A'}</td>
</tr>
</table>
<div style="background: #f8d7da; border: 2px solid #dc3545; padding: 16px; border-radius: 4px; margin-top: 12px;">
<strong>⚠️ WARNING:</strong> Missing court deadlines can result in:
<ul>
<li>Default judgment entered against you</li>
<li>Dismissal of your case</li>
<li>Contempt of court findings</li>
<li>Loss of your legal rights</li>
</ul>
Contact the court clerk immediately to understand your options.
</div>
</div>
<div style="padding: 12px; background: #e9ecef; border-radius: 0 0 6px 6px; font-size: 0.8em; color: #6c757d;">
<strong>DISCLAIMER:</strong> This is an automated alert. This is NOT legal advice.
Consult a licensed Florida family law attorney immediately regarding missed deadlines.<br/><br/>
<strong>Emergency Legal Help:</strong><br/>
Legal Services of Greater Miami: <strong>(305) 576-0080</strong><br/>
Florida Courts Self-Help: <a href="https://www.flcourts.gov">flcourts.gov</a><br/>
Miami-Dade Law Library: <a href="https://www.law.miami.edu/library">law.miami.edu/library</a>
</div>
</div>
]]></field>
<field name="auto_delete" eval="True"/>
</record>
<!-- ══════════════════════════════════════════════════════
PORTAL WELCOME EMAIL (English)
══════════════════════════════════════════════════════ -->
<record id="mail_template_portal_welcome" model="mail.template">
<field name="name">FL: Portal Welcome — New Case (EN)</field>
<field name="model_id" ref="model_fl_case"/>
<field name="subject">Welcome to Your Family Law Case Portal — Case ${object.name}</field>
<field name="body_html"><![CDATA[
<div style="font-family: Arial, sans-serif; max-width: 600px; margin: 0 auto;">
<div style="background: #003366; color: #fff; padding: 20px; border-radius: 6px 6px 0 0;">
<h2 style="margin: 0;">Welcome to Your Family Law Case Portal</h2>
<p style="margin: 8px 0 0 0;">ActiveBlue Family Law — Miami-Dade 11th Circuit</p>
</div>
<div style="padding: 24px; background: #fff; border: 1px solid #dee2e6;">
<p>Dear ${object.petitioner_id.name},</p>
<p>
Your family law case has been created in our system. You can now
track your case, deadlines, and documents through the portal.
</p>
<div style="background: #d4edda; border: 1px solid #28a745; padding: 16px; border-radius: 6px; margin: 16px 0;">
<strong>Your Case Reference:</strong>
<span style="font-size: 1.3em; font-weight: bold; color: #003366; display: block; margin-top: 4px;">
${object.name}
</span>
</div>
<table style="width: 100%; border-collapse: collapse; margin: 16px 0;">
<tr>
<td style="padding: 8px; font-weight: bold; width: 40%; background: #f8f9fa;">Case Type:</td>
<td style="padding: 8px;">${object.case_type}</td>
</tr>
% if object.filing_date:
<tr>
<td style="padding: 8px; font-weight: bold; background: #f8f9fa;">Filing Date:</td>
<td style="padding: 8px;">${object.filing_date}</td>
</tr>
% endif
</table>
<h3>What You Can Do in the Portal:</h3>
<ul>
<li>📋 View your case status and upcoming deadlines</li>
<li>📄 Download and generate court forms</li>
<li>💰 Use the FL 61.30 child support calculator</li>
<li>📅 Track the visual timeline of your case</li>
<li>💬 Communicate through the secure case messaging system</li>
</ul>
<div style="background: #fff3cd; border: 1px solid #ffc107; padding: 16px; border-radius: 6px; margin: 16px 0;">
<strong>⚠️ Important Reminder:</strong>
This system provides information and tools to assist you, but
<strong>does not provide legal advice</strong>. Family law matters
are complex. We strongly recommend consulting with a licensed
Florida family law attorney.
</div>
<h3>Free Legal Resources:</h3>
<ul>
<li>Legal Services of Greater Miami: <strong>(305) 576-0080</strong></li>
<li>Florida Courts Self-Help: <a href="https://www.flcourts.gov">flcourts.gov</a></li>
<li>Miami-Dade Bar Lawyer Referral: <strong>(305) 371-2444</strong></li>
<li>FL Courts e-Filing Portal: <a href="https://www.myflcourtaccess.com">myflcourtaccess.com</a></li>
</ul>
</div>
<div style="padding: 12px; background: #e9ecef; border-radius: 0 0 6px 6px; font-size: 0.8em; color: #6c757d;">
ActiveBlue Family Law Case Management — Miami-Dade County, Florida<br/>
<strong>DISCLAIMER:</strong> This software is not a substitute for legal advice.
Verify all information with the court before filing.
</div>
</div>
]]></field>
<field name="auto_delete" eval="True"/>
</record>
<!-- ══════════════════════════════════════════════════════
PORTAL WELCOME EMAIL (Spanish / Español)
══════════════════════════════════════════════════════ -->
<record id="mail_template_portal_welcome_es" model="mail.template">
<field name="name">FL: Portal Welcome — New Case (ES)</field>
<field name="model_id" ref="model_fl_case"/>
<field name="subject">Bienvenido a su Portal de Caso de Derecho Familiar — Caso ${object.name}</field>
<field name="body_html"><![CDATA[
<div style="font-family: Arial, sans-serif; max-width: 600px; margin: 0 auto;">
<div style="background: #003366; color: #fff; padding: 20px; border-radius: 6px 6px 0 0;">
<h2 style="margin: 0;">Bienvenido a su Portal de Caso de Derecho Familiar</h2>
<p style="margin: 8px 0 0 0;">ActiveBlue Family Law — Circuito 11 de Miami-Dade</p>
</div>
<div style="padding: 24px; background: #fff; border: 1px solid #dee2e6;">
<p>Estimado/a ${object.petitioner_id.name},</p>
<p>
Su caso de derecho familiar ha sido creado en nuestro sistema. Ahora puede
seguir su caso, plazos y documentos a través del portal.
</p>
<div style="background: #d4edda; border: 1px solid #28a745; padding: 16px; border-radius: 6px; margin: 16px 0;">
<strong>Número de Referencia de su Caso:</strong>
<span style="font-size: 1.3em; font-weight: bold; color: #003366; display: block; margin-top: 4px;">
${object.name}
</span>
</div>
<h3>¿Qué puede hacer en el Portal?</h3>
<ul>
<li>📋 Ver el estado de su caso y los próximos plazos</li>
<li>📄 Descargar y generar formularios del tribunal</li>
<li>💰 Usar la calculadora de manutención de hijos FL 61.30</li>
<li>📅 Ver el cronograma visual de su caso</li>
<li>💬 Comunicarse a través del sistema de mensajería segura</li>
</ul>
<div style="background: #fff3cd; border: 1px solid #ffc107; padding: 16px; border-radius: 6px; margin: 16px 0;">
<strong>⚠️ Aviso Importante:</strong>
Este sistema proporciona información y herramientas para ayudarle, pero
<strong>no proporciona asesoramiento legal</strong>. Los asuntos de derecho familiar
son complejos. Recomendamos consultar con un abogado certificado de Florida.
</div>
<h3>Recursos Legales Gratuitos:</h3>
<ul>
<li>Servicios Legales del Gran Miami: <strong>(305) 576-0080</strong></li>
<li>Autoayuda de los Tribunales de Florida: <a href="https://www.flcourts.gov">flcourts.gov</a></li>
<li>Colegio de Abogados de Miami-Dade — Referidos: <strong>(305) 371-2444</strong></li>
</ul>
</div>
<div style="padding: 12px; background: #e9ecef; border-radius: 0 0 6px 6px; font-size: 0.8em; color: #6c757d;">
ActiveBlue Family Law — Condado de Miami-Dade, Florida<br/>
<strong>AVISO LEGAL:</strong> Este software no reemplaza el asesoramiento legal.
Verifique toda la información con el tribunal antes de presentar documentos.
</div>
</div>
]]></field>
<field name="auto_delete" eval="True"/>
</record>
<!-- ══════════════════════════════════════════════════════
DEFAULT JUDGMENT ALERT (English)
══════════════════════════════════════════════════════ -->
<record id="mail_template_default_judgment" model="mail.template">
<field name="name">FL: Default Judgment Window Alert (FL 12.922)</field>
<field name="model_id" ref="model_fl_case"/>
<field name="subject">⚖️ ACTION REQUIRED: File Motion for Default — Case ${object.name}</field>
<field name="body_html"><![CDATA[
<div style="font-family: Arial, sans-serif; max-width: 600px; margin: 0 auto;">
<div style="background: #856404; color: #fff; padding: 20px; border-radius: 6px 6px 0 0;">
<h2 style="margin: 0;">⚖️ Default Judgment Window — Action Required</h2>
<p style="margin: 8px 0 0 0;">FL 12.922 — Motion for Default</p>
</div>
<div style="padding: 24px; background: #fff3cd; border: 1px solid #ffc107;">
<p>
The respondent in your case did not file an answer within the required
20-day window after service. You may now request a <strong>Clerk's Default</strong>.
</p>
<div style="background: #fff; border: 1px solid #dee2e6; padding: 16px; border-radius: 6px; margin: 16px 0;">
<strong>Case:</strong> ${object.name}<br/>
<strong>Petitioner:</strong> ${object.petitioner_id.name}<br/>
<strong>Respondent:</strong> ${object.respondent_id.name if object.respondent_id else 'N/A'}
</div>
<h3>Steps to Request a Default:</h3>
<ol>
<li>Download <strong>FL-12.922</strong> (Motion for Default) from the Florida Courts website</li>
<li>Complete the form with your case number from Miami-Dade Clerk</li>
<li>File at Miami-Dade Clerk's Office OR via the e-Filing portal</li>
<li>After the Clerk enters the default, file a <strong>Motion for Final Judgment</strong></li>
<li>Request a final hearing date from the court</li>
</ol>
<div style="background: #f8d7da; border: 1px solid #f5c6cb; padding: 12px; border-radius: 4px;">
<strong>⚠️ Note:</strong> A default does not automatically mean you win.
You must still present evidence at a final hearing.
The respondent may still contest the default by filing a motion to vacate.
</div>
</div>
<div style="padding: 12px; background: #e9ecef; border-radius: 0 0 6px 6px; font-size: 0.8em; color: #6c757d;">
<strong>DISCLAIMER:</strong> This is NOT legal advice. Consult a licensed
Florida family law attorney for guidance on default proceedings.<br/>
Legal Services of Greater Miami: <strong>(305) 576-0080</strong>
</div>
</div>
]]></field>
<field name="auto_delete" eval="True"/>
</record>
</data>
</odoo>