Přejít na obsah
Menu
You need to be registered to interact with the community.
This question has been flagged
4 Odpovědi
4555 Zobrazení

I have a EDIT button, how i can disable or remove this functionality from my python code, when i press button.

Avatar
Zrušit

Why not with security rules from the CSV/XML?

Autor

How i can do this, when i clicked on my button

Nejlepší odpověď

Hi,

You can remove edit button by changing write access of a model to '0' in security files or by setting edit = false in that models form view.

eg:

<record id="sales_commission_form_view" model="ir.ui.view">
<field name="name">sales.commission.form</field>
<field name="model">sales.commission</field>
<field name="arch" type="xml">
<form create="false" edit="false" delete="false">

Regards

Avatar
Zrušit
Nejlepší odpověď
Use fields_view_get method and make it ['edit'] = 'false'
Avatar
Zrušit
Related Posts Odpovědi Zobrazení Aktivita
2
srp 25
2745
3
úno 25
3954
0
kvě 24
46
1
dub 24
3594
4
zář 23
5146