diff --git a/designer-realize/src/main/java/com/fr/design/actions/replace/action/content/formula/chart/SearchChartCollectionFormulaAction.java b/designer-realize/src/main/java/com/fr/design/actions/replace/action/content/formula/chart/SearchChartCollectionFormulaAction.java index 40e5283ce9..69b763248c 100644 --- a/designer-realize/src/main/java/com/fr/design/actions/replace/action/content/formula/chart/SearchChartCollectionFormulaAction.java +++ b/designer-realize/src/main/java/com/fr/design/actions/replace/action/content/formula/chart/SearchChartCollectionFormulaAction.java @@ -34,6 +34,7 @@ import com.fr.plugin.chart.custom.CustomPlotFactory; import com.fr.plugin.chart.custom.VanChartCustomPlot; import com.fr.plugin.chart.custom.type.CustomPlotType; +import com.fr.plugin.chart.drillmap.VanChartDrillMapPlot; import com.fr.plugin.chart.map.VanChartMapPlot; import com.fr.stable.StringUtils; @@ -106,6 +107,10 @@ public class SearchChartCollectionFormulaAction { customContent.addOtherPos(CustomPlotFactory.getTitle(CustomPlotFactory.getCustomType(plot.getCustomPlotList().get(i)))); dealPlot(formulaInfos, customContent, plot.getCustomPlotList().get(i)); } + } else if (chart.getPlot() instanceof VanChartDrillMapPlot) { + ITContent drillContent = ITContent.copy(conditionContent); + drillContent.addOtherPos(Toolkit.i18nText("Fine-Design_Chart_Drill_Dir")); + dealNameJavaScriptGroup(formulaInfos, drillContent, ((VanChartDrillMapPlot) chart.getPlot()).getDrillUpHyperLink()); } else if (chart.getPlot() != null) { dealPlot(formulaInfos, conditionContent, chart.getPlot()); } diff --git a/designer-realize/src/main/java/com/fr/design/actions/replace/utils/SearchJSUtils.java b/designer-realize/src/main/java/com/fr/design/actions/replace/utils/SearchJSUtils.java index 8901f76edb..2a1a4ef188 100644 --- a/designer-realize/src/main/java/com/fr/design/actions/replace/utils/SearchJSUtils.java +++ b/designer-realize/src/main/java/com/fr/design/actions/replace/utils/SearchJSUtils.java @@ -26,6 +26,7 @@ import com.fr.plugin.chart.base.VanChartHtmlLabel; import com.fr.plugin.chart.custom.CustomPlotFactory; import com.fr.plugin.chart.custom.VanChartCustomPlot; import com.fr.plugin.chart.custom.type.CustomPlotType; +import com.fr.plugin.chart.drillmap.VanChartDrillMapPlot; import com.fr.plugin.chart.map.VanChartMapPlot; import com.fr.plugin.chart.map.attr.AttrMapLabel; import com.fr.plugin.chart.map.attr.AttrMapTooltip; @@ -63,6 +64,14 @@ public class SearchJSUtils { */ public static final String CATEGORY_LABEL = ShowValueUtils.joinStr4Position(Toolkit.i18nText("Fine-Design_Basic_Style"), Toolkit.i18nText("Fine-Design_Chart_Data_Label"), Toolkit.i18nText("Fine-Design_Chart_Category_Label")); + /** + * 条件属性 + */ + public static final String CONDITION = ShowValueUtils.joinStr4Position( + Toolkit.i18nText("Fine-Design_Chart_Chart"), + Toolkit.i18nText("Fine-Design_Chart_Animation_Special"), + Toolkit.i18nText("Fine-Design_Chart_Interactive")); + /** * 从Listener中获取JS */ @@ -338,6 +347,8 @@ public class SearchJSUtils { VanChart chart = ((VanChart) chartCollection.getChart(i)); if (isCustomMapPlot(chart.getPlot())) { dealMapNameJavaScript(content, chart.getPlot(), jsInfos); + } else if (chart.getPlot() instanceof VanChartDrillMapPlot) { + dealDrillNameJavaScript(content, chart.getPlot(), jsInfos); } else { NameJavaScriptGroup nameJavaScriptGroup = chart.getPlot().getHotHyperLink(); addNameJavaScript2Array(nameJavaScriptArrayList, nameJavaScriptGroup); @@ -347,6 +358,17 @@ public class SearchJSUtils { return nameJavaScriptArrayList; } + private static void dealDrillNameJavaScript(ITContent content, VanChartDrillMapPlot plot, List jsInfos) { + ITContent chartContent = ITContent.copy(content); + chartContent.addOtherPos( + CONDITION, + Toolkit.i18nText("Fine-Design_Chart_Drill_Dir") + ); + List list = new ArrayList<>(); + addNameJavaScript2Array(list, plot.getDrillUpHyperLink()); + addJSInfosFromNameJS(chartContent, list, jsInfos); + } + /** * 是否是组合地图 * @param plot 图表的plot @@ -366,14 +388,15 @@ public class SearchJSUtils { List areaJavaScriptList = new ArrayList<>(); List lineJavaScriptList = new ArrayList<>(); List pointJavaScriptList = new ArrayList<>(); - + ITContent chartContent = ITContent.copy(content); + chartContent.addOtherPos(CONDITION); addNameJavaScript2Array(areaJavaScriptList, plot.getAreaHotHyperLink()); addNameJavaScript2Array(lineJavaScriptList, plot.getLineHotHyperLink()); addNameJavaScript2Array(pointJavaScriptList, plot.getPointHotHyperLink()); - addJSInfosFromNameJS(ShowValueUtils.getCustomMapContent(content, Toolkit.i18nText("Fine-Design_Chart_Region_Map")), areaJavaScriptList, jsInfos); - addJSInfosFromNameJS(ShowValueUtils.getCustomMapContent(content, Toolkit.i18nText("Fine-Design_Chart_LineMap")), lineJavaScriptList, jsInfos); - addJSInfosFromNameJS(ShowValueUtils.getCustomMapContent(content, Toolkit.i18nText("Fine-Design_Chart_PointMap")), pointJavaScriptList, jsInfos); + addJSInfosFromNameJS(ShowValueUtils.getCustomMapContent(chartContent, Toolkit.i18nText("Fine-Design_Chart_Region_Map")), areaJavaScriptList, jsInfos); + addJSInfosFromNameJS(ShowValueUtils.getCustomMapContent(chartContent, Toolkit.i18nText("Fine-Design_Chart_LineMap")), lineJavaScriptList, jsInfos); + addJSInfosFromNameJS(ShowValueUtils.getCustomMapContent(chartContent, Toolkit.i18nText("Fine-Design_Chart_PointMap")), pointJavaScriptList, jsInfos); } private static void addNameJavaScript2Array(List nameJavaScriptArrayList, NameJavaScriptGroup nameJavaScriptGroup) {