Browse Source

Merge remote-tracking branch 'origin/fbp/master' into fbp/master

fbp/master
Destiny.Lin 2 months ago
parent
commit
d291b4c2e3
  1. 1
      build.gradle
  2. 8
      designer-base/src/main/java/com/fr/design/gui/controlpane/JControlPane.java
  3. 4
      designer-base/src/main/java/com/fr/design/gui/controlpane/UIControlPane.java
  4. 4
      designer-base/src/main/java/com/fr/design/hyperlink/popup/MobilePopupRegularPane.java
  5. 14
      designer-base/src/main/java/com/fr/design/hyperlink/popup/StyleSettingPane.java
  6. 2
      designer-base/src/main/java/com/fr/design/roleAuthority/ReportAndFSManagePane.java
  7. 40
      designer-base/src/main/java/com/fr/design/style/background/impl/NullBackgroundPane.java
  8. 6
      designer-base/src/main/java/com/fr/design/write/submit/DBManipulationPane.java
  9. 6
      designer-base/src/main/resources/com/fine/theme/icon/formExport.svg
  10. 2
      designer-base/src/main/resources/com/fine/theme/icon/saveFile.svg
  11. 2
      designer-base/src/main/resources/com/fine/theme/icon/saveFile_disable.svg
  12. 1
      designer-base/src/main/resources/com/fine/theme/light/ui/fine_light.icon.json
  13. 2
      designer-chart/src/main/java/com/fr/design/mainframe/chart/gui/ChartTypeButtonPane.java
  14. 3
      designer-chart/src/main/java/com/fr/design/mainframe/chart/gui/type/ChartImagePane.java
  15. BIN
      designer-chart/src/main/resources/com/fr/design/images/background/null_background.png
  16. 105
      designer-realize/src/main/java/com/fanruan/boot/adaptation/DesignServerSupportModule.java
  17. 5
      designer-realize/src/main/java/com/fanruan/boot/adaptation/ReportAdaptationComponent.java
  18. 3
      designer-realize/src/main/java/com/fr/design/actions/file/newReport/NewPolyReportAction.java

1
build.gradle

@ -110,6 +110,7 @@ allprojects {
implementation 'com.fr.datasource:fine-datasource-core:' + fdlVersion
implementation 'com.fr.datasource:fine-datasource-web:' + fdlVersion
implementation 'com.fr.decision:decision-i18n:' + frVersion
implementation 'com.fr.decision:decision-report:' + frVersion
implementation 'com.fr.report:engine-report:' + frDevVersion
implementation 'com.fr.report:engine-x:' + frDevVersion
implementation 'com.fr.report:engine-chart:' + frDevVersion

8
designer-base/src/main/java/com/fr/design/gui/controlpane/JControlPane.java

@ -212,10 +212,10 @@ abstract class JControlPane extends BasicPane implements UnrepeatedNameHelper, S
}
/**
* 刷新 NameableCreator
*
* @param creators 生成器
*/
* 刷新 NameableCreator
*
* @param creators 生成器
*/
public void refreshNameableCreator(NameableCreator[] creators) {
this.creators = creators;
shorts = this.createShortcuts();

4
designer-base/src/main/java/com/fr/design/gui/controlpane/UIControlPane.java

@ -243,8 +243,8 @@ public abstract class UIControlPane extends JControlPane {
}
/**
* 是否需要隐藏popupEditDialog
*/
* 是否需要隐藏popupEditDialog
*/
protected boolean needToHidePopupEditDialog() {
// 检查是否有子弹窗,如果有,则不隐藏
for (Window window : popupEditDialog.getOwnedWindows()) {

4
designer-base/src/main/java/com/fr/design/hyperlink/popup/MobilePopupRegularPane.java

@ -45,7 +45,7 @@ public class MobilePopupRegularPane extends BasicPane {
spinnerGroupPane = this.createSpinnerPane();
this.add(column(LayoutConstants.VERTICAL_GAP,
cell(this.createRadioButtonGroupPane()),
row(flex(1), cell(spinnerGroupPane).weight(3))
row(flex(1.5), cell(spinnerGroupPane).weight(3))
).getComponent());
}
@ -62,7 +62,7 @@ public class MobilePopupRegularPane extends BasicPane {
radioButtons.add(autoRadio);
radiosPane.add(row(30, cell(customRadio), cell(autoRadio), flex()).getComponent());
return row(cell(new UILabel(this.label, FineUIStyle.LABEL_SECONDARY)).weight(1), cell(radiosPane).weight(3)).getComponent();
return row(cell(new UILabel(this.label, FineUIStyle.LABEL_SECONDARY)).weight(1.5), cell(radiosPane).weight(3)).getComponent();
}
private ActionListener radioActionListener = new ActionListener() {

14
designer-base/src/main/java/com/fr/design/hyperlink/popup/StyleSettingPane.java

@ -83,9 +83,9 @@ public class StyleSettingPane extends BasicBeanPane<MobilePopupHyperlink> {
UILabel borderLabel = new UILabel(Toolkit.i18nText("FR-Plugin-Designer_Mobile_Popup_Border"));
borderPane.add(column(LayoutConstants.VERTICAL_GAP,
row(cell(borderLabel).weight(1), cell(new UILabel(Toolkit.i18nText("FR-Plugin-Designer_Mobile_Popup_Line"), FineUIStyle.LABEL_SECONDARY)).weight(1), cell(borderType).weight(2), flex(3)),
row(flex(1), cell(new UILabel(Toolkit.i18nText("FR-Plugin-Designer_Mobile_Popup_Colors"), FineUIStyle.LABEL_SECONDARY)).weight(1), cell(borderColor).weight(2), flex(3)),
row(flex(1), cell(new UILabel(Toolkit.i18nText("FR-Plugin-Designer_Mobile_Popup_Radius"), FineUIStyle.LABEL_SECONDARY)).weight(1), cell(borderRadiusSpinner).weight(2), flex(3))
row(cell(borderLabel).weight(1), cell(new UILabel(Toolkit.i18nText("FR-Plugin-Designer_Mobile_Popup_Line"), FineUIStyle.LABEL_SECONDARY)).weight(1.5), cell(borderType).weight(2), flex(2.5)),
row(flex(1), cell(new UILabel(Toolkit.i18nText("FR-Plugin-Designer_Mobile_Popup_Colors"), FineUIStyle.LABEL_SECONDARY)).weight(1.5), cell(borderColor).weight(2), flex(2.5)),
row(flex(1), cell(new UILabel(Toolkit.i18nText("FR-Plugin-Designer_Mobile_Popup_Radius"), FineUIStyle.LABEL_SECONDARY)).weight(1.5), cell(borderRadiusSpinner).weight(2), flex(2.5))
).getComponent());
return borderPane;
}
@ -102,8 +102,8 @@ public class StyleSettingPane extends BasicBeanPane<MobilePopupHyperlink> {
JLabel bgLabel = new JLabel(Toolkit.i18nText("FR-Plugin-Designer_Mobile_Popup_Background"));
bgPane.add(column(LayoutConstants.VERTICAL_GAP,
row(cell(bgLabel).weight(1), cell(new UILabel(Toolkit.i18nText("FR-Plugin-Designer_Mobile_Popup_Colors"), FineUIStyle.LABEL_SECONDARY)).weight(1), cell(bgColor).weight(2), flex(3)),
row(flex(1), cell(new UILabel(Toolkit.i18nText("FR-Plugin-Designer_Mobile_Popup_Opacity"), FineUIStyle.LABEL_SECONDARY)).weight(1), cell(transparencyPane).weight(3), flex(2))
row(cell(bgLabel).weight(1), cell(new UILabel(Toolkit.i18nText("FR-Plugin-Designer_Mobile_Popup_Colors"), FineUIStyle.LABEL_SECONDARY)).weight(1.5), cell(bgColor).weight(2), flex(2.5)),
row(flex(1), cell(new UILabel(Toolkit.i18nText("FR-Plugin-Designer_Mobile_Popup_Opacity"), FineUIStyle.LABEL_SECONDARY)).weight(1.5), cell(transparencyPane).weight(3), flex(1.5))
).getComponent());
return bgPane;
}
@ -117,9 +117,9 @@ public class StyleSettingPane extends BasicBeanPane<MobilePopupHyperlink> {
sizePane.add(column(LayoutConstants.VERTICAL_GAP,
row(
column(LayoutConstants.VERTICAL_GAP, cell(sizeLabel), flex()).weight(1),
cell(mobileRegularPane).weight(4), flex(2)
cell(mobileRegularPane).weight(4.5), flex(1.5)
),
row(flex(1), cell(padRegularPane).weight(4), flex(2))
row(flex(1), cell(padRegularPane).weight(4.5), flex(1.5))
).getComponent());
return sizePane;
}

2
designer-base/src/main/java/com/fr/design/roleAuthority/ReportAndFSManagePane.java

@ -109,7 +109,7 @@ public class ReportAndFSManagePane extends DockingView implements Prepare4DataSo
cell(scrollPane).weight(1)
).getComponent());
this.add(jPanel, BorderLayout.CENTER);
jPanel.setBorder(new ScaledEmptyBorder(0, 4, 4, 4));
jPanel.setBorder(new ScaledEmptyBorder(0, 12, 4, 4));
registerDSChangeListener();
}

40
designer-base/src/main/java/com/fr/design/style/background/impl/NullBackgroundPane.java

@ -1,20 +1,15 @@
package com.fr.design.style.background.impl;
import com.fine.theme.utils.FineUIScale;
import com.fr.design.gui.ilable.UILabel;
import com.fr.design.layout.FRGUIPaneFactory;
import com.fr.design.style.background.BackgroundDetailPane;
import com.fr.general.Background;
import com.fr.general.locale.image.I18nImage;
import javax.swing.*;
import javax.swing.event.ChangeListener;
import java.awt.BorderLayout;
import java.awt.Dimension;
import java.awt.Graphics;
import java.awt.Image;
import static com.fine.swing.ui.layout.Layouts.cell;
import static com.fine.swing.ui.layout.Layouts.column;
@ -25,23 +20,14 @@ import static com.fine.swing.ui.layout.Layouts.flex;
*/
public class NullBackgroundPane extends BackgroundDetailPane {
private static final String NULL_BACKGROUND = "/com/fr/design/images/background/null_background.png";
private static final Image DEFAULT_NULL_BACKGROUND_IMAGE;
static {
DEFAULT_NULL_BACKGROUND_IMAGE = I18nImage.getImage(NULL_BACKGROUND);
}
public NullBackgroundPane() {
this.setLayout(FRGUIPaneFactory.createBorderLayout());
UILabel centerLabel = new UILabel(
com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Background_Background_Is_Null"));
ImagePanel imagePane = new ImagePanel();
JPanel pane = column(
10,
flex(),
cell(imagePane),
cell(centerLabel),
flex()
).getComponent();
@ -60,30 +46,4 @@ public class NullBackgroundPane extends BackgroundDetailPane {
public void addChangeListener(ChangeListener changeListener) {
// do nothing.
}
/**
* 水平居中绘制 Image
*/
public class ImagePanel extends JPanel {
public ImagePanel() {
}
@Override
public void paintComponent(Graphics g) {
super.paintComponent(g);
if (DEFAULT_NULL_BACKGROUND_IMAGE != null) {
int x = (this.getWidth() - DEFAULT_NULL_BACKGROUND_IMAGE.getWidth(null)) / 2;
g.drawImage(DEFAULT_NULL_BACKGROUND_IMAGE, x, 0, this);
}
}
@Override
public Dimension getPreferredSize() {
if (DEFAULT_NULL_BACKGROUND_IMAGE == null) {
return super.getPreferredSize();
}
return FineUIScale.scale(new Dimension(DEFAULT_NULL_BACKGROUND_IMAGE.getWidth(null), DEFAULT_NULL_BACKGROUND_IMAGE.getHeight(null)));
}
}
}

6
designer-base/src/main/java/com/fr/design/write/submit/DBManipulationPane.java

@ -754,7 +754,7 @@ public class DBManipulationPane extends BasicBeanPane<DBManipulation> {
return super.stopCellEditing();
}
});
((DefaultCellEditor) column1.getCellEditor()).setClickCountToStart(1);
((DefaultCellEditor) column1.getCellEditor()).setClickCountToStart(2);
//设置Column 2的Editor
column2.setCellEditor(new ColumnValueEditor());
@ -963,12 +963,12 @@ public class DBManipulationPane extends BasicBeanPane<DBManipulation> {
}
/*
* 击以编辑
* 击以编辑
*/
@Override
public boolean isCellEditable(EventObject anEvent) {
if (anEvent instanceof MouseEvent) {
return ((MouseEvent) anEvent).getClickCount() >= 1;
return ((MouseEvent) anEvent).getClickCount() >= 2;
}
return true;
}

6
designer-base/src/main/resources/com/fine/theme/icon/formExport.svg

@ -0,0 +1,6 @@
<svg width="31" height="29" viewBox="0 0 31 29" fill="none" xmlns="http://www.w3.org/2000/svg">
<path fill-rule="evenodd" clip-rule="evenodd" d="M0 2C0 0.895431 0.895431 0 2 0H25C26.1046 0 27 0.895431 27 2V11.8321C26.365 11.5546 25.6956 11.3412 25 11.2V2H2V26H14.3378C14.7601 26.73 15.272 27.4017 15.8586 28H2C0.895431 28 0 27.1046 0 26V2Z" fill="#0A1C38" fill-opacity="0.9"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M15.5968 20.25C15.5968 16.5755 18.5755 13.5968 22.25 13.5968C25.9245 13.5968 28.9032 16.5755 28.9032 20.25C28.9032 23.9245 25.9245 26.9032 22.25 26.9032C18.5755 26.9032 15.5968 23.9245 15.5968 20.25ZM22.25 12C17.6937 12 14 15.6937 14 20.25C14 24.8063 17.6937 28.5 22.25 28.5C26.8063 28.5 30.5 24.8063 30.5 20.25C30.5 15.6937 26.8063 12 22.25 12ZM22.25 14.9274C22.8379 14.9274 23.3145 15.404 23.3145 15.9919V19.1855H26.5081C27.096 19.1855 27.5726 19.6621 27.5726 20.25C27.5726 20.8379 27.096 21.3145 26.5081 21.3145H23.3145V24.5081C23.3145 25.096 22.8379 25.5726 22.25 25.5726C21.6621 25.5726 21.1855 25.096 21.1855 24.5081V21.3145H17.9919C17.404 21.3145 16.9274 20.8379 16.9274 20.25C16.9274 19.6621 17.404 19.1855 17.9919 19.1855H21.1855V15.9919C21.1855 15.404 21.6621 14.9274 22.25 14.9274Z" fill="#0A1C38" fill-opacity="0.9"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M22.1429 8H11.4286V14.4286H14.2139C15.9469 11.9759 18.8361 10.3184 22.1429 10.156V8ZM13.5579 15.5C12.8807 16.791 12.4999 18.2462 12.4999 19.7857C12.4999 20.9128 12.704 21.9946 13.079 23H5V15.5H13.5579Z" fill="#0A1C38" fill-opacity="0.9"/>
<path d="M5 8H10.5V14.5H5V8Z" fill="#0A1C38" fill-opacity="0.78"/>
</svg>

After

Width:  |  Height:  |  Size: 1.6 KiB

2
designer-base/src/main/resources/com/fine/theme/icon/saveFile.svg

@ -1,3 +1,3 @@
<svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg">
<path fill-rule="evenodd" clip-rule="evenodd" d="M28.5 28V9.46837C28.5 9.34773 28.4564 9.23115 28.3772 9.14014L23.6185 3.67177C23.5236 3.56265 23.386 3.5 23.2414 3.5H20V10.6C20 11.3732 19.3732 12 18.6 12H9.4C8.6268 12 8 11.3732 8 10.6V3.5H4C3.72386 3.5 3.5 3.72386 3.5 4V28C3.5 28.2761 3.72386 28.5 4 28.5H8V19.4C8 18.6268 8.6268 18 9.4 18H22.6C23.3732 18 24 18.6268 24 19.4V28.5H28C28.2761 28.5 28.5 28.2761 28.5 28ZM24 30H8H4C2.89543 30 2 29.1046 2 28V4C2 2.89543 2.89543 2 4 2H8H20H23.2414C23.82 2 24.3702 2.2506 24.7501 2.68709L29.5087 8.15546C29.8255 8.51949 30 8.9858 30 9.46837V28C30 29.1046 29.1046 30 28 30H24ZM22.5 28.5V19.5H9.5V28.5H22.5ZM9.5 3.5H18.5V10.5H9.5V3.5Z" fill="#0A1C38" fill-opacity="0.9"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M4 4V28H8V20C8 18.8954 8.89543 18 10 18H22C23.1046 18 24 18.8954 24 20V28H28V9.73985L23.0801 4H20V10C20 11.1046 19.1046 12 18 12H10C8.89543 12 8 11.1046 8 10V4H4ZM24 30H28C29.1046 30 30 29.1046 30 28V9.73985C30 9.26243 29.8292 8.80075 29.5185 8.43827L24.5986 2.69842C24.2187 2.25513 23.664 2 23.0801 2H20H8H4C2.89543 2 2 2.89543 2 4V28C2 29.1046 2.89543 30 4 30H8H24ZM22 28V20H10V28H22ZM10 4H18V10H10V4Z" fill="#0A1C38" fill-opacity="0.9"/>
</svg>

Before

Width:  |  Height:  |  Size: 817 B

After

Width:  |  Height:  |  Size: 593 B

2
designer-base/src/main/resources/com/fine/theme/icon/saveFile_disable.svg

@ -1,3 +1,3 @@
<svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg">
<path fill-rule="evenodd" clip-rule="evenodd" d="M28.5 28V9.46837C28.5 9.34773 28.4564 9.23115 28.3772 9.14014L23.6185 3.67177C23.5236 3.56265 23.386 3.5 23.2414 3.5H20V10.6C20 11.3732 19.3732 12 18.6 12H9.4C8.6268 12 8 11.3732 8 10.6V3.5H4C3.72386 3.5 3.5 3.72386 3.5 4V28C3.5 28.2761 3.72386 28.5 4 28.5H8V19.4C8 18.6268 8.6268 18 9.4 18H22.6C23.3732 18 24 18.6268 24 19.4V28.5H28C28.2761 28.5 28.5 28.2761 28.5 28ZM24 30H8H4C2.89543 30 2 29.1046 2 28V4C2 2.89543 2.89543 2 4 2H8H20H23.2414C23.82 2 24.3702 2.2506 24.7501 2.68709L29.5087 8.15546C29.8255 8.51949 30 8.9858 30 9.46837V28C30 29.1046 29.1046 30 28 30H24ZM22.5 28.5V19.5H9.5V28.5H22.5ZM9.5 3.5H18.5V10.5H9.5V3.5Z" fill="#0A1C38" fill-opacity="0.29"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M4 4V28H8V20C8 18.8954 8.89543 18 10 18H22C23.1046 18 24 18.8954 24 20V28H28V9.73985L23.0801 4H20V10C20 11.1046 19.1046 12 18 12H10C8.89543 12 8 11.1046 8 10V4H4ZM24 30H28C29.1046 30 30 29.1046 30 28V9.73985C30 9.26243 29.8292 8.80075 29.5185 8.43827L24.5986 2.69842C24.2187 2.25513 23.664 2 23.0801 2H20H8H4C2.89543 2 2 2.89543 2 4V28C2 29.1046 2.89543 30 4 30H8H24ZM22 28V20H10V28H22ZM10 4H18V10H10V4Z" fill="#0A1C38" fill-opacity="0.29"/>
</svg>

Before

Width:  |  Height:  |  Size: 818 B

After

Width:  |  Height:  |  Size: 594 B

1
designer-base/src/main/resources/com/fine/theme/light/ui/fine_light.icon.json

@ -7,6 +7,7 @@
"cut": "cut.svg",
"save": "save.svg",
"saveFile": "saveFile.svg",
"formExport": "formExport.svg",
"copy": "copy.svg",
"formatBrush": "formatBrush.svg",
"paste": "paste.svg",

2
designer-chart/src/main/java/com/fr/design/mainframe/chart/gui/ChartTypeButtonPane.java

@ -457,7 +457,7 @@ public class ChartTypeButtonPane extends BasicBeanPane<ChartCollection> implemen
private class ChartChangeButton extends UIToggleButton {
private final double DEL_WIDTH = scale(9);
private final double DEL_WIDTH = scale(10);
private final double DOWN_HEIGHT = scale(1);
private final Icon closeIcon = new LazyIcon("closeTag", 8);
private boolean isMoveOn = false;

3
designer-chart/src/main/java/com/fr/design/mainframe/chart/gui/type/ChartImagePane.java

@ -48,7 +48,8 @@ public class ChartImagePane extends ChartSelectDemoPane {
super.paint(g);
BufferedImage image1 = IOUtils.readImageWithCache(fullIconPath);
g.drawImage(image1, 0, 0, scale(IMAGE_WIDTH), scale(IMAGE_HIGTH), null);
int x = (this.getWidth() - scale(IMAGE_WIDTH)) / 2;
g.drawImage(image1, x, 0, scale(IMAGE_WIDTH), scale(IMAGE_HIGTH), null);
}
};

BIN
designer-chart/src/main/resources/com/fr/design/images/background/null_background.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 349 B

105
designer-realize/src/main/java/com/fanruan/boot/adaptation/DesignServerSupportModule.java

@ -0,0 +1,105 @@
package com.fanruan.boot.adaptation;
import com.fanruan.carina.Carina;
import com.fanruan.carina.context.ContextListener;
import com.fanruan.portal.authority.PortalAuthorityItems;
import com.fanruan.portal.module.PortalModule;
import com.fanruan.portal.module.PortalModuleManager;
import com.fr.stable.StringUtils;
import com.fr.third.guava.collect.Sets;
import java.util.Optional;
import java.util.Set;
import static com.fanruan.auth.authority.AuthAuthorityItems.USER_ADD_DEPARTMENT_ID;
import static com.fanruan.auth.authority.AuthAuthorityItems.USER_ADD_ID;
import static com.fanruan.auth.authority.AuthAuthorityItems.USER_ADD_ROLE_ID;
import static com.fanruan.auth.authority.AuthAuthorityItems.USER_DELETE_ID;
import static com.fanruan.auth.authority.AuthAuthorityItems.USER_DELETE_ROLE_ID;
import static com.fanruan.auth.authority.AuthAuthorityItems.USER_EDIT_DEP_ROLE_ID;
import static com.fanruan.auth.authority.AuthAuthorityItems.USER_EDIT_EDIT_INFO_ID;
import static com.fanruan.auth.authority.AuthAuthorityItems.USER_EDIT_ID;
import static com.fanruan.auth.authority.AuthAuthorityItems.USER_EDIT_RESET_PASSWORD_ID;
import static com.fanruan.auth.authority.AuthAuthorityItems.USER_FORBIDDEN_ID;
import static com.fanruan.auth.authority.AuthAuthorityItems.USER_ID;
import static com.fanruan.messenger.ums.authority.UMSAuthorityItems.PORTAL_MANAGEMENT_ENTERPRISE_UMS_ID;
import static com.fanruan.portal.authority.PortalAuthorityItems.ENTERPRISE_GENERAL_ID;
import static com.fanruan.portal.authority.PortalAuthorityItems.ENTERPRISE_ID;
import static com.fanruan.portal.authority.PortalAuthorityItems.MAP_ID;
import static com.fanruan.portal.authority.PortalAuthorityItems.PORTAL_MANAGEMENT_ID;
import static com.fanruan.portal.authority.PortalAuthorityItems.SECURITY_ID;
import static com.fr.decision.authority.base.constant.ReportAuthorityItems.ENTERPRISE_REPORT_BASE_SETTINGS_ID;
import static com.fr.decision.authority.base.constant.ReportAuthorityItems.ENTERPRISE_REPORT_ID;
/**
* 内置服务器支持展示的模块预期调用顺序在业务模块之后
*
* @author Anner
* @since 11.0
* Created on 2024/10/15
*/
public class DesignServerSupportModule {
private final static Set<String> SUPPORT_MODULE = Sets.newHashSet(
// 系统管理
PORTAL_MANAGEMENT_ID,
// 用户管理
USER_ID,
USER_ADD_ROLE_ID,
USER_ADD_DEPARTMENT_ID,
USER_ADD_ID,
USER_EDIT_ID,
USER_EDIT_RESET_PASSWORD_ID,
USER_EDIT_EDIT_INFO_ID,
USER_EDIT_DEP_ROLE_ID,
USER_DELETE_ID,
USER_DELETE_ROLE_ID,
USER_FORBIDDEN_ID,
// 企业设置
ENTERPRISE_ID,
// 企业设置 - 通知中心
PORTAL_MANAGEMENT_ENTERPRISE_UMS_ID,
// 企业设置 - 通用设置
ENTERPRISE_GENERAL_ID,
// 报表设置
ENTERPRISE_REPORT_ID,
// 报表设置 - 基础设置
ENTERPRISE_REPORT_BASE_SETTINGS_ID,
// 安全管理
SECURITY_ID,
// 地图管理
MAP_ID
);
/**
* 注册一下支持展示的模块
*
* @param moduleName name
*/
public static void register(String moduleName) {
Optional.of(moduleName).ifPresent(SUPPORT_MODULE::add);
}
/**
* 取消注册展示的模块
*
* @param moduleName name
*/
public static void unregister(String moduleName) {
Optional.of(moduleName).ifPresent(SUPPORT_MODULE::remove);
}
/**
* 启动入口重建一下展示的module
*/
public static void rebuild() {
Carina.getApplicationContext().addListener(new ContextListener() {
@Override
public void onStart() {
PortalModuleManager.allModules().values().stream()
.filter(m -> !StringUtils.equals(m.getParentID(), PortalAuthorityItems.PORTAL_ROOT_ID)).map(PortalModule::getId)
.filter(m -> !SUPPORT_MODULE.contains(m))
.forEach(PortalModuleManager::unregister);
}
});
}
}

5
designer-realize/src/main/java/com/fanruan/boot/adaptation/ReportAdaptationComponent.java

@ -1,6 +1,7 @@
package com.fanruan.boot.adaptation;
import com.fanruan.carina.Carina;
import com.fanruan.carina.annotions.DependsOn;
import com.fanruan.carina.annotions.FineComponent;
import com.fanruan.carina.annotions.Start;
import com.fanruan.plugins.resource.PluginResourceHelper;
@ -57,8 +58,8 @@ import java.util.TreeSet;
* Created on 2024/6/24
*/
@FineComponent(name = "fine_report_adaptation")
@DependsOn(dependencies = {"fine_report"})
public class ReportAdaptationComponent {
/**
* 启动
*/
@ -74,6 +75,8 @@ public class ReportAdaptationComponent {
// 插件controller注册
PluginControllerManager.getInstance().init();
// 过滤掉内置服务器不支持的模块
DesignServerSupportModule.rebuild();
}
private void listenEmbedServletFilter(ServletContext servletContext) {

3
designer-realize/src/main/java/com/fr/design/actions/file/newReport/NewPolyReportAction.java

@ -6,6 +6,7 @@ import java.awt.event.KeyEvent;
import javax.swing.KeyStroke;
import com.fine.theme.icon.LazyIcon;
import com.fr.base.svg.IconUtils;
import com.fr.design.actions.UpdateAction;
import com.fr.design.mainframe.DesignerContext;
@ -19,7 +20,7 @@ public class NewPolyReportAction extends UpdateAction {
public NewPolyReportAction() {
this.setName(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Report_M_New_Multi_Report"));
this.setMnemonic('F');
this.setSmallIcon("/com/fr/design/images/m_file/formExport");
this.setSmallIcon(new LazyIcon("formExport"));
this.setAccelerator(KeyStroke.getKeyStroke(KeyEvent.VK_M, DEFAULT_MODIFIER));
}

Loading…
Cancel
Save