Files
Odoo-Modules/fusion_authorizer_portal/__manifest__.py
gsinghpal d07159b9b5 fusion_authorizer_portal: wire accessibility assessments into MOD/ODSP/WSIB workflows (v19.0.2.8.0)
Audit found that fusion.accessibility.assessment._create_draft_sale_order
hardcoded x_fc_sale_type='direct_private' for ALL accessibility cases —
meaning MOD, ODSP, WSIB, and insurance projects never entered their
respective downstream workflows. The MOD workflow rework I shipped in
fusion_claims 19.0.8.0.3 was effectively unreachable from the portal.

Also: x_fc_authorizer_id never propagated from the assessment to the SO,
the new x_fc_mod_accessibility_specialist_id was orphaned, and there
was no back-reference from sale.order to the accessibility assessment.

Fixes:
- New required field x_fc_funding_source on fusion.accessibility.assessment
  (march_of_dimes / odsp / wsib / insurance / direct_private / other)
- _create_draft_sale_order now maps funding_source -> x_fc_sale_type,
  copies authorizer_id -> x_fc_authorizer_id, sets accessibility_assessment_id
  back-ref, and for MOD cases pre-populates
  x_fc_mod_accessibility_specialist_id from sales_rep_id.partner_id
- New accessibility_assessment_id field on sale.order so the back-link
  is queryable both directions (previously only assessment->SO existed)
- action_complete now guards against double-completion and missing
  funding_source: raises UserError instead of silently creating duplicates
- Expanded fusion.accessibility.assessment.state from 3 to 6 values
  (draft/scheduled/in_progress/pending_review/completed/cancelled),
  added copy=False, added _expand_states group_expand for kanban
- Booking form at /book-assessment now collects funding_source
  (required dropdown) so the path is known before the visit happens
- portal_assessment.py book_assessment_submit accepts funding_source
  with whitelist validation (defaults to direct_private if missing)

Deployed to odoo-westin (westin-v19) and odoo-mobility (mobility),
both verified at v19.0.2.8.0 with the new columns present.
2026-04-09 08:24:30 -04:00

107 lines
3.6 KiB
Python

# -*- coding: utf-8 -*-
{
'name': 'Fusion Authorizer & Sales Portal',
'version': '19.0.2.8.0',
'category': 'Sales/Portal',
'summary': 'Portal for Authorizers (OTs) and Sales Reps with Assessment Forms',
'description': """
Fusion Authorizer & Sales Rep Portal
=====================================
This module provides external portal access for:
**Authorizers (Occupational Therapists)**
- View assigned ADP cases
- Upload documents (ADP applications, signed pages)
- Add comments to cases
- Complete assessments with clients
- Capture digital signatures for ADP pages 11 & 12
**Sales Representatives**
- View their sales cases
- Start new client assessments
- Record wheelchair specifications and measurements
- Capture client signatures
- Track assessment progress
**Assessment System**
- Client information collection
- Wheelchair specifications (seat width, depth, height, etc.)
- Accessibility and mobility needs documentation
- Digital signature capture for ADP pages 11 & 12
- Automatic draft Sale Order creation
- Document distribution to all parties
- Automated email notifications
**Features**
- Real-time client search
- Document version tracking
- Mobile-friendly signature capture
- Email notifications for status changes
- Secure portal access with role-based permissions
""",
'author': 'Fusion Claims',
'website': 'https://fusionclaims.com',
'license': 'LGPL-3',
'depends': [
'base',
'sale',
'portal',
'website',
'mail',
'calendar',
'knowledge',
'fusion_claims',
'fusion_tasks',
'fusion_loaners_management',
],
'data': [
# Security
'security/portal_security.xml',
'security/ir.model.access.csv',
# Data
'data/mail_template_data.xml',
'data/portal_menu_data.xml',
'data/ir_actions_server_data.xml',
'data/welcome_articles.xml',
# Views
'views/res_partner_views.xml',
'views/sale_order_views.xml',
'views/assessment_views.xml',
'views/loaner_checkout_views.xml',
'views/pdf_template_views.xml',
# Portal Templates
'views/portal_templates.xml',
'views/portal_assessment_express.xml',
'views/portal_pdf_editor.xml',
'views/portal_accessibility_templates.xml',
'views/portal_accessibility_forms.xml',
'views/portal_technician_templates.xml',
'views/portal_book_assessment.xml',
'views/portal_page11_sign_templates.xml',
],
'assets': {
'web.assets_backend': [
'fusion_authorizer_portal/static/src/xml/chatter_message_authorizer.xml',
'fusion_authorizer_portal/static/src/js/chatter_message_authorizer.js',
],
'web.assets_frontend': [
'fusion_authorizer_portal/static/src/css/portal_style.css',
'fusion_authorizer_portal/static/src/css/technician_portal.css',
'fusion_authorizer_portal/static/src/js/portal_search.js',
'fusion_authorizer_portal/static/src/js/assessment_form.js',
'fusion_authorizer_portal/static/src/js/signature_pad.js',
'fusion_authorizer_portal/static/src/js/pdf_field_editor.js',
'fusion_authorizer_portal/static/src/js/technician_push.js',
'fusion_authorizer_portal/static/src/js/technician_location.js',
'fusion_authorizer_portal/static/src/js/timezone_detect.js',
],
},
'images': ['static/description/icon.png'],
'post_init_hook': '_reactivate_views',
'installable': True,
'application': False,
'auto_install': False,
}