Skip to Content
Menu
Musisz się zarejestrować, aby móc wchodzić w interakcje z tą społecznością.
To pytanie dostało ostrzeżenie
2 Odpowiedzi
4393 Widoki

How to Overwrite each item (please see attached image).



I tried this code, but it creates another item, it does not overwrite the existing one.



Anyone can help?

Awatar
Odrzuć
Najlepsza odpowiedź

Hi,

Try this:

<template id="purchase.portal_my_home_purchase" name="Show Purchase Orders" customize_show="True" inherit_id="portal.portal_my_home" priority="25">
<xpath expr="//div[hasclass('o_portal_docs')]" position="inside">
<t t-call="portal.portal_docs_entry">
<t t-set="title">Purchase Orders Changed</t>
<t t-set="url" t-value="'/my/purchase'"/>
<t t-set="placeholder_count" t-value="'purchase_count'"/>
</t>
</xpath>
</template>

Thanks

Awatar
Odrzuć
Najlepsza odpowiedź
<template id="portal_my_home_purchase_changed" inherit_id="purchase.portal_my_home_purchase">
<xpath expr="//t[@t-set='title']" position="replace">
<t t-set="title" t-value="'Purchase Orders XXX'"/>
</xpath>
</template>

This will change the title.
Regards
Awatar
Odrzuć
Powiązane posty Odpowiedzi Widoki Czynność
0
wrz 22
2974
1
sty 23
2162
2
cze 22
3447
1
kwi 22
2319
0
kwi 22
3658