Перейти к содержимому
Меню
Чтобы взаимодействовать с сообществом, необходимо зарегистрироваться.
Этот вопрос был отмечен
1 Ответить
1083 Представления

hello guys i was working on a custom module in odoo 16 and in crm i want to hide or replace the quotation button but every time i got this error message 


action_sale_quotations_new is not a valid action on crm.lead


even  though im not targetting the button with name action_sale_quotations_new

<record id="crm_lead_quotations_button_hide" model="ir.ui.view">
​<field name="name">crm.lead.quotations.button.hide</field>
​<field name="model">crm.lead</field>
​<field name="inherit_id" ref="sale_crm.crm_case_form_view_oppor"/>
​<field name="arch" type="xml">
​<xpath expr="//button[@name='action_view_sale_quotation']" position="attributes">
​<attribute name="invisible">1</attribute>
​</xpath>
​</field>
</record>
Аватар
Отменить
Лучший ответ

Hi,

Try the below code:

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

            <field name="name">crm.lead.oppor.inherited.crm</field>

            <field name="model">crm.lead</field>

            <field name="inherit_id" ref="crm.crm_lead_view_form"/>

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

                <xpath expr="//button[@name='action_sale_quotations_new']" position="attributes">

                                <attribute name="invisible">1</attribute>

                </xpath>

            </field>


Hope it helps

Аватар
Отменить
Related Posts Ответы Просмотры Активность
1
мар. 25
995
2
мая 25
791
0
янв. 24
39
2
мар. 15
5643
3
дек. 23
2778