From 2d490cacb658cac0054e36e9db7871756cdf4309 Mon Sep 17 00:00:00 2001 From: Starryi Date: Tue, 24 Aug 2021 18:41:35 +0800 Subject: [PATCH] =?UTF-8?q?REPORT-57974=20=E3=80=90=E4=B8=BB=E9=A2=98?= =?UTF-8?q?=E5=88=87=E6=8D=A2=E3=80=91=E6=96=B0=E5=BB=BA=E6=A8=A1=E6=9D=BF?= =?UTF-8?q?=E6=97=B6=EF=BC=8C=E6=B2=A1=E6=8C=89=E7=85=A7=E8=AE=BE=E7=BD=AE?= =?UTF-8?q?=E7=9A=84=E6=A8=A1=E6=9D=BF=E4=B8=BB=E9=A2=98=E6=9D=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 【问题原因】 补充新建模版后根据主题修改数据模型的逻辑 【改动思路】 同上 --- .../src/main/java/com/fr/design/mainframe/JTemplate.java | 2 +- .../src/main/java/com/fr/design/mainframe/JForm.java | 7 ++++++- .../src/main/java/com/fr/design/mainframe/JWorkBook.java | 7 +++++++ 3 files changed, 14 insertions(+), 2 deletions(-) diff --git a/designer-base/src/main/java/com/fr/design/mainframe/JTemplate.java b/designer-base/src/main/java/com/fr/design/mainframe/JTemplate.java index 1eebed739..543a2c3ca 100644 --- a/designer-base/src/main/java/com/fr/design/mainframe/JTemplate.java +++ b/designer-base/src/main/java/com/fr/design/mainframe/JTemplate.java @@ -1713,7 +1713,7 @@ public abstract class JTemplate> return runtimeId; } - private void setUpTheme4NewTemplate() { + protected void setUpTheme4NewTemplate() { TemplateTheme theme = getUsingTemplateThemeConfig().cachedFetchTheme4NewTemplate(); TemplateThemeAttrMark themeAttrMark = template.getAttrMark(TemplateThemeAttrMark.XML_TAG); if (themeAttrMark == null) { diff --git a/designer-form/src/main/java/com/fr/design/mainframe/JForm.java b/designer-form/src/main/java/com/fr/design/mainframe/JForm.java index 09808b7bb..60463b312 100644 --- a/designer-form/src/main/java/com/fr/design/mainframe/JForm.java +++ b/designer-form/src/main/java/com/fr/design/mainframe/JForm.java @@ -140,7 +140,6 @@ public class JForm extends JTemplate implements BaseJForm implements BaseJForm getUsingTemplateThemeConfig() { return getTarget().getUsingTemplateThemeConfig(); diff --git a/designer-realize/src/main/java/com/fr/design/mainframe/JWorkBook.java b/designer-realize/src/main/java/com/fr/design/mainframe/JWorkBook.java index 333c7415b..3359513ce 100644 --- a/designer-realize/src/main/java/com/fr/design/mainframe/JWorkBook.java +++ b/designer-realize/src/main/java/com/fr/design/mainframe/JWorkBook.java @@ -1269,6 +1269,13 @@ public class JWorkBook extends JTemplate { } } + @Override + protected void setUpTheme4NewTemplate() { + super.setUpTheme4NewTemplate(); + getTarget().setTemplateTheme(getTarget().getTemplateTheme()); + } + + @Override public TemplateThemeConfig getUsingTemplateThemeConfig() { return getTarget().getUsingTemplateThemeConfig();