Deactivating ToolbarDetail Customize button throws NPE when using Toggle button
Description
Environment
Activity
Nicolas Micoud May 17, 2021 at 9:29 AM
nb this patch also solves
java.lang.ClassCastException: class org.zkoss.zul.Space cannot be cast to class org.adempiere.webui.component.ToolBarButton (org.zkoss.zul.Space is in unnamed module of loader org.eclipse.osgi.internal.loader.EquinoxClassLoader @4b0250b; org.adempiere.webui.component.ToolBarButton is in unnamed module of loader org.eclipse.osgi.internal.loader.EquinoxClassLoader @1f4c9c39)
at java.base/java.util.stream.ReferencePipeline$2$1.accept(ReferencePipeline.java:176)
at java.base/java.util.Spliterators$IteratorSpliterator.tryAdvance(Spliterators.java:1812)
at java.base/java.util.stream.ReferencePipeline.forEachWithCancel(ReferencePipeline.java:127)
at java.base/java.util.stream.AbstractPipeline.copyIntoWithCancel(AbstractPipeline.java:502)
at java.base/java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:488)
at java.base/java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:474)
at java.base/java.util.stream.FindOps$FindOp.evaluateSequential(FindOps.java:150)
at java.base/java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234)
at java.base/java.util.stream.ReferencePipeline.findFirst(ReferencePipeline.java:543)
at org.adempiere.webui.adwindow.DetailPane$Tabpanel.getToolbarButton(DetailPane.java:1211)
at org.adempiere.webui.adwindow.DetailPane.onToggle(DetailPane.java:539)
at org.adempiere.webui.adwindow.DetailPane.lambda$1(DetailPane.java:443)
at org.zkoss.zk.ui.AbstractComponent.onEvent(AbstractComponent.java:3184)
at org.zkoss.zk.ui.AbstractComponent.service(AbstractComponent.java:3154)
at org.zkoss.zk.ui.AbstractComponent.service(AbstractComponent.java:3096)
at org.zkoss.zk.ui.impl.EventProcessor.process(EventProcessor.java:138)
at org.zkoss.zk.ui.impl.UiEngineImpl.processEvent(UiEngineImpl.java:1890)
at org.zkoss.zk.ui.impl.UiEngineImpl.process(UiEngineImpl.java:1662)
at org.zkoss.zk.ui.impl.UiEngineImpl.execUpdate(UiEngineImpl.java:1329)
at org.zkoss.zk.au.http.DHtmlUpdateServlet.process(DHtmlUpdateServlet.java:570)
at org.zkoss.zk.au.http.DHtmlUpdateServlet.doGet(DHtmlUpdateServlet.java:450)
Hi,
Deactivating ToolbarDetail Customize button throws NPE when using Toggle button
Steps
log in System
deactivate "Detail - Customize" record from Toolbar Button window
Open any window with a sub tab ; click on the Toggle button.