From ea6e77b5ddc558a6949c19660f45648c0dd3fc6d Mon Sep 17 00:00:00 2001 From: Carlos Ruiz Date: Wed, 21 Oct 2020 14:48:24 +0200 Subject: [PATCH] IDEMPIERE-4468 Pass the current value of numberbox to the textfield of calculator (#311) Fix NPE --- .../WEB-INF/src/org/adempiere/webui/component/NumberBox.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/component/NumberBox.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/component/NumberBox.java index ed92ceefbc..9d1518e12f 100644 --- a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/component/NumberBox.java +++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/component/NumberBox.java @@ -143,7 +143,7 @@ public class NumberBox extends Div HtmlBasedComponent comp = (HtmlBasedComponent) btn.getDesktop().getComponentByUuidIfAny(uid); if (comp != null) { Textbox ctbox = (Textbox) comp.getLastChild().getFirstChild(); - if (ctbox != null) { + if (ctbox != null && decimalBox.getValue() != null) { ctbox.setText(decimalBox.getValue().toString()); StringWriter writer = new StringWriter(1024); try {