Passa al contenuto
Menu
È necessario essere registrati per interagire con la community.
La domanda è stata contrassegnata
2 Risposte
12327 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
3079
5
mag 25
7555
1
ott 24
22529
1
ago 21
3313
0
giu 21
6527