FIX inhert from account move

This commit is contained in:
Nossibaelhadi 2025-11-04 16:39:06 +03:00
parent e7a4b76b86
commit 11b7b88395
2 changed files with 23 additions and 1 deletions

View File

@ -0,0 +1,15 @@
<odoo>
<!-- Inherit form account move view -->
<record id="takaful_account_move_inherit_form" model="ir.ui.view">
<field name="name">takaful.account.move.inherit.form</field>
<field name="model">account.move</field>
<field name="inherit_id" ref="account.view_move_form"/>
<field name="arch" type="xml">
<xpath expr="//field[@name='invoice_origin']" position="attributes">
<attribute name="attrs">{'invisible': False}</attribute>
</xpath>
</field>
</record>
</odoo>

View File

@ -13,21 +13,28 @@
widget="statinfo"/>
</button>
</xpath>
<xpath expr="//field[@name='sponsor_related_id']" position="replace">
<field name="sponsor_related_id" readonly="1" invisible="1"/>
</xpath>
<xpath expr="//page[4]" position="after">
<page name="kafala_info" string="Kafala Information">
<group>
<field name="kafala_status" readonly="1"/>
<field name="sponsor_related_id"
readonly="1"/>
<field name="sponsor_id"
attrs="{'readonly':[('state','not in',['draft','complete_info'])]}"
invisible="1"/>
<field name="sponsorship_id" invisible="1"
attrs="{'readonly':[('state','not in',['draft','complete_info'])]}"/>
<field name="sponsorship_end_date" readonly="1"/>
</group>
<group>
<field name="is_restricted" widget="boolean_toggle"/>
<field name="general_restriction" widget="boolean_toggle"/>
<field name="kafala_status" readonly="1"/>
</group>
</page>