Details
-
Bug
-
Status: Resolved
-
Major
-
Resolution: Fixed
-
9.0.0
-
None
Description
The following code used to work in Wicket 8 and before and refresh the entire page:
@Override
protected void onSaved(IPartialPageRequestHandler target) {
target.add(findPage());
}
In wicket 9 it gives:
java.lang.IllegalArgumentException: cannot update component that does not have setOutputMarkupId property set to true. Component: [Page class = nl.topicus.keyhub.web.pages.AccountProfielPage, id = 4, render count = 2] at deployment.keyhub-web-console.war//org.apache.wicket.core.request.handler.AbstractPartialPageRequestHandler.add(AbstractPartialPageRequestHandler.java:71) at deployment.keyhub-web-console.war//nl.topicus.keyhub.web.components.panel.AccountOverviewPanel$Config2FALink$1.onSaved(AccountOverviewPanel.java:61) at deployment.keyhub-web-console.war//nl.topicus.keyhub.web.components.contextpanel.TwoFactorAuthenticationConfigPanel$1.onSave(TwoFactorAuthenticationConfigPanel.java:59) at deployment.keyhub-web-console.war//nl.topicus.keyhub.web.components.panel.ContextPopupSubmitLink.onSubmit(ContextPopupSubmitLink.java:24) at deployment.keyhub-web-console.war//nl.topicus.keyhub.web.components.form.UpgradingSubmitLink.doSubmit(UpgradingSubmitLink.java:44) at deployment.keyhub-web-console.war//nl.topicus.keyhub.web.components.form.UpgradingSubmitLink.onSubmit(UpgradingSubmitLink.java:37)
Calling setOutputMarkupId(true) on the page fixes the error, but IMHO does not make much sense.