How I can show dialog before any f:ajax action. I have code as following:
<h:commandButton value="Create Project" styleClass="greyishBtn submitForm" action="#{projectController.delete}">
<f:ajax execute="@form" onevent="function(data) {createProjectEventHandler(data);}" render=":tblProject txtNewProjectName txtNewProjectStartDate taNewProjectDesc"/>
</h:commandButton>
This code works fine, but I need a confirm dialog before call delete action, I tried onevent, but it only have begin, success and complete events, what I need is confirm dialog before 'begin' event.
Any idea?
Thanks in advance.