inlinframeを使用してポップアッププレビュー印刷ページを表示したいのですが、これが私の問題です。
Java:
Form form = new Form("form");
form.setOutputMarkupId(true);
form.add(new AjaxSubmitLink("test") {
@Override
protected void onSubmit(AjaxRequestTarget art, Form<?> form) {
containerPrint.add(/*another inlineframe*/)
art.addComponent(containerPrint);
}
});
add(form);
HTML:
<form wicket:id="form">
<input type="button" wicket:id="test"></input>
</form>
<div wicket:id="page" style="width: 0px;height: 0px">
<iframe wicket:id="printPage" width="0px" height="0px">
</iframe>
</div>
テストボタンをクリックしてinlineiframeを別のinlineiframeに置き換えたいのですが、ボタンをクリックするとこの問題が発生します
WicketMessage: org.apache.wicket.WicketRuntimeException: component form:panel:panel:panel:mcGridViewInfo:GridViewInfo:form:<b>test not found on page</b> ir.mersad.ui.authenticationAndAuthorization.Office[id = 1], listener interface = [RequestListenerInterface name=IActivePageBehaviorListener, method=public abstract void org.apache.wicket.behavior.IBehaviorListener.onRequest()]
Root cause:
org.apache.wicket.WicketRuntimeException: component form:panel:panel:panel:mcGridViewInfo:GridViewInfo:form:test not found on page ir.mersad.ui.authenticationAndAuthorization.Office[id = 1], listener interface = [RequestListenerInterface name=IActivePageBehaviorListener, method=public abstract void org.apache.wicket.behavior.IBehaviorListener.onRequest()]
at org.apache.wicket.request.AbstractRequestCycleProcessor.resolveListenerInterfaceTarget(AbstractRequestCycleProcessor.java:427)
at org.apache.wicket.request.AbstractRequestCycleProcessor.resolveRenderedPage(AbstractRequestCycleProcessor.java:472)
at org.apache.wicket.protocol.http.WebRequestCycleProcessor.resolve(WebRequestCycleProcessor.java:144)
at org.apache.wicket.RequestCycle.step(RequestCycle.java:1339)
at org.apache.wicket.RequestCycle.steps(RequestCycle.java:1465)
at org.apache.wicket.RequestCycle.request(RequestCycle.java:545)
at org.apache.wicket.protocol.http.WicketFilter.doGet(WicketFilter.java:486)
at org.apache.wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java:319)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:225)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:169)
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:472)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:168)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:98)
at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:927)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:118)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:407)
at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:999)
at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:565)
at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:309)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
at java.lang.Thread.run(Thread.java:722)
Complete stack:
org.apache.wicket.protocol.http.request.InvalidUrlException: org.apache.wicket.WicketRuntimeException: component form:panel:panel:panel:mcGridViewInfo:GridViewInfo:form:test not found on page ir.mersad.ui.authenticationAndAuthorization.Office[id = 1], listener interface = [RequestListenerInterface name=IActivePageBehaviorListener, method=public abstract void org.apache.wicket.behavior.IBehaviorListener.onRequest()]
at org.apache.wicket.protocol.http.WebRequestCycleProcessor.resolve(WebRequestCycleProcessor.java:262)
at org.apache.wicket.RequestCycle.step(RequestCycle.java:1339)
at org.apache.wicket.RequestCycle.steps(RequestCycle.java:1465)
at org.apache.wicket.RequestCycle.request(RequestCycle.java:545)
at org.apache.wicket.protocol.http.WicketFilter.doGet(WicketFilter.java:486)
私はすでに問題が以下にあることを知っています:
container.add(new InlineFrame("printPage", new EmptyPage()));
ラベルに交換すると正常に動作しますが、何が問題なのかわかりません