Implements full Phase 1 of the activeblue_familylaw Odoo 18 module: - 17 Python models (fl.case, fl.party, fl.child, fl.support.calculation, fl.fee.waiver, fl.income.withholding, fl.deadline, fl.hearing, fl.deposition, fl.discovery, fl.document, fl.caselaw, fl.analysis, fl.ai.engine, fl.argument, fl.statute, fl.issue.tag) + hr.expense extension - 3 wizard stubs (intake, analysis, generate-packet) - Security: 4 groups (admin/paralegal/portal-petitioner/portal-respondent) + record rules scoping portal users to their own cases - Seed data: issue tags, FL statutes, FL DCF support schedule, ir.sequence - 13 backend view XML files with FL 61.30 worksheet, fee waiver eligibility banner, DV safety resources, emancipation alerts - Static CSS/JS stubs for Phase 6 portal Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
53 lines
2.1 KiB
Python
53 lines
2.1 KiB
Python
from odoo import fields, models
|
|
|
|
|
|
class FlDocument(models.Model):
|
|
"""
|
|
Phase 4 — Full implementation with QWeb report generation.
|
|
Phase 1: Stub with core fields.
|
|
"""
|
|
_name = 'fl.document'
|
|
_description = 'Case Document'
|
|
_inherit = ['mail.thread']
|
|
_order = 'create_date desc'
|
|
|
|
case_id = fields.Many2one(
|
|
'fl.case', required=True, ondelete='cascade', index=True
|
|
)
|
|
name = fields.Char(string='Document Name', required=True)
|
|
document_type = fields.Selection([
|
|
('financial_affidavit_short', 'Financial Affidavit Short (FL-12.902(b))'),
|
|
('financial_affidavit_long', 'Financial Affidavit Long (FL-12.902(c))'),
|
|
('support_worksheet', 'Child Support Worksheet (FL-12.902(e))'),
|
|
('motion_to_modify', 'Motion to Modify Child Support'),
|
|
('notice_deposition', 'Notice of Taking Deposition'),
|
|
('motion_to_compel', 'Motion to Compel (FL 1.380)'),
|
|
('motion_default', 'Motion for Default (FL 12.922)'),
|
|
('income_withholding', 'Income Withholding Order (FL 61.1301)'),
|
|
('parenting_plan', 'Parenting Plan (FL-12.995(a))'),
|
|
('fee_waiver', 'Application for Civil Indigent Status (FL 57.082)'),
|
|
('notice_ssn', 'Notice of SSN (FL-12.930(a))'),
|
|
('mandatory_disclosure', 'Certificate of Mandatory Disclosure (FL-12.932)'),
|
|
('duces_tecum', 'Subpoena Duces Tecum'),
|
|
('other', 'Other Document'),
|
|
], string='Document Type')
|
|
state = fields.Selection([
|
|
('draft', 'Draft'),
|
|
('generated', 'Generated'),
|
|
('signed', 'Signed'),
|
|
('filed', 'Filed with Court'),
|
|
], string='Status', default='draft', tracking=True)
|
|
attachment_ids = fields.Many2many(
|
|
'ir.attachment',
|
|
'fl_document_attachment_rel',
|
|
'document_id', 'attachment_id',
|
|
string='Files'
|
|
)
|
|
notes = fields.Text(string='Notes')
|
|
requires_notarization = fields.Boolean(
|
|
string='Requires Notarization',
|
|
help='Financial affidavits must be notarized before filing'
|
|
)
|
|
notarized = fields.Boolean(string='Notarized')
|
|
filed_date = fields.Date(string='Filed with Court Date')
|