Overslaan naar inhoud
Menu
Je moet geregistreerd zijn om te kunnen communiceren met de community.
Deze vraag is gerapporteerd
1 Beantwoorden
858 Weergaven

I tried to inherit the view of button for specific group. There's this button in Inventory>Products>Product that can be seen in top, named  .
But when inheriting it, it show's the button but the sales_count remains 0, even though there's a sold history.​

Avatar
Annuleer
Auteur

Someone please help me about this?

Beste antwoord

Hi,

Please try to use the below example for inheriting buttons.

<odoo>
<record id="product_template_form_view_sale_order_button_inherit" model="ir.ui.view">
<field name="name">product.template.sale.order.button.inherit</field>
<field name="model">product.template</field>
<field name="inherit_id" ref="sale.product_template_form_view_sale_order_button"/>
<field name="arch" type="xml">
<xpath expr="//button[@name='action_view_sales']" position="attributes">
<!-- Modify the attributes you want to change -->
<attribute name="help">Updated help text for the button</attribute>
<attribute name="icon">fa-new-icon</attribute>
</xpath>
</field>
</record>
</odoo>


Hope it helps


Avatar
Annuleer
Auteur

I already inherited the button. What my problem is the sale_count. It remains 0 no matter how i tried to inherit the view.

Gerelateerde posts Antwoorden Weergaven Activiteit
1
mei 16
7271
4
mrt. 24
3658
1
okt. 23
5556
2
mrt. 23
10308
2
mrt. 23
2586