mirror of
https://github.com/OCA/contract.git
synced 2025-02-13 17:57:24 +02:00
Add check_company=True in field definition and
[('company_id', '=', company_id)] in the domain (in view or in field definition)
24 lines
961 B
XML
24 lines
961 B
XML
<?xml version="1.0" ?>
|
|
<odoo>
|
|
<!--FORM view-->
|
|
<record id="contract_contract_form_view" model="ir.ui.view">
|
|
<field name="name">contract.contract form view (in contract_mandate)</field>
|
|
<field name="model">contract.contract</field>
|
|
<field
|
|
name="inherit_id"
|
|
ref="contract_payment_mode.contract_contract_form_view"
|
|
/>
|
|
<field name="arch" type="xml">
|
|
<field name="payment_mode_id" position="after">
|
|
<field
|
|
name="mandate_id"
|
|
domain="[('partner_id', '=', commercial_partner_id), ('state', '=', 'valid'), ('company_id', '=', company_id)]"
|
|
attrs="{'invisible': [('mandate_required', '=', False)]}"
|
|
/>
|
|
<field name="commercial_partner_id" invisible="1" />
|
|
<field name="mandate_required" invisible="1" />
|
|
</field>
|
|
</field>
|
|
</record>
|
|
</odoo>
|