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

hi. 

im looking for a method that runs when a form opens and can be overriden in odoo 16 to run custom code before the form opens.

i want to run custom code when crm pipeline opens.

hope someone can help

Avatar
Zrušit
Nejlepší odpověď

Hi,

You can use the '_get_view' method in the crm_lead model.

@api.model
   def _get_view(self, view_id=None, view_type='form', **options):
       arch, view = super()._get_view(view_id, view_type, **options)
       custom code here
       return arch, view


Hope it helps​

Avatar
Zrušit
Related Posts Odpovědi Zobrazení Aktivita
1
lis 24
1666
1
dub 24
2073
3
čvn 23
2476
1
zář 21
9441
1
led 24
17051