diff --git a/designer-base/src/main/java/com/fr/design/file/HistoryTemplateListCache.java b/designer-base/src/main/java/com/fr/design/file/HistoryTemplateListCache.java index cb68bb6e4..466e919b7 100644 --- a/designer-base/src/main/java/com/fr/design/file/HistoryTemplateListCache.java +++ b/designer-base/src/main/java/com/fr/design/file/HistoryTemplateListCache.java @@ -422,5 +422,4 @@ public class HistoryTemplateListCache implements CallbackEvent { jt.refreshResource(); } } - } diff --git a/designer-base/src/main/java/com/fr/design/mainframe/DesignerFrame.java b/designer-base/src/main/java/com/fr/design/mainframe/DesignerFrame.java index 2cf8d8c35..e52d4333f 100644 --- a/designer-base/src/main/java/com/fr/design/mainframe/DesignerFrame.java +++ b/designer-base/src/main/java/com/fr/design/mainframe/DesignerFrame.java @@ -1105,7 +1105,17 @@ public class DesignerFrame extends JFrame implements JTemplateActionListener, Ta int index = HistoryTemplateListCache.getInstance().contains(tplFile); if (index != -1) { JTemplate jt = HistoryTemplateListCache.getInstance().getHistoryList().get(index); - if (!(jt instanceof JVirtualTemplate)) { + if (jt instanceof JVirtualTemplate) { + // 如果是JVirtualTemplate 创建真实JTemplate + JTemplate realJTemplate = JTemplateFactory.createJTemplate(tplFile); + if (realJTemplate == null) { + return; + } + // 由JVirtualTemplate激活真实JTemplate 本质在historyList中进行替换 + // 同时 realJTemplate被管理起来 不需要主动释放 关闭时会自动释放 + jt.activeJTemplate(index, realJTemplate); + return; + } else { jt.activeOldJTemplate(); return; } diff --git a/designer-realize/src/main/java/com/fr/design/mainframe/messagecollect/solid/SolidCollector.java b/designer-realize/src/main/java/com/fr/design/mainframe/messagecollect/solid/SolidCollector.java index 194ca75d9..974f75dd3 100644 --- a/designer-realize/src/main/java/com/fr/design/mainframe/messagecollect/solid/SolidCollector.java +++ b/designer-realize/src/main/java/com/fr/design/mainframe/messagecollect/solid/SolidCollector.java @@ -58,8 +58,9 @@ public class SolidCollector { HttpToolbox.post(url, params); deleteSolidFile(); + + FineLoggerFactory.getLogger().info("send solid content to cloud center success."); } - FineLoggerFactory.getLogger().info("send solid content to cloud center success."); } catch (Exception e) { FineLoggerFactory.getLogger().info(e.getMessage(), e); } finally {