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

this.do_notify("Success", "Your Message has been send successfully...");

I can see the following error:

Uncaught Javascript Error > this.do_notify is not a function

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

Hi,

Instead of using this.do_notify in odoo 15, we should use this.displayNotification.

So try changing the code to

this.displayNotification({
   type: 'warning',
   title: _t('Success'),
   message: "Your Message has been send successfully...",
   sticky: true
});

Regards

Ảnh đại diện
Huỷ bỏ
Tác giả

Thanks
but when used displayNotification function
i getting this error
TypeError: cannot read properties of undefined ( reading 'displayNotification)

Bài viết liên quan Trả lời Lượt xem Hoạt động
1
thg 6 23
1836
1
thg 5 23
1785
0
thg 5 20
3048
2
thg 1 20
8516
1
thg 3 15
6051