Odoo Help

Welcome!

This community is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.

0

ODOO9: HOW to make a block invisible through inheritance

By
Drees Far
on 5/2/16, 9:23 AM 281 views

Hello Guys :D

Can anyone help me to make this block invisble through inheritance.

        <record id="hr_contract_form_inherit" model="ir.ui.view">

<field name="name">hr.contract.view.form.inherit</field>

<field name="model">hr.contract</field>

<field name="inherit_id" ref="hr_contract.hr_contract_view_form"/>

<field name="arch" type="xml">

<xpath expr="//group[@name='duration_group']" position="after">

<group string="Accounting">

<field name="analytic_account_id" groups="analytic.group_analytic_accounting"/>

<field name="journal_id"/>

</group>

</xpath>

</field>

</record>

Thanks a lot in advance.

1
Mohamed Essakali
On 5/2/16, 5:35 PM

If you want to make the group "duration_group"  invisible you must use "replace", "after" is used to add a new group.

...

<field name="arch" type="xml">

<xpath expr="//group[@name='duration_group']" position="replace">

</xpath> 

....

Your Answer

Please try to give a substantial answer. If you wanted to comment on the question or answer, just use the commenting tool. Please remember that you can always revise your answers - no need to answer the same question twice. Also, please don't forget to vote - it really helps to select the best questions and answers!

About This Community

This community is for professionals and enthusiasts of our products and services. Read Guidelines

Question tools

1 follower(s)

Stats

Asked: 5/2/16, 9:23 AM
Seen: 281 times
Last updated: 5/3/16, 5:48 AM