From d7f7d1985c759821b99179074aca9c1d6082ddbe Mon Sep 17 00:00:00 2001 From: "Destiny.Lin" Date: Tue, 13 Dec 2022 15:29:24 +0800 Subject: [PATCH 1/5] =?UTF-8?q?REPORT-85953=20=E3=80=90=E4=B8=8A=E6=B5=B7?= =?UTF-8?q?=E7=90=86=E5=85=89=E3=80=91=E6=A8=A1=E6=9D=BF=E4=BF=9D=E5=AD=98?= =?UTF-8?q?=E9=97=AE=E9=A2=98=20=E4=BF=9D=E5=AD=98=E7=9A=84=E6=97=B6?= =?UTF-8?q?=E5=80=99=E4=B8=8D=E5=85=81=E8=AE=B8=E8=A7=A6=E5=8F=91=E9=A2=84?= =?UTF-8?q?=E8=A7=88=E4=BA=8B=E4=BB=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- designer-realize/src/main/java/com/fr/start/MainDesigner.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/designer-realize/src/main/java/com/fr/start/MainDesigner.java b/designer-realize/src/main/java/com/fr/start/MainDesigner.java index 02116dc41c..d90ceb0556 100644 --- a/designer-realize/src/main/java/com/fr/start/MainDesigner.java +++ b/designer-realize/src/main/java/com/fr/start/MainDesigner.java @@ -368,7 +368,7 @@ public class MainDesigner extends BaseDesigner { @Override protected void upButtonClickEvent() { JTemplate jt = HistoryTemplateListCache.getInstance().getCurrentEditingTemplate(); - if (jt == null) { + if (jt == null || jt.isSaving()) { return; } WebPreviewUtils.preview(jt); From 8bac6c7db46074f099562157a3f56413dd0dfaf4 Mon Sep 17 00:00:00 2001 From: "Destiny.Lin" Date: Tue, 13 Dec 2022 21:11:11 +0800 Subject: [PATCH 2/5] =?UTF-8?q?REPORT-82895=20=E5=8D=95=E5=85=83=E6=A0=BC?= =?UTF-8?q?=E9=87=8D=E5=A4=8D=E5=86=BB=E7=BB=93=E4=BC=98=E5=8C=96=20?= =?UTF-8?q?=E5=86=B3=E7=AD=96=E6=8A=A5=E8=A1=A8=E7=9B=B8=E5=85=B3=E7=BB=93?= =?UTF-8?q?=E5=B0=BE=E5=86=BB=E7=BB=93=E5=AE=9E=E7=8E=B0=EF=BC=8C=E7=95=8C?= =?UTF-8?q?=E9=9D=A2=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/fr/design/gui/ispinner/UISpinner.java | 10 ++++++++++ .../report/freeze/FreezeAndRepeatPane.java | 18 +++++++++++++++--- .../freeze/RepeatAndFreezeSettingPane.java | 10 +++++----- 3 files changed, 30 insertions(+), 8 deletions(-) diff --git a/designer-base/src/main/java/com/fr/design/gui/ispinner/UISpinner.java b/designer-base/src/main/java/com/fr/design/gui/ispinner/UISpinner.java index 18207011fe..a19db05060 100644 --- a/designer-base/src/main/java/com/fr/design/gui/ispinner/UISpinner.java +++ b/designer-base/src/main/java/com/fr/design/gui/ispinner/UISpinner.java @@ -321,6 +321,16 @@ public class UISpinner extends JPanel implements UIObserver, GlobalNameObserver textField.setMaxValue(maxValue); } + /** + * 设置最小值 + * + * @param minValue 最小值 + */ + public void setMinValue(double minValue) { + this.minValue = minValue; + textField.setMinValue(minValue); + } + private void componentInitListeners() { preButton.addActionListener(new ActionListener() { @Override diff --git a/designer-realize/src/main/java/com/fr/design/report/freeze/FreezeAndRepeatPane.java b/designer-realize/src/main/java/com/fr/design/report/freeze/FreezeAndRepeatPane.java index c0af78bf06..cf32a24b65 100644 --- a/designer-realize/src/main/java/com/fr/design/report/freeze/FreezeAndRepeatPane.java +++ b/designer-realize/src/main/java/com/fr/design/report/freeze/FreezeAndRepeatPane.java @@ -32,14 +32,18 @@ public abstract class FreezeAndRepeatPane extends BasicBeanPane { ((UISpinner) start).addChangeListener(new ChangeListener() { @Override public void stateChanged(ChangeEvent e) { - if (end instanceof UISpinner) { - ((UISpinner) end).setValue(Math.max(((UISpinner) start).getValue(), ((UISpinner) end).getValue())); - } + updateEndValue(); } }); } if (end instanceof UISpinner) { end.setPreferredSize(size); + ((UISpinner) end).addChangeListener(new ChangeListener() { + @Override + public void stateChanged(ChangeEvent e) { + updateEndValue(); + } + }); } this.setLayout(FRGUIPaneFactory.createBoxFlowLayout()); this.add(start); @@ -81,4 +85,12 @@ public abstract class FreezeAndRepeatPane extends BasicBeanPane { } } + + private void updateEndValue() { + if (end instanceof UISpinner) { + ((UISpinner) end).setMinValue(((UISpinner) start).getValue()); + ((UISpinner) end).setValue(((UISpinner) end).getValue()); + + } + } } \ No newline at end of file diff --git a/designer-realize/src/main/java/com/fr/design/report/freeze/RepeatAndFreezeSettingPane.java b/designer-realize/src/main/java/com/fr/design/report/freeze/RepeatAndFreezeSettingPane.java index 11a3aba60c..be7606a22d 100644 --- a/designer-realize/src/main/java/com/fr/design/report/freeze/RepeatAndFreezeSettingPane.java +++ b/designer-realize/src/main/java/com/fr/design/report/freeze/RepeatAndFreezeSettingPane.java @@ -242,6 +242,7 @@ public class RepeatAndFreezeSettingPane extends BasicPane { JPanel pagePanel = new JPanel(FRGUIPaneFactory.createBorderLayout()); JPanel repeatHeadPanel = FRGUIPaneFactory.createNColumnGridInnerContainer_S_Pane(1); JPanel repeatFootPanel = FRGUIPaneFactory.createNColumnGridInnerContainer_S_Pane(1); + tabbedPane = new UITabbedPane(); //添加上方的边界线 addBorder(repeatHeadPanel, REPEAT_AND_FROZEN_HEAD); @@ -268,14 +269,12 @@ public class RepeatAndFreezeSettingPane extends BasicPane { outfreezePanel.add(initPageFrozenPane(), BorderLayout.NORTH); outfreezePanel.add(initPageFrozenFootPane(),BorderLayout.CENTER); + tabbedPane.addTab(Toolkit.i18nText("Fine-Design_Basic_M_Page_Preview"), pagePanel); JPanel writePanel = FRGUIPaneFactory.createTitledBorderPane(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Report_Engine_Frozen")); addWriteFrozen(writePanel); - tabbedPane = new UITabbedPane(); //去除对应的焦点虚线边框 tabbedPane.setFocusable(false); - tabbedPane.addTab(Toolkit.i18nText("Fine-Design_Basic_M_Page_Preview"), pagePanel); - tabbedPane.addTab(Toolkit.i18nText("Fine-Design_Basic_M_Write_Preview"), writePanel); this.add(tabbedPane); initPageRwoListener(); initPageColListener(); @@ -322,6 +321,7 @@ public class RepeatAndFreezeSettingPane extends BasicPane { protected void addWriteFrozen(JPanel freezePanel) { freezePanel.add(initWriteFrozenPane(), BorderLayout.CENTER); + tabbedPane.addTab(Toolkit.i18nText("Fine-Design_Basic_M_Write_Preview"), freezePanel); } protected void addFootColStart(JPanel repeatPanel) { @@ -509,7 +509,7 @@ public class RepeatAndFreezeSettingPane extends BasicPane { } this.usePageHeadFrozenRCheckBox.setSelected(attribute.isUsePageFrozenRow()); - this.usePageFootFrozenRCheckBox.setSelected(attribute.isUsePageFrozenRow()); + this.usePageFootFrozenRCheckBox.setSelected(attribute.isUsePageFootRowFrozen()); this.freezePageRowPane.setEnabled(attribute.isUsePageFrozenRow()); } @@ -536,7 +536,7 @@ public class RepeatAndFreezeSettingPane extends BasicPane { } this.usePageHeadFrozenCCheckBox.setSelected(attribute.isUsePageFrozenColumn()); - this.usePageFootFrozenCCheckBox.setSelected(attribute.isUsePageFrozenColumn()); + this.usePageFootFrozenCCheckBox.setSelected(attribute.isUsePageFootColFrozen()); this.freezePageColPane.setEnabled(attribute.isUsePageFrozenColumn()); } From 303894c472f869d9083162ef95233bcd03a0a993 Mon Sep 17 00:00:00 2001 From: "Destiny.Lin" Date: Wed, 14 Dec 2022 10:37:57 +0800 Subject: [PATCH 3/5] =?UTF-8?q?REPORT-86364=20=E6=9C=8D=E5=8A=A1=E5=B9=B3?= =?UTF-8?q?=E5=8F=B0=E8=AE=BE=E8=AE=A1=E5=99=A8=E9=80=82=E9=85=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/fr/design/actions/help/AboutPane.java | 4 +-- .../platform/ServicePlatformAction.java | 29 +++++++++++++++++++ .../mainframe/toolbar/ToolBarMenuDock.java | 7 +++-- .../images/platform/platform_normal.svg | 3 ++ 4 files changed, 39 insertions(+), 4 deletions(-) create mode 100644 designer-base/src/main/java/com/fr/design/mainframe/platform/ServicePlatformAction.java create mode 100644 designer-base/src/main/resources/com/fr/design/images/platform/platform_normal.svg diff --git a/designer-base/src/main/java/com/fr/design/actions/help/AboutPane.java b/designer-base/src/main/java/com/fr/design/actions/help/AboutPane.java index 6158540888..d24665f69b 100644 --- a/designer-base/src/main/java/com/fr/design/actions/help/AboutPane.java +++ b/designer-base/src/main/java/com/fr/design/actions/help/AboutPane.java @@ -126,8 +126,8 @@ public class AboutPane extends JPanel { if (GeneralContext.getLocale().equals(Locale.TAIWAN)) { return; } - boxCenterAlignmentPane = new BoxCenterAligmentPane("QQ: " + CloudCenter.getInstance().acquireUrlByKind("help.qq")); - contentPane.add(boxCenterAlignmentPane); + JPanel servicePlatformPane = getURLActionPane(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Service_Platform")+ ":", CloudCenter.getInstance().acquireUrlByKind("service.platform")); + contentPane.add(servicePlatformPane); } // 是否显示鸣谢面板 diff --git a/designer-base/src/main/java/com/fr/design/mainframe/platform/ServicePlatformAction.java b/designer-base/src/main/java/com/fr/design/mainframe/platform/ServicePlatformAction.java new file mode 100644 index 0000000000..b9fb5fd0e1 --- /dev/null +++ b/designer-base/src/main/java/com/fr/design/mainframe/platform/ServicePlatformAction.java @@ -0,0 +1,29 @@ +package com.fr.design.mainframe.platform; + +import com.fr.design.actions.UpdateAction; +import com.fr.design.i18n.Toolkit; +import com.fr.general.CloudCenter; + +import java.awt.Desktop; +import java.awt.event.ActionEvent; +import java.net.URI; + +/** + * @author Destiny.Lin + * @version 11.0 + * created by Destiny.Lin on 2022-12-14 + */ +public class ServicePlatformAction extends UpdateAction { + public ServicePlatformAction() { + this.setName(Toolkit.i18nText("Fine-Design_Basic_Service_Platform")); + this.setSmallIcon("/com/fr/design/images/platform/platform"); + } + + @Override + public void actionPerformed(ActionEvent e) { + try { + Desktop.getDesktop().browse(new URI(CloudCenter.getInstance().acquireUrlByKind("service.platform"))); + } catch (Exception exp) { + } + } +} diff --git a/designer-base/src/main/java/com/fr/design/mainframe/toolbar/ToolBarMenuDock.java b/designer-base/src/main/java/com/fr/design/mainframe/toolbar/ToolBarMenuDock.java index 904c281560..ba734af660 100644 --- a/designer-base/src/main/java/com/fr/design/mainframe/toolbar/ToolBarMenuDock.java +++ b/designer-base/src/main/java/com/fr/design/mainframe/toolbar/ToolBarMenuDock.java @@ -56,6 +56,7 @@ import com.fr.design.gui.itoolbar.UIToolbar; import com.fr.design.locale.impl.SupportLocaleImpl; import com.fr.design.mainframe.JTemplate; import com.fr.design.mainframe.ToolBarNewTemplatePane; +import com.fr.design.mainframe.platform.ServicePlatformAction; import com.fr.design.menu.MenuDef; import com.fr.design.menu.SeparatorDef; import com.fr.design.menu.ShortCut; @@ -571,9 +572,11 @@ public abstract class ToolBarMenuDock { if (AlphaFineConfigManager.isALPHALicAvailable()) { shortCuts.add(new AlphaFineAction()); } - + shortCuts.add(new EnvDetectorAction()); - + //服务平台 + shortCuts.add(new ServicePlatformAction()); + shortCuts.add(SeparatorDef.DEFAULT); if (DesignerEnvManager.getEnvManager().isOpenDebug()) { OSSupportCenter.buildAction(objects -> shortCuts.add(new FineUIAction()), SupportOSImpl.FINEUI); diff --git a/designer-base/src/main/resources/com/fr/design/images/platform/platform_normal.svg b/designer-base/src/main/resources/com/fr/design/images/platform/platform_normal.svg new file mode 100644 index 0000000000..ab95e95f3c --- /dev/null +++ b/designer-base/src/main/resources/com/fr/design/images/platform/platform_normal.svg @@ -0,0 +1,3 @@ + + + From 19e6c4206cb07fa440d162c0bb4bece0d8d2e782 Mon Sep 17 00:00:00 2001 From: "Destiny.Lin" Date: Wed, 14 Dec 2022 10:44:34 +0800 Subject: [PATCH 4/5] =?UTF-8?q?REPORT-86364=20=E6=9C=8D=E5=8A=A1=E5=B9=B3?= =?UTF-8?q?=E5=8F=B0=E8=AE=BE=E8=AE=A1=E5=99=A8=E9=80=82=E9=85=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/main/java/com/fr/design/actions/help/AboutPane.java | 2 +- .../fr/design/mainframe/platform/ServicePlatformAction.java | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/designer-base/src/main/java/com/fr/design/actions/help/AboutPane.java b/designer-base/src/main/java/com/fr/design/actions/help/AboutPane.java index d24665f69b..dbb7798f3b 100644 --- a/designer-base/src/main/java/com/fr/design/actions/help/AboutPane.java +++ b/designer-base/src/main/java/com/fr/design/actions/help/AboutPane.java @@ -126,7 +126,7 @@ public class AboutPane extends JPanel { if (GeneralContext.getLocale().equals(Locale.TAIWAN)) { return; } - JPanel servicePlatformPane = getURLActionPane(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Service_Platform")+ ":", CloudCenter.getInstance().acquireUrlByKind("service.platform")); + JPanel servicePlatformPane = getURLActionPane(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Service_Platform"), CloudCenter.getInstance().acquireUrlByKind("service.platform")); contentPane.add(servicePlatformPane); } diff --git a/designer-base/src/main/java/com/fr/design/mainframe/platform/ServicePlatformAction.java b/designer-base/src/main/java/com/fr/design/mainframe/platform/ServicePlatformAction.java index b9fb5fd0e1..214b355680 100644 --- a/designer-base/src/main/java/com/fr/design/mainframe/platform/ServicePlatformAction.java +++ b/designer-base/src/main/java/com/fr/design/mainframe/platform/ServicePlatformAction.java @@ -9,13 +9,15 @@ import java.awt.event.ActionEvent; import java.net.URI; /** + * 帮助-服务平台 + * * @author Destiny.Lin * @version 11.0 * created by Destiny.Lin on 2022-12-14 */ public class ServicePlatformAction extends UpdateAction { public ServicePlatformAction() { - this.setName(Toolkit.i18nText("Fine-Design_Basic_Service_Platform")); + this.setName(Toolkit.i18nText("Fine-Design_Basic_Service_Platform_Title")); this.setSmallIcon("/com/fr/design/images/platform/platform"); } From d34c6db4de185ca029a2e6d135ec9e22f3927ada Mon Sep 17 00:00:00 2001 From: "Destiny.Lin" Date: Wed, 14 Dec 2022 10:51:30 +0800 Subject: [PATCH 5/5] =?UTF-8?q?REPORT-86364=20=E6=9C=8D=E5=8A=A1=E5=B9=B3?= =?UTF-8?q?=E5=8F=B0=E8=AE=BE=E8=AE=A1=E5=99=A8=E9=80=82=E9=85=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../design/mainframe/platform/ServicePlatformAction.java | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/designer-base/src/main/java/com/fr/design/mainframe/platform/ServicePlatformAction.java b/designer-base/src/main/java/com/fr/design/mainframe/platform/ServicePlatformAction.java index 214b355680..7912354501 100644 --- a/designer-base/src/main/java/com/fr/design/mainframe/platform/ServicePlatformAction.java +++ b/designer-base/src/main/java/com/fr/design/mainframe/platform/ServicePlatformAction.java @@ -2,7 +2,9 @@ package com.fr.design.mainframe.platform; import com.fr.design.actions.UpdateAction; import com.fr.design.i18n.Toolkit; +import com.fr.design.utils.BrowseUtils; import com.fr.general.CloudCenter; +import com.fr.log.FineLoggerFactory; import java.awt.Desktop; import java.awt.event.ActionEvent; @@ -23,9 +25,6 @@ public class ServicePlatformAction extends UpdateAction { @Override public void actionPerformed(ActionEvent e) { - try { - Desktop.getDesktop().browse(new URI(CloudCenter.getInstance().acquireUrlByKind("service.platform"))); - } catch (Exception exp) { - } + BrowseUtils.browser(CloudCenter.getInstance().acquireUrlByKind("service.platform")); } }