Split 49 modules/suites into independent git repos; untrack from monorepo
Each top-level module/suite folder is now its own private repo on GitHub (gsinghpal/<name>) and gitea (admin/<name>), with a fresh single initial commit. The monorepo no longer tracks them (added to .gitignore + git rm --cached); working-tree files are retained on disk and managed in their own repos. The monorepo keeps shared root files (CLAUDE.md, docs/, scripts/, tools/, AGENTS.md, WIP/obsolete dirs) and full history. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -1,84 +0,0 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# Copyright 2024-2026 Nexa Systems Inc.
|
||||
# License OPL-1 (Odoo Proprietary License v1.0)
|
||||
"""
|
||||
MOD Funding Denied Wizard — captures the denial reason and sets the order
|
||||
status. Previously action_mod_funding_denied was a bare write with no reason
|
||||
capture; this wizard replaces that flow.
|
||||
"""
|
||||
from odoo import models, fields, api, _
|
||||
from odoo.exceptions import UserError
|
||||
from markupsafe import Markup
|
||||
|
||||
|
||||
class ModFundingDeniedWizard(models.TransientModel):
|
||||
_name = 'fusion_claims.mod.funding.denied.wizard'
|
||||
_description = 'MOD - Funding Denied Reason Capture'
|
||||
|
||||
sale_order_id = fields.Many2one('sale.order', required=True, readonly=True)
|
||||
denial_date = fields.Date(
|
||||
string='Denial Date',
|
||||
required=True,
|
||||
default=fields.Date.context_today,
|
||||
)
|
||||
denial_reason_category = fields.Selection(
|
||||
selection=[
|
||||
('income_too_high', 'Client income exceeds MOD threshold'),
|
||||
('residency', 'Residency requirement not met'),
|
||||
('project_scope', 'Project scope not eligible'),
|
||||
('missing_docs', 'Missing documentation'),
|
||||
('funding_depleted', 'MOD funding depleted for this period'),
|
||||
('other', 'Other'),
|
||||
],
|
||||
string='Denial Category',
|
||||
required=True,
|
||||
)
|
||||
denial_reason = fields.Text(
|
||||
string='Denial Details',
|
||||
required=True,
|
||||
help='MOD\'s stated reason for denying funding. Captured for the '
|
||||
'audit trail and used when generating the client denial email.',
|
||||
)
|
||||
|
||||
@api.model
|
||||
def default_get(self, fields_list):
|
||||
res = super().default_get(fields_list)
|
||||
if self.env.context.get('active_id'):
|
||||
order = self.env['sale.order'].browse(self.env.context['active_id'])
|
||||
res['sale_order_id'] = order.id
|
||||
return res
|
||||
|
||||
def action_confirm(self):
|
||||
self.ensure_one()
|
||||
order = self.sale_order_id
|
||||
if order.x_fc_mod_status not in ('awaiting_funding', 'quote_submitted', 'handoff_to_client'):
|
||||
raise UserError(
|
||||
_("Funding can only be denied from awaiting_funding, "
|
||||
"quote_submitted or handoff_to_client. Current: %s") % order.x_fc_mod_status
|
||||
)
|
||||
|
||||
labels = dict(self._fields['denial_reason_category'].selection)
|
||||
category_label = labels.get(self.denial_reason_category, self.denial_reason_category)
|
||||
full_reason = f'[{category_label}] {self.denial_reason}'
|
||||
|
||||
order.write({
|
||||
'x_fc_mod_status': 'funding_denied',
|
||||
'x_fc_mod_funding_denial_reason': full_reason,
|
||||
})
|
||||
|
||||
body = (
|
||||
f'<div class="alert alert-danger" role="alert">'
|
||||
f'<strong><i class="fa fa-ban"></i> Funding Denied by March of Dimes</strong>'
|
||||
f'<ul>'
|
||||
f'<li><strong>Date:</strong> {self.denial_date.strftime("%B %d, %Y")}</li>'
|
||||
f'<li><strong>Category:</strong> {category_label}</li>'
|
||||
f'<li><strong>Details:</strong> {self.denial_reason}</li>'
|
||||
f'</ul>'
|
||||
f'</div>'
|
||||
)
|
||||
order.message_post(
|
||||
body=Markup(body),
|
||||
message_type='notification',
|
||||
subtype_xmlid='mail.mt_note',
|
||||
)
|
||||
return {'type': 'ir.actions.act_window_close'}
|
||||
Reference in New Issue
Block a user