콘텐츠로 건너뛰기
메뉴
커뮤니티에 참여하려면 회원 가입을 하시기 바랍니다.
신고된 질문입니다
1 회신
6261 화면

Hii,

In a custom purchase workflow when submit, it should show a warning popup message that a product is expired (our custom field), and if user click on popup ok, workflow should continue as normal. 

By raise UserError stops the program execution until condition fixed. 

How to achieve in odoo 12 EE?

아바타
취소
작성자

As @ Amr Abd-Alkrim Hassan replied. 
Achieved the requirement with the help of wizard.


베스트 답변

All Odoo errors will stop the execution of the python method if you raise them. So you can't do them through UserError, ValidationError. But there is a work around you can build a wizard that will get executed through an action and in the wizard you can build a form with buttons that are linked to python methods and you can execute what ever you want there.

Read more about how to build wizards here.
And For calling the wizard in your method read here.

아바타
취소
관련 게시물 답글 화면 활동
2
8월 19
6996
2
5월 16
4139
4
7월 24
15166
1
7월 22
2494
0
1월 22
2145