Bỏ qua để đến Nội dung
Menu
Câu hỏi này đã bị gắn cờ
2 Trả lời
12315 Lượt xem

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?


Ảnh đại diện
Huỷ bỏ
Câu trả lời hay nhất

Change your code to:

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

This will give you:


Ảnh đại diện
Huỷ bỏ

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

Bài viết liên quan Trả lời Lượt xem Hoạt động
1
thg 3 21
3047
5
thg 5 25
7429
1
thg 10 24
22441
1
thg 8 21
3254
0
thg 6 21
6472