I would like to understand the behaviour behind a4j on Richfaces.
I have a h:form with a h:inputText and a a4j:commandButton. The button action call a method in my bean, and the oncomplete shows Richfaces.showModal with some content.
<h:form id="i_form">
<h:inputText value="#{ordemManagedBean.formEntity.emissor.cpf}" required="true" />
<a4j:commandButton value="#{msg.labelbtn}" reRender="f_FormordemEmissorModal" oncomplete="Richfaces.showModalPanel('ordemEmissorModal');" action="#{ordemManagedBean.consultarCadastroEmissor}" />
</h:form>
Outside h:form I have an ui:decorate that imports my Modal, which have a form around.
<ui:decorate template="/templates/ordemEmissorModal.xhtml">
<ui:param
name="beanForm"
value="#{ordemManagedBean}"
/>
The problem: When I submit my form on button click, the method is fired and the modal is shown, but it works only at the first time. When I close my Modal, change the input value and submit, the method is not called and my modal is shown with the old content. What's happening in my second form submission?
Thank you in advance!