From 221384a1ce86cf9c861e4a3ef72eac2ae6171f56 Mon Sep 17 00:00:00 2001 From: Carlos Ruiz Date: Sun, 16 Oct 2022 16:21:56 +0200 Subject: [PATCH] IDEMPIERE-5449 Performance: Avoid recount when clicking a process button (#1527) * IDEMPIERE-5449 Performance: Avoid recount when clicking a process button * - remove unnecessary comment --- .../webui/adwindow/AbstractADWindowContent.java | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/adwindow/AbstractADWindowContent.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/adwindow/AbstractADWindowContent.java index 6ba0ea319c..a06996b441 100644 --- a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/adwindow/AbstractADWindowContent.java +++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/adwindow/AbstractADWindowContent.java @@ -1326,8 +1326,8 @@ public abstract class AbstractADWindowContent extends AbstractUIPart implements } MPInstance instance = new MPInstance(ctx, pi.getAD_PInstance_ID(), "false"); - if (!instance.isRunAsJob()){ - // when run as job, don't expect see its effect when close parameter panel, so don't refresh + if (!instance.isRunAsJob() && !dialog.isCancel()){ + // when run as job or canceled, don't expect see its effect when close parameter panel, so don't refresh onRefresh(true, false); } @@ -3731,13 +3731,6 @@ public abstract class AbstractADWindowContent extends AbstractUIPart implements } Executions.schedule(getComponent().getDesktop(), e -> dialog.focus(), new Event("onPostShowProcessModalDialog")); } - if (adTabbox.getSelectedGridTab().isQuickForm()) { - adTabbox.getSelectedGridTab().dataRefreshAll(false, false); - } - else - { - onRefresh(true, false); - } } }