From 585b289dabc03b7bf69c529e548542fa21f11397 Mon Sep 17 00:00:00 2001 From: Starryi Date: Fri, 4 Mar 2022 17:37:23 +0800 Subject: [PATCH] =?UTF-8?q?REPORT-67348=20=E7=BB=84=E4=BB=B6=E5=8C=85?= =?UTF-8?q?=E4=B8=8B=E8=BD=BD=E6=8F=90=E7=A4=BA=E6=96=87=E6=9C=AC=E4=B8=AD?= =?UTF-8?q?=E7=9A=84=E6=95=B0=E9=87=8F=E4=B8=8D=E7=AC=A6=E5=90=88=E8=AE=BE?= =?UTF-8?q?=E8=AE=A1=E6=84=8F=E5=9B=BE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 【问题原因】 下载组件包时后台已做过兼容性检测和去重处理,因此下载的组件包中本身就是兼容的组件。 所以不存在不兼容的组件。 【改动思路】 同上 REPORT-67348 组件包下载提示文本中的数量不符合设计意图 【问题原因】 下载组件包时后台已做过兼容性检测和去重处理,因此下载的组件包中本身就是兼容的组件。 所以不存在不兼容的组件。 【改动思路】 同上 --- .../mini/bridge/NativeProductBridge.java | 39 +++++-------------- 1 file changed, 10 insertions(+), 29 deletions(-) diff --git a/designer-form/src/main/java/com/fr/design/mainframe/share/ui/online/mini/bridge/NativeProductBridge.java b/designer-form/src/main/java/com/fr/design/mainframe/share/ui/online/mini/bridge/NativeProductBridge.java index e6a4f720cc..4cb985b5af 100644 --- a/designer-form/src/main/java/com/fr/design/mainframe/share/ui/online/mini/bridge/NativeProductBridge.java +++ b/designer-form/src/main/java/com/fr/design/mainframe/share/ui/online/mini/bridge/NativeProductBridge.java @@ -254,9 +254,9 @@ public class NativeProductBridge { MiniComponentShopDialog.getInstance().getContentPane(), Toolkit.i18nText("Fine-Design_Share_Online_Mini_Shop_Download_Incompatible_Component_Tip"), "", - FineJOptionPane.YES_NO_OPTION + FineJOptionPane.OK_CANCEL_OPTION ); - allowedDownload = result == JOptionPane.YES_OPTION; + allowedDownload = result == JOptionPane.OK_OPTION; } if (allowedDownload) { fireStartEvent(null); @@ -353,33 +353,14 @@ public class NativeProductBridge { SwingUtilities.invokeLater(new Runnable() { @Override public void run() { - boolean allowedDownload; - OnlineShareWidget[] childrenWidgets = OnlineShopUtils.getPackageWidgets(widget, false); - boolean isCompatibleWithCurrentEnv = true; - for (OnlineShareWidget children: childrenWidgets) { - if (!children.isCompatibleWithCurrentEnv()) { - isCompatibleWithCurrentEnv = false; - break; - } - } - int result; - if (!isCompatibleWithCurrentEnv) { - result = FineJOptionPane.showConfirmDialog( - MiniComponentShopDialog.getInstance().getContentPane(), - Toolkit.i18nText("Fine-Design_Share_Online_Mini_Shop_Download_Incompatible_Components_Package_Tip", childrenCount), - "", - FineJOptionPane.YES_NO_OPTION - ); - } else { - result = FineJOptionPane.showConfirmDialog( - MiniComponentShopDialog.getInstance().getContentPane(), - Toolkit.i18nText("Fine-Design_Share_Online_Mini_Shop_Download_Components_Package_Tip", childrenCount), - "", - FineJOptionPane.YES_NO_OPTION - ); - } - allowedDownload = result == JOptionPane.YES_OPTION; - if (allowedDownload) { + OnlineShareWidget[] childrenWidgets = OnlineShopUtils.getPackageWidgets(widget, true); + int result = FineJOptionPane.showConfirmDialog( + MiniComponentShopDialog.getInstance().getContentPane(), + Toolkit.i18nText("Fine-Design_Share_Online_Mini_Shop_Download_Components_Package_Tip", childrenWidgets.length), + "", + FineJOptionPane.OK_CANCEL_OPTION + ); + if (result == JOptionPane.OK_OPTION) { fireStartEvent(null); action.install(); } else {