Skip to Content
Menu
Musisz się zarejestrować, aby móc wchodzić w interakcje z tą społecznością.
To pytanie dostało ostrzeżenie

Hi All,
I was trying to override one of Odoo's exception classes in my custom module. Here is what i tried.

exception.py
     

from odoo.exceptions import ValidationError, except_orm
from odoo.http import request
print('-------am here-------------')
class ValidationError(ValidationError):
​def __init__(self, msg):
​print('print ValidationError------',msg)
​super(ValidationError, self).__init__(msg)

But still, the validation error gets called from the base class, not my custom class.

Awatar
Odrzuć
Powiązane posty Odpowiedzi Widoki Czynność
2
lis 18
12253
2
gru 24
4420
1
lis 24
3197
2
kwi 23
18221
1
mar 23
2462