You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@wicket.apache.org by "Brevard Swart (JIRA)" <ji...@apache.org> on 2010/01/07 17:10:56 UTC
[jira] Created: (WICKET-2665) When adding two buttons to a form and
enabling and disabling them alternatively we get the
org.apache.wicket.WicketRuntimeException: Submit Button ... is not enabled
When adding two buttons to a form and enabling and disabling them alternatively we get the org.apache.wicket.WicketRuntimeException: Submit Button ... is not enabled
----------------------------------------------------------------------------------------------------------------------------------------------------------------------
Key: WICKET-2665
URL: https://issues.apache.org/jira/browse/WICKET-2665
Project: Wicket
Issue Type: Bug
Components: wicket
Affects Versions: 1.4.5, 1.4.4
Environment: Wicket 1.4.5 portlet
Deployed on Liferay 5.2.3 (using JBoss 4.2.3 on windows X)
Reporter: Brevard Swart
If you look at eth JIRA WICKET-2570 fix it adds the following lines:
+ if (!component.isEnabledInHierarchy())
+ {
+ throw new WicketRuntimeException("Submit Button " +
+ submittingComponent.getInputName() + " (path=" +
+ component.getPageRelativePath() + ") is not enabled");
+ }
This fix above breaks our code if I go back to version 1.4.3 this goes away.
If you have a scenarion where you have added two ajax buttons on a form disabling them using org.apache.wicket.Component.setEnabled, alternating and enabling one while disabling the other. Then once you have clicked on the button (say Button Y) a second time you get the error:
org.apache.wicket.WicketRuntimeException: Submit Button X ... is not enabled
I have a wicket form inside a wick panel that is inside another wicket panel (if I do a complete re-render on the root panel after each click the error will not occur). The order in which the buttons have been added to the form determine which button onclick will fail. This failure will occur when Submit Button Y is clicked a second time it will complain that Submit Button X is not enabled. We have tried disabling these buttons in either the onBeforeRender of the buttons or the form but both fail.
Current button states:
Button Y - isEnabled = true
Button Y - isEnabledInHierarchy = true
Button X - isEnabled = false
Button X - isEnabledInHierarchy = false
Submit Button Y clicked!
Current button states:
Button Y - isEnabled = false
Button Y - isEnabledInHierarchy = false
Button X - isEnabled = true
Button X- isEnabledInHierarchy = true
Submit Button X clicked:
Current button states:
Button Y - isEnabled = true
Button Y - isEnabledInHierarchy = true
Button X - isEnabled = false
Button X- isEnabledInHierarchy = false
Submit Button Y clicked!
ERROR!!!!
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (WICKET-2665) When adding two buttons to a form and
enabling and disabling them alternatively we get the
org.apache.wicket.WicketRuntimeException: Submit Button ... is not enabled
Posted by "Brevard Swart (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/WICKET-2665?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Brevard Swart updated WICKET-2665:
----------------------------------
Description:
If you look at the JIRA WICKET-2570 fix it adds the following lines:
+ if (!component.isEnabledInHierarchy())
+ {
+ throw new WicketRuntimeException("Submit Button " +
+ submittingComponent.getInputName() + " (path=" +
+ component.getPageRelativePath() + ") is not enabled");
+ }
This fix above breaks our code if I go back to version 1.4.3 this goes away.
If you have a scenario where you have added two ajax buttons on a form disabling them using org.apache.wicket.Component.setEnabled, alternating and enabling one while disabling the other. Then once you have clicked on the button (say Button Y) a second time you get the error:
org.apache.wicket.WicketRuntimeException: Submit Button X ... is not enabled
I have a wicket form inside a wick panel that is inside another wicket panel (if I do a complete re-render on the root panel after each click the error will not occur). The order in which the buttons have been added to the form determine which button onclick will fail. This failure will occur when Submit Button Y is clicked a second time it will complain that Submit Button X is not enabled. We have tried disabling these buttons in either the onBeforeRender of the buttons or the form but both fail.
Current button states:
Button Y - isEnabled = true
Button Y - isEnabledInHierarchy = true
Button X - isEnabled = false
Button X - isEnabledInHierarchy = false
Submit Button Y clicked!
Current button states:
Button Y - isEnabled = false
Button Y - isEnabledInHierarchy = false
Button X - isEnabled = true
Button X- isEnabledInHierarchy = true
Submit Button X clicked:
Current button states:
Button Y - isEnabled = true
Button Y - isEnabledInHierarchy = true
Button X - isEnabled = false
Button X- isEnabledInHierarchy = false
Submit Button Y clicked!
ERROR!!!!
was:
If you look at eth JIRA WICKET-2570 fix it adds the following lines:
+ if (!component.isEnabledInHierarchy())
+ {
+ throw new WicketRuntimeException("Submit Button " +
+ submittingComponent.getInputName() + " (path=" +
+ component.getPageRelativePath() + ") is not enabled");
+ }
This fix above breaks our code if I go back to version 1.4.3 this goes away.
If you have a scenarion where you have added two ajax buttons on a form disabling them using org.apache.wicket.Component.setEnabled, alternating and enabling one while disabling the other. Then once you have clicked on the button (say Button Y) a second time you get the error:
org.apache.wicket.WicketRuntimeException: Submit Button X ... is not enabled
I have a wicket form inside a wick panel that is inside another wicket panel (if I do a complete re-render on the root panel after each click the error will not occur). The order in which the buttons have been added to the form determine which button onclick will fail. This failure will occur when Submit Button Y is clicked a second time it will complain that Submit Button X is not enabled. We have tried disabling these buttons in either the onBeforeRender of the buttons or the form but both fail.
Current button states:
Button Y - isEnabled = true
Button Y - isEnabledInHierarchy = true
Button X - isEnabled = false
Button X - isEnabledInHierarchy = false
Submit Button Y clicked!
Current button states:
Button Y - isEnabled = false
Button Y - isEnabledInHierarchy = false
Button X - isEnabled = true
Button X- isEnabledInHierarchy = true
Submit Button X clicked:
Current button states:
Button Y - isEnabled = true
Button Y - isEnabledInHierarchy = true
Button X - isEnabled = false
Button X- isEnabledInHierarchy = false
Submit Button Y clicked!
ERROR!!!!
> When adding two buttons to a form and enabling and disabling them alternatively we get the org.apache.wicket.WicketRuntimeException: Submit Button ... is not enabled
> ----------------------------------------------------------------------------------------------------------------------------------------------------------------------
>
> Key: WICKET-2665
> URL: https://issues.apache.org/jira/browse/WICKET-2665
> Project: Wicket
> Issue Type: Bug
> Components: wicket
> Affects Versions: 1.4.4, 1.4.5
> Environment: Wicket 1.4.5 portlet
> Deployed on Liferay 5.2.3 (using JBoss 4.2.3 on windows X)
> Reporter: Brevard Swart
> Original Estimate: 24h
> Remaining Estimate: 24h
>
> If you look at the JIRA WICKET-2570 fix it adds the following lines:
> + if (!component.isEnabledInHierarchy())
> + {
> + throw new WicketRuntimeException("Submit Button " +
> + submittingComponent.getInputName() + " (path=" +
> + component.getPageRelativePath() + ") is not enabled");
> + }
> This fix above breaks our code if I go back to version 1.4.3 this goes away.
> If you have a scenario where you have added two ajax buttons on a form disabling them using org.apache.wicket.Component.setEnabled, alternating and enabling one while disabling the other. Then once you have clicked on the button (say Button Y) a second time you get the error:
> org.apache.wicket.WicketRuntimeException: Submit Button X ... is not enabled
> I have a wicket form inside a wick panel that is inside another wicket panel (if I do a complete re-render on the root panel after each click the error will not occur). The order in which the buttons have been added to the form determine which button onclick will fail. This failure will occur when Submit Button Y is clicked a second time it will complain that Submit Button X is not enabled. We have tried disabling these buttons in either the onBeforeRender of the buttons or the form but both fail.
> Current button states:
> Button Y - isEnabled = true
> Button Y - isEnabledInHierarchy = true
> Button X - isEnabled = false
> Button X - isEnabledInHierarchy = false
> Submit Button Y clicked!
> Current button states:
> Button Y - isEnabled = false
> Button Y - isEnabledInHierarchy = false
> Button X - isEnabled = true
> Button X- isEnabledInHierarchy = true
> Submit Button X clicked:
> Current button states:
> Button Y - isEnabled = true
> Button Y - isEnabledInHierarchy = true
> Button X - isEnabled = false
> Button X- isEnabledInHierarchy = false
> Submit Button Y clicked!
> ERROR!!!!
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (WICKET-2665) When adding two buttons to a form
and enabling and disabling them alternatively we get the
org.apache.wicket.WicketRuntimeException: Submit Button ... is not enabled
Posted by "Brevard Swart (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/WICKET-2665?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12797669#action_12797669 ]
Brevard Swart commented on WICKET-2665:
---------------------------------------
The error stack is:
2010-01-07 11:04:06,674 INFO [STDOUT] 2010-01-07 11:04:06,659 ERROR wicket.RequestCycle (RequestCycle.java:1521) - Submit Button suspendActivityPanel:suspensionForm:suspendButton (path=searchForm:suspendActivityPanel:suspensionForm:suspendButton) is not enabled
org.apache.wicket.WicketRuntimeException: Submit Button suspendActivityPanel:suspensionForm:suspendButton (path=searchForm:suspendActivityPanel:suspensionForm:suspendButton) is not enabled
at org.apache.wicket.markup.html.form.Form$2.component(Form.java:617)
at org.apache.wicket.MarkupContainer.visitChildren(MarkupContainer.java:878)
at org.apache.wicket.MarkupContainer.visitChildren(MarkupContainer.java:893)
at org.apache.wicket.MarkupContainer.visitChildren(MarkupContainer.java:893)
at org.apache.wicket.MarkupContainer.visitChildren(MarkupContainer.java:893)
at org.apache.wicket.markup.html.form.Form.findSubmittingButton(Form.java:593)
at org.apache.wicket.markup.html.form.Form.onFormSubmitted(Form.java:866)
at org.apache.wicket.ajax.form.AjaxFormSubmitBehavior.onEvent(AjaxFormSubmitBehavior.java:135)
at org.apache.wicket.ajax.AjaxEventBehavior.respond(AjaxEventBehavior.java:177)
at org.apache.wicket.ajax.AbstractDefaultAjaxBehavior.onRequest(AbstractDefaultAjaxBehavior.java:299)
at org.apache.wicket.request.target.component.listener.BehaviorRequestTarget.processEvents(BehaviorRequestTarget.java:119)
at org.apache.wicket.request.AbstractRequestCycleProcessor.processEvents(AbstractRequestCycleProcessor.java:92)
at org.apache.wicket.RequestCycle.processEventsAndRespond(RequestCycle.java:1250)
at org.apache.wicket.RequestCycle.step(RequestCycle.java:1329)
at org.apache.wicket.RequestCycle.steps(RequestCycle.java:1428)
at org.apache.wicket.RequestCycle.request(RequestCycle.java:545)
at org.apache.wicket.protocol.http.WicketFilter.doGet(WicketFilter.java:479)
at org.apache.wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java:312)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:654)
at org.apache.catalina.core.ApplicationDispatcher.doInclude(ApplicationDispatcher.java:557)
at org.apache.catalina.core.ApplicationDispatcher.include(ApplicationDispatcher.java:481)
at com.liferay.portlet.PortletRequestDispatcherImpl.dispatch(PortletRequestDispatcherImpl.java:307)
at com.liferay.portlet.PortletRequestDispatcherImpl.include(PortletRequestDispatcherImpl.java:107)
at org.apache.wicket.protocol.http.portlet.WicketPortlet.processMimeResponseRequest(WicketPortlet.java:655)
at org.apache.wicket.protocol.http.portlet.WicketPortlet.processRequest(WicketPortlet.java:608)
at org.apache.wicket.protocol.http.portlet.WicketPortlet.serveResource(WicketPortlet.java:536)
at ie.magnet.threesixtyview.core.SearchPortlet.serveResource(SearchPortlet.java:167)
at com.sun.portal.portletcontainer.appengine.filter.FilterChainImpl.doFilter(FilterChainImpl.java:177)
at com.liferay.portal.kernel.portlet.PortletFilterUtil.doFilter(PortletFilterUtil.java:76)
at com.liferay.portal.kernel.servlet.PortletServlet.service(PortletServlet.java:100)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.apache.wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java:363)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:654)
at org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:445)
at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:379)
at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:292)
at com.liferay.portlet.InvokerPortletImpl.invoke(InvokerPortletImpl.java:615)
at com.liferay.portlet.InvokerPortletImpl.invokeResource(InvokerPortletImpl.java:724)
at com.liferay.portlet.InvokerPortletImpl.serveResource(InvokerPortletImpl.java:498)
at com.liferay.portal.action.LayoutAction.processPortletRequest(LayoutAction.java:672)
at com.liferay.portal.action.LayoutAction.processLayout(LayoutAction.java:459)
at com.liferay.portal.action.LayoutAction.execute(LayoutAction.java:195)
at org.apache.struts.action.RequestProcessor.processActionPerform(RequestProcessor.java:431)
at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:236)
at com.liferay.portal.struts.PortalRequestProcessor.process(PortalRequestProcessor.java:157)
at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1196)
at org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:432)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:710)
at com.liferay.portal.servlet.MainServlet.callParentService(MainServlet.java:608)
at com.liferay.portal.servlet.MainServlet.service(MainServlet.java:846)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:654)
at org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:445)
at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:379)
at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:292)
at com.liferay.portal.servlet.FriendlyURLServlet.service(FriendlyURLServlet.java:143)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at com.liferay.portal.kernel.servlet.BaseFilter.processFilter(BaseFilter.java:154)
at com.liferay.portal.servlet.filters.strip.StripFilter.processFilter(StripFilter.java:178)
at com.liferay.portal.kernel.servlet.BaseFilter.doFilter(BaseFilter.java:91)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at com.liferay.portal.kernel.servlet.BaseFilter.processFilter(BaseFilter.java:154)
at com.liferay.portal.kernel.servlet.BaseFilter.doFilter(BaseFilter.java:94)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at com.liferay.portal.kernel.servlet.BaseFilter.processFilter(BaseFilter.java:154)
at com.liferay.portal.servlet.filters.gzip.GZipFilter.processFilter(GZipFilter.java:149)
at com.liferay.portal.kernel.servlet.BaseFilter.doFilter(BaseFilter.java:91)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at com.liferay.portal.kernel.servlet.BaseFilter.processFilter(BaseFilter.java:154)
at com.liferay.portal.servlet.filters.secure.SecureFilter.processFilter(SecureFilter.java:282)
at com.liferay.portal.kernel.servlet.BaseFilter.doFilter(BaseFilter.java:91)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at com.liferay.portal.kernel.servlet.BaseFilter.processFilter(BaseFilter.java:154)
at com.liferay.portal.kernel.servlet
2010-01-07 11:04:06,737 INFO [STDOUT] .BaseFilter.doFilter(BaseFilter.java:94)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at com.liferay.portal.kernel.servlet.BaseFilter.processFilter(BaseFilter.java:154)
at com.liferay.portal.servlet.filters.cache.CacheFilter.processFilter(CacheFilter.java:425)
at com.liferay.portal.kernel.servlet.BaseFilter.doFilter(BaseFilter.java:91)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at com.liferay.portal.kernel.servlet.BaseFilter.processFilter(BaseFilter.java:154)
at com.liferay.portal.servlet.filters.autologin.AutoLoginFilter.processFilter(AutoLoginFilter.java:257)
at com.liferay.portal.kernel.servlet.BaseFilter.doFilter(BaseFilter.java:91)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at com.liferay.portal.kernel.servlet.BaseFilter.processFilter(BaseFilter.java:154)
at com.liferay.portal.servlet.filters.sso.opensso.OpenSSOFilter.processFilter(OpenSSOFilter.java:73)
at com.liferay.portal.kernel.servlet.BaseFilter.doFilter(BaseFilter.java:91)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at com.liferay.portal.kernel.servlet.BaseFilter.processFilter(BaseFilter.java:154)
at com.liferay.portal.sharepoint.SharepointFilter.processFilter(SharepointFilter.java:193)
at com.liferay.portal.kernel.servlet.BaseFilter.doFilter(BaseFilter.java:91)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at com.liferay.portal.kernel.servlet.BaseFilter.processFilter(BaseFilter.java:154)
at com.liferay.portal.servlet.filters.virtualhost.VirtualHostFilter.doFilter(VirtualHostFilter.java:191)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at com.liferay.portal.kernel.servlet.BaseFilter.processFilter(BaseFilter.java:154)
at com.liferay.portal.servlet.filters.threadlocalcache.ThreadLocalCacheFilter.processFilter(ThreadLocalCacheFilter.java:55)
at com.liferay.portal.kernel.servlet.BaseFilter.doFilter(BaseFilter.java:91)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at com.liferay.portal.kernel.servlet.BaseFilter.processFilter(BaseFilter.java:154)
at com.liferay.portal.kernel.servlet.BaseFilter.doFilter(BaseFilter.java:94)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.tuckey.web.filters.urlrewrite.UrlRewriteFilter.doFilter(UrlRewriteFilter.java:738)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:230)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:182)
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:432)
at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:84)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:157)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:262)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583)
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:446)
at java.lang.Thread.run(Thread.java:619)
> When adding two buttons to a form and enabling and disabling them alternatively we get the org.apache.wicket.WicketRuntimeException: Submit Button ... is not enabled
> ----------------------------------------------------------------------------------------------------------------------------------------------------------------------
>
> Key: WICKET-2665
> URL: https://issues.apache.org/jira/browse/WICKET-2665
> Project: Wicket
> Issue Type: Bug
> Components: wicket
> Affects Versions: 1.4.4, 1.4.5
> Environment: Wicket 1.4.5 portlet
> Deployed on Liferay 5.2.3 (using JBoss 4.2.3 on windows X)
> Reporter: Brevard Swart
> Original Estimate: 24h
> Remaining Estimate: 24h
>
> If you look at eth JIRA WICKET-2570 fix it adds the following lines:
> + if (!component.isEnabledInHierarchy())
> + {
> + throw new WicketRuntimeException("Submit Button " +
> + submittingComponent.getInputName() + " (path=" +
> + component.getPageRelativePath() + ") is not enabled");
> + }
> This fix above breaks our code if I go back to version 1.4.3 this goes away.
> If you have a scenarion where you have added two ajax buttons on a form disabling them using org.apache.wicket.Component.setEnabled, alternating and enabling one while disabling the other. Then once you have clicked on the button (say Button Y) a second time you get the error:
> org.apache.wicket.WicketRuntimeException: Submit Button X ... is not enabled
> I have a wicket form inside a wick panel that is inside another wicket panel (if I do a complete re-render on the root panel after each click the error will not occur). The order in which the buttons have been added to the form determine which button onclick will fail. This failure will occur when Submit Button Y is clicked a second time it will complain that Submit Button X is not enabled. We have tried disabling these buttons in either the onBeforeRender of the buttons or the form but both fail.
> Current button states:
> Button Y - isEnabled = true
> Button Y - isEnabledInHierarchy = true
> Button X - isEnabled = false
> Button X - isEnabledInHierarchy = false
> Submit Button Y clicked!
> Current button states:
> Button Y - isEnabled = false
> Button Y - isEnabledInHierarchy = false
> Button X - isEnabled = true
> Button X- isEnabledInHierarchy = true
> Submit Button X clicked:
> Current button states:
> Button Y - isEnabled = true
> Button Y - isEnabledInHierarchy = true
> Button X - isEnabled = false
> Button X- isEnabledInHierarchy = false
> Submit Button Y clicked!
> ERROR!!!!
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Resolved: (WICKET-2665) When adding two buttons to a form
and enabling and disabling them alternatively we get the
org.apache.wicket.WicketRuntimeException: Submit Button ... is not enabled
Posted by "Igor Vaynberg (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/WICKET-2665?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Igor Vaynberg resolved WICKET-2665.
-----------------------------------
Resolution: Cannot Reproduce
Assignee: Igor Vaynberg
closing until a quickstart is provided. i tried to replicate but things worked as expected.
> When adding two buttons to a form and enabling and disabling them alternatively we get the org.apache.wicket.WicketRuntimeException: Submit Button ... is not enabled
> ----------------------------------------------------------------------------------------------------------------------------------------------------------------------
>
> Key: WICKET-2665
> URL: https://issues.apache.org/jira/browse/WICKET-2665
> Project: Wicket
> Issue Type: Bug
> Components: wicket
> Affects Versions: 1.4.4, 1.4.5
> Environment: Wicket 1.4.5 portlet
> Deployed on Liferay 5.2.3 (using JBoss 4.2.3 on windows X)
> Reporter: Brevard Swart
> Assignee: Igor Vaynberg
> Original Estimate: 24h
> Remaining Estimate: 24h
>
> If you look at the JIRA WICKET-2570 fix it adds the following lines:
> + if (!component.isEnabledInHierarchy())
> + {
> + throw new WicketRuntimeException("Submit Button " +
> + submittingComponent.getInputName() + " (path=" +
> + component.getPageRelativePath() + ") is not enabled");
> + }
> This fix above breaks our code if I go back to version 1.4.3 this goes away.
> If you have a scenario where you have added two ajax buttons on a form disabling them using org.apache.wicket.Component.setEnabled, alternating and enabling one while disabling the other. Then once you have clicked on the button (say Button Y) a second time you get the error:
> org.apache.wicket.WicketRuntimeException: Submit Button X ... is not enabled
> I have a wicket form inside a wick panel that is inside another wicket panel (if I do a complete re-render on the root panel after each click the error will not occur). The order in which the buttons have been added to the form determine which button onclick will fail. This failure will occur when Submit Button Y is clicked a second time it will complain that Submit Button X is not enabled. We have tried disabling these buttons in either the onBeforeRender of the buttons or the form but both fail.
> Current button states:
> Button Y - isEnabled = true
> Button Y - isEnabledInHierarchy = true
> Button X - isEnabled = false
> Button X - isEnabledInHierarchy = false
> Submit Button Y clicked!
> Current button states:
> Button Y - isEnabled = false
> Button Y - isEnabledInHierarchy = false
> Button X - isEnabled = true
> Button X- isEnabledInHierarchy = true
> Submit Button X clicked:
> Current button states:
> Button Y - isEnabled = true
> Button Y - isEnabledInHierarchy = true
> Button X - isEnabled = false
> Button X- isEnabledInHierarchy = false
> Submit Button Y clicked!
> ERROR!!!!
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (WICKET-2665) When adding two buttons to a form
and enabling and disabling them alternatively we get the
org.apache.wicket.WicketRuntimeException: Submit Button ... is not enabled
Posted by "Igor Vaynberg (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/WICKET-2665?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12799393#action_12799393 ]
Igor Vaynberg commented on WICKET-2665:
---------------------------------------
please provide a quickstart
> When adding two buttons to a form and enabling and disabling them alternatively we get the org.apache.wicket.WicketRuntimeException: Submit Button ... is not enabled
> ----------------------------------------------------------------------------------------------------------------------------------------------------------------------
>
> Key: WICKET-2665
> URL: https://issues.apache.org/jira/browse/WICKET-2665
> Project: Wicket
> Issue Type: Bug
> Components: wicket
> Affects Versions: 1.4.4, 1.4.5
> Environment: Wicket 1.4.5 portlet
> Deployed on Liferay 5.2.3 (using JBoss 4.2.3 on windows X)
> Reporter: Brevard Swart
> Original Estimate: 24h
> Remaining Estimate: 24h
>
> If you look at the JIRA WICKET-2570 fix it adds the following lines:
> + if (!component.isEnabledInHierarchy())
> + {
> + throw new WicketRuntimeException("Submit Button " +
> + submittingComponent.getInputName() + " (path=" +
> + component.getPageRelativePath() + ") is not enabled");
> + }
> This fix above breaks our code if I go back to version 1.4.3 this goes away.
> If you have a scenario where you have added two ajax buttons on a form disabling them using org.apache.wicket.Component.setEnabled, alternating and enabling one while disabling the other. Then once you have clicked on the button (say Button Y) a second time you get the error:
> org.apache.wicket.WicketRuntimeException: Submit Button X ... is not enabled
> I have a wicket form inside a wick panel that is inside another wicket panel (if I do a complete re-render on the root panel after each click the error will not occur). The order in which the buttons have been added to the form determine which button onclick will fail. This failure will occur when Submit Button Y is clicked a second time it will complain that Submit Button X is not enabled. We have tried disabling these buttons in either the onBeforeRender of the buttons or the form but both fail.
> Current button states:
> Button Y - isEnabled = true
> Button Y - isEnabledInHierarchy = true
> Button X - isEnabled = false
> Button X - isEnabledInHierarchy = false
> Submit Button Y clicked!
> Current button states:
> Button Y - isEnabled = false
> Button Y - isEnabledInHierarchy = false
> Button X - isEnabled = true
> Button X- isEnabledInHierarchy = true
> Submit Button X clicked:
> Current button states:
> Button Y - isEnabled = true
> Button Y - isEnabledInHierarchy = true
> Button X - isEnabled = false
> Button X- isEnabledInHierarchy = false
> Submit Button Y clicked!
> ERROR!!!!
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.