独自のフォームを含む (Richfaces) ポップアップは、別のフォームを実行する必要がある保存ボタン ( contentForm
) を提供し、検証の失敗が発生した場合は転送しません。
ただし、saveHandler.forward()
常に呼び出されます...何かアイデアはありますか?
<a4j:commandButton
id="saveContentChanges"
value="Speichern"
action="#{cc.attrs.handler.save()}"
type="submit">
<a4j:ajax
execute=":contentForm"
render=":contentForm"
oncomplete="if (#{!facesContext.validationFailed}) { saveHandler.forward() } else { #{rich:component('contentSaveHandlerPopup')}.hide() }"
onerror="errorHandler.onError(event.description); #{rich:component('contentSaveHandlerPopup')}.hide();" />
</a4j:commandButton>
PS。このコードは複合コンポーネント内にあります。JavaScript コンソールでエラーは発生しません。