Passa al contenuto
Menu
È necessario essere registrati per interagire con la community.
La domanda è stata contrassegnata
2 Risposte
12244 Visualizzazioni

When I did this at v13:

raise Warning("You can't do that!")

it looked like this:



Now at v14, it looks like this:




How can I get a "user-friendly" message like at v13?


Avatar
Abbandona
Risposta migliore

Change your code to:

raise UserError("You can't do that!") 

This will give you:


Avatar
Abbandona

odoo.exceptions.Warning: An error occurred Please use the copy button to report the error to your support service

Post correlati Risposte Visualizzazioni Attività
1
mar 21
2990
5
mag 25
7242
1
ott 24
22315
1
ago 21
3224
0
giu 21
6371