Se rendre au contenu
Menu
Cette question a été signalée
2 Réponses
2288 Vues

in the documentation, it was just mentioned as a passing remark

https://www.odoo.com/documentation/17.0/developer/reference/frontend/javascript_reference.html#patching-classes

But is there any example I can refer to?

Avatar
Ignorer
Meilleure réponse

I think it should be done some like this:

patch(ClassToPatch, {
components: {
​...(ClassToPatch.components || {}),
​Dropdown,
​DropdownItem,
​}
})


Avatar
Ignorer
Meilleure réponse

Hi,

Please refer to the following blog for an understanding the working of patching, with example:


https://www.cybrosys.com/blog/how-to-patch-existing-owl-component-in-odoo-17


Hope it helps.

Avatar
Ignorer
Publications associées Réponses Vues Activité
2
juil. 24
2670
2
mai 24
2196
1
déc. 23
2624
1
juin 24
1453
1
mai 24
1954