Browse Source

Merge pull request #15203 in DESIGN/design from fbp/master to fbp/release

* commit 'cfe162b7da351692badb1071754527175fcf5f98':
  REPORT-138579 fix:esd工具条布局修复
  REPORT-138311 【fr-fbp冒烟】【数据源】关联数据集选择后预览 无法弹出参数的弹窗,直接报错或者空白
  无JIRA任务 改了前端bug,更新一波js
  无jira 启动页视觉图换新
  无jira 启动页视觉图换新
  REPORT-138690 fix: 富文本编辑器工具条缺失元素补充
fbp/release
superman 1 month ago
parent
commit
2616f4e8ec
  1. 4
      designer-base/src/main/java/com/fr/design/data/DesignTableDataManager.java
  2. 6
      designer-base/src/main/java/com/fr/design/data/tabledata/tabledatapane/DBTableDataPane.java
  3. 124
      designer-base/src/main/resources/com/fr/design/data/tabledata/datacenter/web/data-choose.main.js
  4. 4
      designer-realize/src/main/java/com/fanruan/boot/env/function/DesignDatasourceComponent.java
  5. 100
      designer-realize/src/main/java/com/fanruan/data/DesignTableDataConfigWrapper.java
  6. 11
      designer-realize/src/main/java/com/fr/design/cell/editor/RichTextToolBar.java
  7. BIN
      designer-realize/src/main/resources/com/fr/design/images/splash.png
  8. BIN
      designer-realize/src/main/resources/com/fr/design/images/splash@2x.png
  9. BIN
      designer-realize/src/main/resources/com/fr/design/images/splash@2x_en.png
  10. BIN
      designer-realize/src/main/resources/com/fr/design/images/splash@2x_zh.png
  11. BIN
      designer-realize/src/main/resources/com/fr/design/images/splash@2x_zh_TW.png
  12. BIN
      designer-realize/src/main/resources/com/fr/design/images/splash_en.png
  13. BIN
      designer-realize/src/main/resources/com/fr/design/images/splash_zh.png
  14. BIN
      designer-realize/src/main/resources/com/fr/design/images/splash_zh_TW.png

4
designer-base/src/main/java/com/fr/design/data/DesignTableDataManager.java

@ -622,6 +622,10 @@ public abstract class DesignTableDataManager {
private static boolean checkBean(PreviewSourceBean bean, TableData tableData) { private static boolean checkBean(PreviewSourceBean bean, TableData tableData) {
if (bean.getDataName().isEmpty()) { if (bean.getDataName().isEmpty()) {
if (tableData instanceof ConditionTableData || tableData instanceof RecursionTableData) { if (tableData instanceof ConditionTableData || tableData instanceof RecursionTableData) {
if (bean.getDataSource() instanceof TableDataSourceTailor.EmptyTableDataSource) {
// 用tabledata传的时候不能是EmptyTableDataSource,因此这里得重新弄个source
bean.setDataSource(new TableDataSourceTailor.TableDataOnlySource());
}
bean.getDataSource().putTableData(StringUtils.EMPTY, tableData); bean.getDataSource().putTableData(StringUtils.EMPTY, tableData);
return true; return true;
} }

6
designer-base/src/main/java/com/fr/design/data/tabledata/tabledatapane/DBTableDataPane.java

@ -342,13 +342,13 @@ public class DBTableDataPane extends AbstractTableDataPane<DBTableData> implemen
private void createToolbarEsdComponents(final UIToolbar editToolBar) { private void createToolbarEsdComponents(final UIToolbar editToolBar) {
this.esdSettingsLabel = new UILabel(Toolkit.i18nText("Fine-Design_ESD_Cache_Settings")); this.esdSettingsLabel = new UILabel(Toolkit.i18nText("Fine-Design_ESD_Cache_Settings"));
esdSettingsLabel.setBorder(new ScaledEmptyBorder(0, 6, 0,6)); esdSettingsLabel.setBorder(new ScaledEmptyBorder(0, 2, 0,2));
this.esdConfigOption = new UIComboBox(StrategyConfigFrom.values()); this.esdConfigOption = new UIComboBox(StrategyConfigFrom.values());
this.esdConfigOption.putClientProperty(COMBO_BOX_TYPE, ADAPTIVE_COMBO_BOX); this.esdConfigOption.putClientProperty(COMBO_BOX_TYPE, ADAPTIVE_COMBO_BOX);
this.esdEnabled = new UICheckBox(Toolkit.i18nText("Fine-Design_ESD_Enable_Cache")); this.esdEnabled = new UICheckBox(Toolkit.i18nText("Fine-Design_ESD_Enable_Cache"));
esdEnabled.setBorder(new ScaledEmptyBorder(0, 6, 0,6)); esdEnabled.setBorder(new ScaledEmptyBorder(0, 2, 0,2));
this.barErrorTips = new UILabel(); this.barErrorTips = new UILabel();
barErrorTips.setBorder(new ScaledEmptyBorder(0, 6, 0,6)); barErrorTips.setBorder(new ScaledEmptyBorder(0, 2, 0,2));
FineUIStyle.setStyle(barErrorTips, FineUIStyle.LABEL_WARNING_TIP); FineUIStyle.setStyle(barErrorTips, FineUIStyle.LABEL_WARNING_TIP);
this.barErrorTips.setVisible(false); this.barErrorTips.setVisible(false);

124
designer-base/src/main/resources/com/fr/design/data/tabledata/datacenter/web/data-choose.main.js

File diff suppressed because one or more lines are too long

4
designer-realize/src/main/java/com/fanruan/boot/env/function/DesignDatasourceComponent.java vendored

@ -12,6 +12,7 @@ import com.fanruan.config.impl.data.ConnectionConfigWriter;
import com.fanruan.config.impl.data.ConnectionConfigWriterFactory; import com.fanruan.config.impl.data.ConnectionConfigWriterFactory;
import com.fanruan.config.impl.data.TableDataConfigProviderFactory; import com.fanruan.config.impl.data.TableDataConfigProviderFactory;
import com.fanruan.data.ConnectionConfigWrapper; import com.fanruan.data.ConnectionConfigWrapper;
import com.fanruan.data.DesignTableDataConfigWrapper;
import com.fanruan.datasource.connection.processor.ElasticSearchConnectionProcessor; import com.fanruan.datasource.connection.processor.ElasticSearchConnectionProcessor;
import com.fanruan.datasource.connection.processor.FTPConnectionProcessor; import com.fanruan.datasource.connection.processor.FTPConnectionProcessor;
import com.fanruan.datasource.connection.processor.LocalFileConnectionProcessor; import com.fanruan.datasource.connection.processor.LocalFileConnectionProcessor;
@ -42,7 +43,6 @@ import com.fr.decision.webservice.v10.datasource.connection.processor.impl.JNDIC
import com.fr.decision.webservice.v10.datasource.dataset.processor.impl.DataSetProcessorFactory; import com.fr.decision.webservice.v10.datasource.dataset.processor.impl.DataSetProcessorFactory;
import com.fr.design.data.datapane.connect.LocalConnectionSource; import com.fr.design.data.datapane.connect.LocalConnectionSource;
import com.fr.design.data.tabledata.LocalTableDataSource; import com.fr.design.data.tabledata.LocalTableDataSource;
import com.fr.file.TableDataConfigWrapper;
import com.fr.workspace.server.repository.connection.ConnectionRepository; import com.fr.workspace.server.repository.connection.ConnectionRepository;
import com.fr.workspace.server.repository.connection.ConnectionWriterShell; import com.fr.workspace.server.repository.connection.ConnectionWriterShell;
import com.fr.workspace.server.repository.connection.LocalConnectionShell; import com.fr.workspace.server.repository.connection.LocalConnectionShell;
@ -83,7 +83,7 @@ public class DesignDatasourceComponent extends DatasourceComponent {
public void start() { public void start() {
// 服务器数据集与数据连接设计器这边先手动切为finedb存储,后续数据中心适配后再切为他们提供的wrapper // 服务器数据集与数据连接设计器这边先手动切为finedb存储,后续数据中心适配后再切为他们提供的wrapper
ConnectionConfigProviderFactory.registerConnectionConfigProvider(ConnectionConfigWrapper.getInstance()); ConnectionConfigProviderFactory.registerConnectionConfigProvider(ConnectionConfigWrapper.getInstance());
TableDataConfigProviderFactory.getInstance().registerTableDataConfigProvider(new TableDataConfigWrapper()); TableDataConfigProviderFactory.getInstance().registerTableDataConfigProvider(new DesignTableDataConfigWrapper());
registerDriverClassLoader(); registerDriverClassLoader();
ConnectionConfigWriterFactory.registerConnectionConfigWriter((ConnectionConfigWriter) ConnectionConfigProviderFactory.getConfigProvider()); ConnectionConfigWriterFactory.registerConnectionConfigWriter((ConnectionConfigWriter) ConnectionConfigProviderFactory.getConfigProvider());
Carina.getApplicationContext().singleton(ConnectionWriterShell.class).set(ConnectionConfigWriterFactory.getConfigWriter()); Carina.getApplicationContext().singleton(ConnectionWriterShell.class).set(ConnectionConfigWriterFactory.getConfigWriter());

100
designer-realize/src/main/java/com/fanruan/data/DesignTableDataConfigWrapper.java

@ -0,0 +1,100 @@
package com.fanruan.data;
import com.fanruan.config.impl.data.TableDataConfigProvider;
import com.fr.base.TableData;
import com.fr.decision.webservice.bean.dataset.ServerDataSetBean;
import com.fr.design.data.datapane.preview.ConnectionInfoBeanHelper;
import com.fr.design.data.datapane.preview.TableDataBeanHelper;
import com.fr.file.TableDataConfig;
import com.fr.log.FineLoggerFactory;
import com.fr.transaction.Configurations;
import com.fr.transaction.WorkerAdaptor;
import com.fr.workspace.WorkContext;
import com.fr.workspace.server.repository.tabledata.TableDataRepository;
import org.jetbrains.annotations.Nullable;
import java.util.Map;
/**
* 设计器的TableData配置Wrapper
* <p>防止底层错误调用</p>
*
* @author Destiny.Lin
* @since 11.0
* Created on 2024/10/25
*/
public class DesignTableDataConfigWrapper implements TableDataConfigProvider {
@Override
public Map<String, TableData> getTableDatas() {
return TableDataConfig.getInstance().getTableDatas();
}
@Override
public void removeTableData(String tableDataName) {
Configurations.update(new WorkerAdaptor(TableDataConfig.class) {
@Override
public void run() {
TableDataConfig.getInstance().removeTableData(tableDataName);
}
});
}
@Nullable
@Override
public TableData getTableData(String name) {
if (WorkContext.getCurrent().isLocal()) {
return TableDataConfig.getInstance().getTableData(name);
}
ServerDataSetBean bean = TableDataRepository.getInstance().getTableData(name);
try {
if (bean == null) {
return null;
}
return TableDataBeanHelper.getTableDataSet(ConnectionInfoBeanHelper.getCurrentConnectionMap(), bean.getDatasetType(), bean.getDatasetData());
} catch (Exception e) {
FineLoggerFactory.getLogger().error(e.getMessage(), e);
return null;
}
}
@Override
public void addTableData(String name, TableData tableData) {
Configurations.update(new WorkerAdaptor(TableDataConfig.class) {
@Override
public void run() {
TableDataConfig.getInstance().addTableData(name, tableData);
}
});
}
@Override
public void renameTableData(String oldName, String newName) {
Configurations.update(new WorkerAdaptor(TableDataConfig.class) {
@Override
public void run() {
TableDataConfig.getInstance().renameTableData(oldName, newName);
}
});
}
@Override
public void updateTableData(String tableDataName, TableData tableData) {
Configurations.update(new WorkerAdaptor(TableDataConfig.class) {
@Override
public void run() {
TableDataConfig.getInstance().removeTableData(tableDataName);
TableDataConfig.getInstance().addTableData(tableDataName, tableData);
}
});
}
@Override
public void removeAllTableData() {
Configurations.update(new WorkerAdaptor(TableDataConfig.class) {
@Override
public void run() {
TableDataConfig.getInstance().removeAllTableData();
}
});
}
}

11
designer-realize/src/main/java/com/fr/design/cell/editor/RichTextToolBar.java

@ -108,7 +108,7 @@ public class RichTextToolBar extends BasicPane {
fontNameComboBox = new UIComboBox(DesignUtils.getAvailableFontFamilyNames4Report()); fontNameComboBox = new UIComboBox(DesignUtils.getAvailableFontFamilyNames4Report());
fontSizeComboBox = new UIComboBox(FRFontPane.getFontSizes()); fontSizeComboBox = new UIComboBox(FRFontPane.getFontSizes());
colorSelectPane = new UIToolbarColorButton(new LazyIcon("foreground")); colorSelectPane = new UIToolbarColorButton(new LazyIcon("foreground"));
colorSelectPane.set4Toolbar(); setColorSelectPaneStyle();
bold = new UIToggleButton(new LazyIcon("bold")); bold = new UIToggleButton(new LazyIcon("bold"));
italic = new UIToggleButton(new LazyIcon("italic")); italic = new UIToggleButton(new LazyIcon("italic"));
@ -127,10 +127,19 @@ public class RichTextToolBar extends BasicPane {
bindListener(); bindListener();
} }
private void setColorSelectPaneStyle() {
colorSelectPane.set4Toolbar();
if (colorSelectPane.getLeftButton() != null && colorSelectPane.getRightButton() != null) {
colorSelectPane.getLeftButton().setBackground(null);
colorSelectPane.getRightButton().setBackground(null);
}
}
private void addIntoToolBar() { private void addIntoToolBar() {
toolbar.add(bold); toolbar.add(bold);
toolbar.add(italic); toolbar.add(italic);
toolbar.add(underline); toolbar.add(underline);
toolbar.add(colorSelectPane);
toolbar.add(subPane); toolbar.add(subPane);
toolbar.add(superPane); toolbar.add(superPane);
toolbar.add(formulaPane); toolbar.add(formulaPane);

BIN
designer-realize/src/main/resources/com/fr/design/images/splash.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 253 KiB

After

Width:  |  Height:  |  Size: 252 KiB

BIN
designer-realize/src/main/resources/com/fr/design/images/splash@2x.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 870 KiB

After

Width:  |  Height:  |  Size: 869 KiB

BIN
designer-realize/src/main/resources/com/fr/design/images/splash@2x_en.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 870 KiB

After

Width:  |  Height:  |  Size: 869 KiB

BIN
designer-realize/src/main/resources/com/fr/design/images/splash@2x_zh.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 870 KiB

After

Width:  |  Height:  |  Size: 868 KiB

BIN
designer-realize/src/main/resources/com/fr/design/images/splash@2x_zh_TW.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 870 KiB

After

Width:  |  Height:  |  Size: 868 KiB

BIN
designer-realize/src/main/resources/com/fr/design/images/splash_en.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 253 KiB

After

Width:  |  Height:  |  Size: 252 KiB

BIN
designer-realize/src/main/resources/com/fr/design/images/splash_zh.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 252 KiB

After

Width:  |  Height:  |  Size: 252 KiB

BIN
designer-realize/src/main/resources/com/fr/design/images/splash_zh_TW.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 252 KiB

After

Width:  |  Height:  |  Size: 252 KiB

Loading…
Cancel
Save