Files
Odoo-Modules/fusion_claims/views/res_partner_views.xml
Nexa Admin f3766c2898 feat: add x_fc_authorizer_number, x_fc_account_number, x_marked_for fields; auto-link authorizer from XML
- fusion_claims: added x_fc_authorizer_number to res.partner for ADP authorizer registration numbers
- fusion_claims: XML parser auto-links authorizer contact to sale order by ADP number
- fusion_claims: removed size=9 constraint from x_fc_odsp_member_id
- fusion_claims: authorizer number shown on OT/PT contact form
- fusion_so_to_po: added x_marked_for (Many2one) field definition on purchase.order
- fusion_so_to_po: added x_fc_account_number on res.partner for vendor account numbers
2026-03-11 17:22:02 +00:00

85 lines
4.1 KiB
XML

<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright 2024-2026 Nexa Systems Inc.
License OPL-1 (Odoo Proprietary License v1.0)
Part of the Fusion Claim Assistant product family.
-->
<odoo>
<!-- Add Contact Type + ODSP fields to Partner Form -->
<record id="view_partner_form_fusion_claims" model="ir.ui.view">
<field name="name">res.partner.form.fusion.claims</field>
<field name="model">res.partner</field>
<field name="inherit_id" ref="base.view_partner_form"/>
<field name="arch" type="xml">
<!-- Our Contact Type field above the address -->
<xpath expr="//span[@name='address_name']" position="before">
<field name="x_fc_contact_type" placeholder="Select contact type..."/>
</xpath>
<!-- Authorizer number for OTs/PTs/authorizer contacts -->
<xpath expr="//field[@name='x_fc_contact_type']" position="after">
<field name="x_fc_authorizer_number" string="ADP Reg. Number"
invisible="x_fc_contact_type not in ('occupational_therapist', 'physiotherapist', 'adp_agent')"
placeholder="e.g. 3000001234"/>
</xpath>
<!-- ODSP section in notebook -->
<xpath expr="//notebook" position="inside">
<page string="ODSP" name="odsp_info"
invisible="x_fc_contact_type not in ('odsp_customer', 'adp_odsp_customer', 'odsp_agent', 'odsp_office')">
<group string="ODSP Information">
<group>
<field name="x_fc_odsp_member_id"
invisible="x_fc_contact_type == 'odsp_office'"/>
<field name="x_fc_case_worker_id"
invisible="x_fc_contact_type == 'odsp_office'"/>
</group>
<group>
<field name="x_fc_date_of_birth"
invisible="x_fc_contact_type == 'odsp_office'"/>
<field name="x_fc_healthcard_number"
invisible="x_fc_contact_type == 'odsp_office'"/>
</group>
</group>
<group string="ODSP Office Details"
invisible="x_fc_contact_type != 'odsp_office'">
<group>
<field name="x_fc_is_odsp_office" invisible="1"/>
<field name="email" string="Office Email"/>
<field name="phone" string="Office Phone"/>
</group>
</group>
</page>
</xpath>
</field>
</record>
<!-- Add Contact Type to list view -->
<record id="view_partner_tree_fusion_claims" model="ir.ui.view">
<field name="name">res.partner.tree.fusion.claims</field>
<field name="model">res.partner</field>
<field name="inherit_id" ref="base.view_partner_tree"/>
<field name="arch" type="xml">
<xpath expr="//field[@name='phone']" position="after">
<field name="x_fc_contact_type" optional="hide"/>
</xpath>
</field>
</record>
<!-- Add Contact Type to search view -->
<record id="view_partner_search_fusion_claims" model="ir.ui.view">
<field name="name">res.partner.search.fusion.claims</field>
<field name="model">res.partner</field>
<field name="inherit_id" ref="base.view_res_partner_filter"/>
<field name="arch" type="xml">
<xpath expr="//filter[@name='type_company']" position="after">
<separator/>
<filter name="filter_odsp_customer" string="ODSP Customers"
domain="[('x_fc_contact_type', 'in', ['odsp_customer', 'adp_odsp_customer'])]"/>
<filter name="filter_odsp_office" string="ODSP Offices"
domain="[('x_fc_contact_type', '=', 'odsp_office')]"/>
</xpath>
</field>
</record>
</odoo>