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

hi everyone, im encountered some trouble.
im adding a new state in sale order "confirm salae order" which is after "sale order" state and im trying using the same button as accept & sign in "sale order" state
the problem is when i trigger that button from the "sale order" state it has no problem but when i already use the state in "sent" or "draft" which is sent the state to "sale order" and i use again the button it has an eror below

UncaughtClientError > TypeError

Uncaught Javascript Error > Illegal invocation

TypeError: Illegal invocation

    at Object.findOne (http://localhost:8069/web/assets/557-3594973/web.assets_frontend_lazy.min.js:4132:345)

    at Modal._showElement (http://localhost:8069/web/assets/557-3594973/web.assets_frontend_lazy.min.js:4452:113)

    at http://localhost:8069/web/assets/557-3594973/web.assets_frontend_lazy.min.js:4442:388

    at execute (http://localhost:8069/web/assets/557-3594973/web.assets_frontend_lazy.min.js:4394:475)

    at http://localhost:8069/web/assets/557-3594973/web.assets_frontend_lazy.min.js:4410:81

    at execute (http://localhost:8069/web/assets/557-3594973/web.assets_frontend_lazy.min.js:4394:475)

    at HTMLDivElement.handler (http://localhost:8069/web/assets/557-3594973/web.assets_frontend_lazy.min.js:4396:75)

    at triggerTransitionEnd (http://localhost:8069/web/assets/557-3594973/web.assets_frontend_lazy.min.js:4384:251)

    at http://localhost:8069/web/assets/557-3594973/web.assets_frontend_lazy.min.js:4396:182

below this is my code to inherit and add new button just different string



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

1. the xpath "a contain" will probably work in a single language, you should change xpath into diffirent approach

2. I'm not sure the term "method='sale_order.confirm_sale_order()'" , you see normally to add button in template, we will use as a route which has been defined in controller or through on click action in JS file which will also eventually call route or method in backend. So i don't think this is the right way to add a button in sale order portal

Ảnh đại diện
Huỷ bỏ
Bài viết liên quan Trả lời Lượt xem Hoạt động
1
thg 9 24
1688
0
thg 7 24
1412
1
thg 4 23
13349
1
thg 3 24
14831
13
thg 10 17
17994