Passa al contenuto
Menu
È necessario essere registrati per interagire con la community.
La domanda è stata contrassegnata
1 Rispondi
13739 Visualizzazioni

Hi,

has anyone an idea how I can override Odoo's default behaviour of hiding records with active=False values?
It leads to many problems for users who needs to see inactive records in several one2many or many2many views. It is not very user friendly, if they always have to switch to some list view and have to enable the advanced filter for active=False & active=True.

So, how to override this behaviour without renaming the active column in many of my models?

Thanks!

Avatar
Abbandona
Risposta migliore

Hi,

This can be done by passing this value in the context of your view:

{'active_test': False,}


A simple way to change the context is with the debug mode, choose "Edit action" from the debug window as admin user.  In the form you can update the value for context.


Regards,

Jos

Avatar
Abbandona
Autore

It works fine, thank you!

Post correlati Risposte Visualizzazioni Attività
2
gen 17
3216
4
feb 24
11349
0
nov 23
1369
1
giu 23
1890
0
ott 22
2441