From 51c0b98170d1fdc6a92a5974360c0041ccc5c2c9 Mon Sep 17 00:00:00 2001 From: "Wim.Zhai" Date: Sun, 3 Nov 2019 10:37:53 +0800 Subject: [PATCH 1/3] =?UTF-8?q?CHART-4248=20=E9=87=8D=E5=91=BD=E5=90=8D?= =?UTF-8?q?=E9=9D=9E=E6=8A=BD=E8=B1=A1=E7=B1=BB?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../AbstractCellDataFieldsWithSeriesValuePane.java | 8 ++++---- .../diff/AbstractDataSetFieldsWithSeriesValuePane.java | 8 ++++---- .../chartx/fields/diff/FunnelCellDataFieldsPane.java | 10 +++++----- .../chartx/fields/diff/FunnelDataSetFieldsPane.java | 10 +++++----- 4 files changed, 18 insertions(+), 18 deletions(-) diff --git a/designer-chart/src/main/java/com/fr/design/chartx/fields/diff/AbstractCellDataFieldsWithSeriesValuePane.java b/designer-chart/src/main/java/com/fr/design/chartx/fields/diff/AbstractCellDataFieldsWithSeriesValuePane.java index 21f86633a..1ac1952aa 100644 --- a/designer-chart/src/main/java/com/fr/design/chartx/fields/diff/AbstractCellDataFieldsWithSeriesValuePane.java +++ b/designer-chart/src/main/java/com/fr/design/chartx/fields/diff/AbstractCellDataFieldsWithSeriesValuePane.java @@ -1,6 +1,6 @@ package com.fr.design.chartx.fields.diff; -import com.fr.chartx.data.field.diff.AbstractColumnFieldCollectionWithSeriesValue; +import com.fr.chartx.data.field.diff.ColumnFieldCollectionWithSeriesValue; import com.fr.design.chartx.component.CellDataSeriesValueCorrelationPane; import com.fr.design.chartx.fields.AbstractCellDataFieldsPane; @@ -10,7 +10,7 @@ import java.awt.BorderLayout; /** * Created by shine on 2019/6/4. */ -public abstract class AbstractCellDataFieldsWithSeriesValuePane +public abstract class AbstractCellDataFieldsWithSeriesValuePane extends AbstractCellDataFieldsPane { private CellDataSeriesValueCorrelationPane seriesValueFieldsPane; @@ -41,11 +41,11 @@ public abstract class AbstractCellDataFieldsWithSeriesValuePane +public abstract class AbstractDataSetFieldsWithSeriesValuePane extends AbstractDataSetFieldsPane { private SeriesValueFieldComboBoxPane seriesValueFieldComboBoxPane; @@ -61,11 +61,11 @@ public abstract class AbstractDataSetFieldsWithSeriesValuePane { +public class FunnelCellDataFieldsPane extends AbstractCellDataFieldsWithSeriesValuePane { private AbstractSingleFilterPane filterPane; @@ -50,8 +50,8 @@ public class FunnelCellDataFieldsPane extends AbstractCellDataFieldsWithSeriesVa } @Override - public AbstractColumnFieldCollectionWithSeriesValue updateBean() { - AbstractColumnFieldCollectionWithSeriesValue fieldCollection = new AbstractColumnFieldCollectionWithSeriesValue(); + public ColumnFieldCollectionWithSeriesValue updateBean() { + ColumnFieldCollectionWithSeriesValue fieldCollection = new ColumnFieldCollectionWithSeriesValue(); updateSeriesValuePane(fieldCollection); SeriesValueCorrelationDefinition seriesValueCorrelationDefinition = fieldCollection.getSeriesValueCorrelationDefinition(); filterPane.updateBean(seriesValueCorrelationDefinition.getFilterProperties()); @@ -59,7 +59,7 @@ public class FunnelCellDataFieldsPane extends AbstractCellDataFieldsWithSeriesVa } @Override - public void populateBean(AbstractColumnFieldCollectionWithSeriesValue ob) { + public void populateBean(ColumnFieldCollectionWithSeriesValue ob) { populateSeriesValuePane(ob); SeriesValueCorrelationDefinition seriesValueCorrelationDefinition = ob.getSeriesValueCorrelationDefinition(); filterPane.populateBean(seriesValueCorrelationDefinition.getFilterProperties()); diff --git a/designer-chart/src/main/java/com/fr/design/chartx/fields/diff/FunnelDataSetFieldsPane.java b/designer-chart/src/main/java/com/fr/design/chartx/fields/diff/FunnelDataSetFieldsPane.java index e6adcc289..c24a23b4e 100644 --- a/designer-chart/src/main/java/com/fr/design/chartx/fields/diff/FunnelDataSetFieldsPane.java +++ b/designer-chart/src/main/java/com/fr/design/chartx/fields/diff/FunnelDataSetFieldsPane.java @@ -1,7 +1,7 @@ package com.fr.design.chartx.fields.diff; import com.fr.chartx.data.field.SeriesValueCorrelationDefinition; -import com.fr.chartx.data.field.diff.AbstractColumnFieldCollectionWithSeriesValue; +import com.fr.chartx.data.field.diff.ColumnFieldCollectionWithSeriesValue; import com.fr.design.chartx.component.AbstractSingleFilterPane; import com.fr.design.gui.icombobox.UIComboBox; import com.fr.design.i18n.Toolkit; @@ -15,7 +15,7 @@ import java.awt.BorderLayout; /** * Created by Wim on 2019/10/23. */ -public class FunnelDataSetFieldsPane extends AbstractDataSetFieldsWithSeriesValuePane { +public class FunnelDataSetFieldsPane extends AbstractDataSetFieldsWithSeriesValuePane { private AbstractSingleFilterPane filterPane; @@ -53,8 +53,8 @@ public class FunnelDataSetFieldsPane extends AbstractDataSetFieldsWithSeriesValu } @Override - public AbstractColumnFieldCollectionWithSeriesValue updateBean() { - AbstractColumnFieldCollectionWithSeriesValue collection = new AbstractColumnFieldCollectionWithSeriesValue(); + public ColumnFieldCollectionWithSeriesValue updateBean() { + ColumnFieldCollectionWithSeriesValue collection = new ColumnFieldCollectionWithSeriesValue(); updateSeriesValuePane(collection); SeriesValueCorrelationDefinition seriesValueCorrelationDefinition = collection.getSeriesValueCorrelationDefinition(); filterPane.updateBean(seriesValueCorrelationDefinition.getFilterProperties()); @@ -62,7 +62,7 @@ public class FunnelDataSetFieldsPane extends AbstractDataSetFieldsWithSeriesValu } @Override - public void populateBean(AbstractColumnFieldCollectionWithSeriesValue ob) { + public void populateBean(ColumnFieldCollectionWithSeriesValue ob) { populateSeriesValuePane(ob); SeriesValueCorrelationDefinition seriesValueCorrelationDefinition = ob.getSeriesValueCorrelationDefinition(); filterPane.populateBean(seriesValueCorrelationDefinition.getFilterProperties()); From c5926c4a0b026fc198494ce97a5220bea50c2e38 Mon Sep 17 00:00:00 2001 From: "Wim.Zhai" Date: Mon, 4 Nov 2019 11:27:53 +0800 Subject: [PATCH 2/3] =?UTF-8?q?refactor:=E6=95=A3=E7=82=B9=E5=9B=BE?= =?UTF-8?q?=E6=B0=94=E6=B3=A1=E5=9B=BE=E6=95=B0=E6=8D=AE=E9=9D=A2=E6=9D=BF?= =?UTF-8?q?=20CHART-4248?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../design/chartx/AbstractChartDataPane.java | 2 +- .../chartx/AbstractVanSingleDataPane.java | 7 +- .../fr/design/chartx/CustomChartDataPane.java | 7 +- .../fr/design/chartx/GanttChartDataPane.java | 5 +- .../CellDataSeriesXYValueCorrelationPane.java | 66 +++++++++++++ .../diff/ScatterCellDataFieldsPane.java | 86 +++++++++++++++++ .../fields/diff/ScatterDataSetFieldsPane.java | 95 +++++++++++++++++++ .../mainframe/chart/gui/ChartDataPane.java | 5 + .../BubbleIndependentVanChartInterface.java | 22 +++++ .../FunnelIndependentVanChartInterface.java | 3 +- .../MultiPieIndependentVanChartInterface.java | 3 +- .../ScatterIndependentVanChartInterface.java | 15 +++ .../desinger/VanStructureChartTypeUI.java | 3 +- .../AbstractIndependentVanChartUI.java | 3 +- .../AbstractMultiCategoryVanChartUI.java | 3 +- ...WordCloudIndependentVanChartInterface.java | 3 +- 16 files changed, 313 insertions(+), 15 deletions(-) create mode 100644 designer-chart/src/main/java/com/fr/design/chartx/component/CellDataSeriesXYValueCorrelationPane.java create mode 100644 designer-chart/src/main/java/com/fr/design/chartx/fields/diff/ScatterCellDataFieldsPane.java create mode 100644 designer-chart/src/main/java/com/fr/design/chartx/fields/diff/ScatterDataSetFieldsPane.java diff --git a/designer-chart/src/main/java/com/fr/design/chartx/AbstractChartDataPane.java b/designer-chart/src/main/java/com/fr/design/chartx/AbstractChartDataPane.java index 61359d91b..aa776f489 100644 --- a/designer-chart/src/main/java/com/fr/design/chartx/AbstractChartDataPane.java +++ b/designer-chart/src/main/java/com/fr/design/chartx/AbstractChartDataPane.java @@ -32,7 +32,7 @@ public abstract class AbstractChartDataPane { + + @Override + protected FieldEditorComponentWrapper[] createFieldEditorComponentWrappers() { + return new FieldEditorComponentWrapper[]{ + new TinyFormulaPaneEditorComponent(Toolkit.i18nText("Fine-Design_Chart_Series_Name")), + new TinyFormulaPaneEditorComponent(Toolkit.i18nText("Fine-Design_Chart_X_Axis")), + new TinyFormulaPaneEditorComponent(Toolkit.i18nText("Fine-Design_Chart_Y_Axis")), + new TinyFormulaPaneEditorComponent(Toolkit.i18nText("Fine-Design_Chart_Series_Value")) + }; + } + + @Override + protected List covertTBeanToTableModelList(BubbleColumnFieldCollection bubbleColumnFieldCollection) { + List result = new ArrayList<>(); + + List bubbleColumnFieldList = bubbleColumnFieldCollection.getList(); + for (BubbleColumnField field : bubbleColumnFieldList) { + Object[] array = new Object[]{ + field.getSeriesName().getFieldName(), + field.getXField().getFieldName(), + field.getYField().getFieldName(), + field.getValueField().getFieldName() + }; + result.add(array); + } + + return result; + } + + @Override + protected void setTableModelListToTBean(List tableValues, BubbleColumnFieldCollection bubbleColumnFieldCollection) { + List bubbleColumnFieldList = new ArrayList<>(); + for (Object[] oneLine : tableValues) { + BubbleColumnField bubbleColumnField = new BubbleColumnField(); + ColumnField series = new ColumnField(Utils.objectToString(oneLine[0])); + ColumnField xField = new ColumnField(Utils.objectToString(oneLine[1])); + ColumnField yField = new ColumnField(Utils.objectToString(oneLine[2])); + ColumnField value = new ColumnField(Utils.objectToString(oneLine[3])); + bubbleColumnField.setSeriesName(series); + bubbleColumnField.setXField(xField); + bubbleColumnField.setYField(yField); + bubbleColumnField.setValueField(value); + bubbleColumnFieldList.add(bubbleColumnField); + } + + bubbleColumnFieldCollection.setList(bubbleColumnFieldList); + } +} diff --git a/designer-chart/src/main/java/com/fr/design/chartx/fields/diff/ScatterCellDataFieldsPane.java b/designer-chart/src/main/java/com/fr/design/chartx/fields/diff/ScatterCellDataFieldsPane.java new file mode 100644 index 000000000..920538f43 --- /dev/null +++ b/designer-chart/src/main/java/com/fr/design/chartx/fields/diff/ScatterCellDataFieldsPane.java @@ -0,0 +1,86 @@ +package com.fr.design.chartx.fields.diff; + +import com.fr.chartx.data.field.diff.BubbleColumnFieldCollection; +import com.fr.design.chartx.component.AbstractSingleFilterPane; +import com.fr.design.chartx.component.CellDataSeriesXYValueCorrelationPane; +import com.fr.design.chartx.fields.AbstractCellDataFieldsPane; +import com.fr.design.formula.TinyFormulaPane; +import com.fr.design.i18n.Toolkit; +import com.fr.van.chart.designer.TableLayout4VanChartHelper; + +import javax.swing.JPanel; +import java.awt.BorderLayout; + +/** + * Created by Wim on 2019/11/04. + */ +public class ScatterCellDataFieldsPane extends AbstractCellDataFieldsPane { + + private CellDataSeriesXYValueCorrelationPane seriesXYValueCorrelationPane; + private AbstractSingleFilterPane filterPane; + + + public CellDataSeriesXYValueCorrelationPane getSeriesXYValueCorrelationPane() { + return seriesXYValueCorrelationPane; + } + + public void setSeriesXYValueCorrelationPane(CellDataSeriesXYValueCorrelationPane seriesXYValueCorrelationPane) { + this.seriesXYValueCorrelationPane = seriesXYValueCorrelationPane; + } + + @Override + protected void initComponents() { + filterPane = new AbstractSingleFilterPane() { + @Override + public String title4PopupWindow() { + return Toolkit.i18nText("Fine-Design_Chart_Series"); + } + }; + + this.setLayout(new BorderLayout(0, 6)); + this.add(createCenterPane(), BorderLayout.NORTH); + JPanel contentPane = new JPanel(new BorderLayout()); + contentPane.add(new JPanel(), BorderLayout.NORTH); + contentPane.add(filterPane, BorderLayout.CENTER); + this.add(TableLayout4VanChartHelper.createExpandablePaneWithTitle(Toolkit.i18nText("Fine-Design_Chart_Data_Filter"), contentPane), BorderLayout.CENTER); + + } + + @Override + protected JPanel createCenterPane() { + JPanel normalCenter = super.createCenterPane(); + seriesXYValueCorrelationPane = new CellDataSeriesXYValueCorrelationPane(); + + if (normalCenter != null) { + JPanel panel = new JPanel(new BorderLayout(0, 6)); + panel.add(normalCenter, BorderLayout.NORTH); + panel.add(seriesXYValueCorrelationPane, BorderLayout.CENTER); + return panel; + } else { + return seriesXYValueCorrelationPane; + } + + } + + @Override + protected String[] fieldLabels() { + return new String[0]; + } + + @Override + protected TinyFormulaPane[] formulaPanes() { + return new TinyFormulaPane[0]; + } + + @Override + public BubbleColumnFieldCollection updateBean() { + BubbleColumnFieldCollection collection = new BubbleColumnFieldCollection(); + seriesXYValueCorrelationPane.updateBean(collection); + return collection; + } + + @Override + public void populateBean(BubbleColumnFieldCollection ob) { + seriesXYValueCorrelationPane.populateBean(ob); + } +} diff --git a/designer-chart/src/main/java/com/fr/design/chartx/fields/diff/ScatterDataSetFieldsPane.java b/designer-chart/src/main/java/com/fr/design/chartx/fields/diff/ScatterDataSetFieldsPane.java new file mode 100644 index 000000000..79765cccb --- /dev/null +++ b/designer-chart/src/main/java/com/fr/design/chartx/fields/diff/ScatterDataSetFieldsPane.java @@ -0,0 +1,95 @@ +package com.fr.design.chartx.fields.diff; + +import com.fr.chartx.data.field.diff.BubbleColumnField; +import com.fr.chartx.data.field.diff.BubbleColumnFieldCollection; +import com.fr.design.chartx.component.AbstractSingleFilterPane; +import com.fr.design.chartx.fields.AbstractDataSetFieldsPane; +import com.fr.design.gui.icombobox.UIComboBox; +import com.fr.design.i18n.Toolkit; +import com.fr.extended.chart.UIComboBoxWithNone; +import com.fr.van.chart.designer.TableLayout4VanChartHelper; + +import javax.swing.BorderFactory; +import javax.swing.JPanel; +import javax.swing.JSeparator; +import java.awt.BorderLayout; + +/** + * Created by Wim on 2019/10/29. + */ +public class ScatterDataSetFieldsPane extends AbstractDataSetFieldsPane { + + private UIComboBoxWithNone series; + private UIComboBox xField; + private UIComboBox yField; + private UIComboBoxWithNone value; + + //todo 数据筛选 + private AbstractSingleFilterPane filterPane; + + + @Override + protected void initComponents() { + + series = new UIComboBoxWithNone(); + xField = new UIComboBox(); + yField = new UIComboBox(); + value = new UIComboBoxWithNone(); + + filterPane = new AbstractSingleFilterPane() { + @Override + public String title4PopupWindow() { + return Toolkit.i18nText("Fine-Design_Chart_Series"); + } + }; + + JPanel northPane = new JPanel(new BorderLayout(0, 6)); + northPane.add(new JSeparator(), BorderLayout.CENTER); + northPane.add(createCenterPane(), BorderLayout.SOUTH); + northPane.setBorder(BorderFactory.createEmptyBorder(4, 24, 0, 15)); + + this.setLayout(new BorderLayout(0, 6)); + this.add(northPane, BorderLayout.NORTH); + JPanel contentPane = new JPanel(new BorderLayout()); + contentPane.add(new JPanel(), BorderLayout.NORTH); + contentPane.add(filterPane, BorderLayout.CENTER); + this.add(TableLayout4VanChartHelper.createExpandablePaneWithTitle(Toolkit.i18nText("Fine-Design_Chart_Data_Filter"), contentPane), BorderLayout.CENTER); + } + + @Override + protected UIComboBox[] filedComboBoxes() { + return new UIComboBox[]{ + series, xField, yField, value + }; + } + + @Override + protected String[] fieldLabels() { + return new String[]{ + Toolkit.i18nText("Fine-Design_Chart_Series_Name"), + "x", + "y", + Toolkit.i18nText("Fine-Design_Chart_Use_Value") + }; + } + + @Override + public BubbleColumnFieldCollection updateBean() { + BubbleColumnFieldCollection collection = new BubbleColumnFieldCollection(); + BubbleColumnField field = collection.getBubbleColumnField(0); + updateField(series, field.getSeriesName()); + updateField(xField, field.getXField()); + updateField(yField, field.getYField()); + updateField(value, field.getValueField()); + return collection; + } + + @Override + public void populateBean(BubbleColumnFieldCollection ob) { + BubbleColumnField field = ob.getBubbleColumnField(0); + populateField(series, field.getSeriesName()); + populateField(xField, field.getXField()); + populateField(yField, field.getYField()); + populateField(value, field.getValueField()); + } +} diff --git a/designer-chart/src/main/java/com/fr/design/mainframe/chart/gui/ChartDataPane.java b/designer-chart/src/main/java/com/fr/design/mainframe/chart/gui/ChartDataPane.java index 5aed1e47d..4d961b3c3 100644 --- a/designer-chart/src/main/java/com/fr/design/mainframe/chart/gui/ChartDataPane.java +++ b/designer-chart/src/main/java/com/fr/design/mainframe/chart/gui/ChartDataPane.java @@ -10,6 +10,7 @@ import com.fr.design.mainframe.chart.AbstractChartAttrPane; import com.fr.design.mainframe.chart.PaneTitleConstants; import com.fr.design.mainframe.chart.gui.data.DataContentsPane; import com.fr.design.mainframe.chart.gui.data.NormalChartDataPane; +import com.fr.plugin.chart.vanchart.VanChart; import javax.swing.*; import java.awt.*; @@ -35,6 +36,10 @@ public class ChartDataPane extends AbstractChartAttrPane { return contentsPane; } + protected JPanel createContentPane(VanChart vanChart){ + return createContentPane(); + } + /** * 界面标题 */ diff --git a/designer-chart/src/main/java/com/fr/van/chart/bubble/BubbleIndependentVanChartInterface.java b/designer-chart/src/main/java/com/fr/van/chart/bubble/BubbleIndependentVanChartInterface.java index 6041f7e6f..1206d0fd3 100644 --- a/designer-chart/src/main/java/com/fr/van/chart/bubble/BubbleIndependentVanChartInterface.java +++ b/designer-chart/src/main/java/com/fr/van/chart/bubble/BubbleIndependentVanChartInterface.java @@ -3,6 +3,12 @@ package com.fr.van.chart.bubble; import com.fr.chart.chartattr.Chart; import com.fr.chart.chartattr.Plot; import com.fr.design.beans.BasicBeanPane; +import com.fr.design.chartx.AbstractVanSingleDataPane; +import com.fr.design.chartx.fields.diff.ScatterCellDataFieldsPane; +import com.fr.design.chartx.fields.diff.ScatterDataSetFieldsPane; +import com.fr.design.chartx.fields.diff.SingleCategoryCellDataFieldsPane; +import com.fr.design.chartx.fields.diff.SingleCategoryDataSetFieldsPane; +import com.fr.design.chartx.single.SingleDataPane; import com.fr.design.condition.ConditionAttributesPane; import com.fr.design.gui.frpane.AttributeChangeListener; import com.fr.design.i18n.Toolkit; @@ -14,6 +20,7 @@ import com.fr.design.mainframe.chart.gui.data.report.BubblePlotReportDataContent import com.fr.design.mainframe.chart.gui.data.table.AbstractTableDataContentPane; import com.fr.design.mainframe.chart.gui.type.AbstractChartTypePane; import com.fr.plugin.chart.bubble.VanChartBubblePlot; +import com.fr.plugin.chart.vanchart.VanChart; import com.fr.van.chart.bubble.data.VanChartBubblePlotTableDataContentPane; import com.fr.van.chart.designer.other.VanChartInteractivePaneWithOutSort; import com.fr.van.chart.designer.other.VanChartOtherPane; @@ -115,4 +122,19 @@ public class BubbleIndependentVanChartInterface extends AbstractIndependentVanCh public ConditionAttributesPane getPlotConditionPane(Plot plot) { return new VanChartBubbleConditionPane(plot); } + + @Override + public ChartDataPane getChartDataPane(AttributeChangeListener listener) { + return new AbstractVanSingleDataPane(listener) { + @Override + protected SingleDataPane createSingleDataPane(VanChart vanChart) { + VanChartBubblePlot bubblePlot = vanChart.getPlot(); + if (bubblePlot.isForceBubble()) { + return new SingleDataPane(new SingleCategoryDataSetFieldsPane(), new SingleCategoryCellDataFieldsPane()); + } else { + return new SingleDataPane(new ScatterDataSetFieldsPane(), new ScatterCellDataFieldsPane()); + } + } + }; + } } diff --git a/designer-chart/src/main/java/com/fr/van/chart/funnel/designer/FunnelIndependentVanChartInterface.java b/designer-chart/src/main/java/com/fr/van/chart/funnel/designer/FunnelIndependentVanChartInterface.java index c45aa17c3..c9f3b977c 100644 --- a/designer-chart/src/main/java/com/fr/van/chart/funnel/designer/FunnelIndependentVanChartInterface.java +++ b/designer-chart/src/main/java/com/fr/van/chart/funnel/designer/FunnelIndependentVanChartInterface.java @@ -17,6 +17,7 @@ import com.fr.design.mainframe.chart.gui.data.report.AbstractReportDataContentPa import com.fr.design.mainframe.chart.gui.data.table.AbstractTableDataContentPane; import com.fr.design.mainframe.chart.gui.data.table.PiePlotTableDataContentPane; import com.fr.design.mainframe.chart.gui.type.AbstractChartTypePane; +import com.fr.plugin.chart.vanchart.VanChart; import com.fr.van.chart.designer.data.OneDimensionalPlotReportDataContentPane; import com.fr.van.chart.designer.other.VanChartInteractivePaneWithOutSort; import com.fr.van.chart.designer.other.VanChartOtherPane; @@ -98,7 +99,7 @@ public class FunnelIndependentVanChartInterface extends AbstractIndependentVanCh public ChartDataPane getChartDataPane(AttributeChangeListener listener) { return new AbstractVanSingleDataPane(listener) { @Override - protected SingleDataPane createSingleDataPane() { + protected SingleDataPane createSingleDataPane(VanChart vanChart) { return new SingleDataPane(new FunnelDataSetFieldsPane(), new FunnelCellDataFieldsPane()); } }; diff --git a/designer-chart/src/main/java/com/fr/van/chart/multilayer/MultiPieIndependentVanChartInterface.java b/designer-chart/src/main/java/com/fr/van/chart/multilayer/MultiPieIndependentVanChartInterface.java index 9b1aa395f..36bc74ae6 100644 --- a/designer-chart/src/main/java/com/fr/van/chart/multilayer/MultiPieIndependentVanChartInterface.java +++ b/designer-chart/src/main/java/com/fr/van/chart/multilayer/MultiPieIndependentVanChartInterface.java @@ -12,6 +12,7 @@ import com.fr.design.i18n.Toolkit; import com.fr.design.mainframe.chart.gui.ChartDataPane; import com.fr.design.mainframe.chart.gui.ChartStylePane; import com.fr.design.mainframe.chart.gui.type.AbstractChartTypePane; +import com.fr.plugin.chart.vanchart.VanChart; import com.fr.van.chart.multilayer.other.VanChartMultiPieConditionPane; import com.fr.van.chart.multilayer.style.VanChartMultiPieSeriesPane; import com.fr.van.chart.vanchart.AbstractIndependentVanChartUI; @@ -46,7 +47,7 @@ public class MultiPieIndependentVanChartInterface extends AbstractIndependentVan public ChartDataPane getChartDataPane(AttributeChangeListener listener) { return new AbstractVanSingleDataPane(listener) { @Override - protected SingleDataPane createSingleDataPane() { + protected SingleDataPane createSingleDataPane(VanChart vanChart) { return new SingleDataPane(new MultiPieDataSetFieldsPane(), new MultiPieCellDataFieldsPane()); } }; diff --git a/designer-chart/src/main/java/com/fr/van/chart/scatter/ScatterIndependentVanChartInterface.java b/designer-chart/src/main/java/com/fr/van/chart/scatter/ScatterIndependentVanChartInterface.java index ebd81f4f0..d8b7a875b 100644 --- a/designer-chart/src/main/java/com/fr/van/chart/scatter/ScatterIndependentVanChartInterface.java +++ b/designer-chart/src/main/java/com/fr/van/chart/scatter/ScatterIndependentVanChartInterface.java @@ -4,6 +4,10 @@ package com.fr.van.chart.scatter; import com.fr.chart.chartattr.Chart; import com.fr.chart.chartattr.Plot; import com.fr.design.beans.BasicBeanPane; +import com.fr.design.chartx.AbstractVanSingleDataPane; +import com.fr.design.chartx.fields.diff.ScatterCellDataFieldsPane; +import com.fr.design.chartx.fields.diff.ScatterDataSetFieldsPane; +import com.fr.design.chartx.single.SingleDataPane; import com.fr.design.condition.ConditionAttributesPane; import com.fr.design.gui.frpane.AttributeChangeListener; import com.fr.design.i18n.Toolkit; @@ -14,6 +18,7 @@ import com.fr.design.mainframe.chart.gui.data.report.AbstractReportDataContentPa import com.fr.design.mainframe.chart.gui.data.report.BubblePlotReportDataContentPane; import com.fr.design.mainframe.chart.gui.data.table.AbstractTableDataContentPane; import com.fr.design.mainframe.chart.gui.type.AbstractChartTypePane; +import com.fr.plugin.chart.vanchart.VanChart; import com.fr.van.chart.designer.other.VanChartInteractivePaneWithOutSort; import com.fr.van.chart.designer.other.VanChartOtherPane; import com.fr.van.chart.designer.other.zoom.ZoomPane; @@ -103,4 +108,14 @@ public class ScatterIndependentVanChartInterface extends AbstractIndependentVanC public ConditionAttributesPane getPlotConditionPane(Plot plot) { return new VanChartScatterConditionPane(plot); } + + @Override + public ChartDataPane getChartDataPane(AttributeChangeListener listener) { + return new AbstractVanSingleDataPane(listener) { + @Override + protected SingleDataPane createSingleDataPane(VanChart vanChart) { + return new SingleDataPane(new ScatterDataSetFieldsPane(), new ScatterCellDataFieldsPane()); + } + }; + } } \ No newline at end of file diff --git a/designer-chart/src/main/java/com/fr/van/chart/structure/desinger/VanStructureChartTypeUI.java b/designer-chart/src/main/java/com/fr/van/chart/structure/desinger/VanStructureChartTypeUI.java index 19f5abd5a..3238a51b5 100644 --- a/designer-chart/src/main/java/com/fr/van/chart/structure/desinger/VanStructureChartTypeUI.java +++ b/designer-chart/src/main/java/com/fr/van/chart/structure/desinger/VanStructureChartTypeUI.java @@ -16,6 +16,7 @@ import com.fr.design.mainframe.chart.gui.ChartStylePane; import com.fr.design.mainframe.chart.gui.data.report.AbstractReportDataContentPane; import com.fr.design.mainframe.chart.gui.data.table.AbstractTableDataContentPane; import com.fr.design.mainframe.chart.gui.type.AbstractChartTypePane; +import com.fr.plugin.chart.vanchart.VanChart; import com.fr.van.chart.designer.other.VanChartInteractivePaneWithOutSort; import com.fr.van.chart.designer.other.VanChartOtherPane; import com.fr.van.chart.designer.other.zoom.ZoomPane; @@ -107,7 +108,7 @@ public class VanStructureChartTypeUI extends AbstractIndependentVanChartUI { public ChartDataPane getChartDataPane(AttributeChangeListener listener) { return new AbstractVanSingleDataPane(listener) { @Override - protected SingleDataPane createSingleDataPane() { + protected SingleDataPane createSingleDataPane(VanChart vanChart) { return new SingleDataPane(new StructureDataSetFieldsPane(), new StructureCellDataFieldsPane()); } }; diff --git a/designer-chart/src/main/java/com/fr/van/chart/vanchart/AbstractIndependentVanChartUI.java b/designer-chart/src/main/java/com/fr/van/chart/vanchart/AbstractIndependentVanChartUI.java index 39e22492f..3e4d32503 100644 --- a/designer-chart/src/main/java/com/fr/van/chart/vanchart/AbstractIndependentVanChartUI.java +++ b/designer-chart/src/main/java/com/fr/van/chart/vanchart/AbstractIndependentVanChartUI.java @@ -13,6 +13,7 @@ import com.fr.design.mainframe.chart.gui.data.report.AbstractReportDataContentPa import com.fr.design.mainframe.chart.gui.data.report.CategoryPlotReportDataContentPane; import com.fr.design.mainframe.chart.gui.data.table.AbstractTableDataContentPane; import com.fr.design.mainframe.chart.gui.data.table.CategoryPlotTableDataContentPane; +import com.fr.plugin.chart.vanchart.VanChart; import com.fr.van.chart.designer.other.VanChartOtherPane; import com.fr.van.chart.designer.style.VanChartStylePane; @@ -55,7 +56,7 @@ public abstract class AbstractIndependentVanChartUI extends AbstractIndependentC public ChartDataPane getChartDataPane(AttributeChangeListener listener) { return new AbstractVanSingleDataPane(listener) { @Override - protected SingleDataPane createSingleDataPane() { + protected SingleDataPane createSingleDataPane(VanChart vanChart) { return new SingleDataPane(new SingleCategoryDataSetFieldsPane(), new SingleCategoryCellDataFieldsPane()); } }; diff --git a/designer-chart/src/main/java/com/fr/van/chart/vanchart/AbstractMultiCategoryVanChartUI.java b/designer-chart/src/main/java/com/fr/van/chart/vanchart/AbstractMultiCategoryVanChartUI.java index 6cd2743fe..1505b09ca 100644 --- a/designer-chart/src/main/java/com/fr/van/chart/vanchart/AbstractMultiCategoryVanChartUI.java +++ b/designer-chart/src/main/java/com/fr/van/chart/vanchart/AbstractMultiCategoryVanChartUI.java @@ -15,6 +15,7 @@ import com.fr.design.mainframe.chart.gui.data.report.CategoryPlotReportDataConte import com.fr.design.mainframe.chart.gui.data.table.AbstractTableDataContentPane; import com.fr.design.mainframe.chart.gui.data.table.CategoryPlotTableDataContentPane; import com.fr.plugin.chart.attr.plot.VanChartPlot; +import com.fr.plugin.chart.vanchart.VanChart; import com.fr.van.chart.designer.data.VanChartMoreCateReportDataContentPane; import com.fr.van.chart.designer.data.VanChartMoreCateTableDataContentPane; import com.fr.van.chart.designer.other.VanChartInteractivePane; @@ -69,7 +70,7 @@ public abstract class AbstractMultiCategoryVanChartUI extends AbstractIndependen public ChartDataPane getChartDataPane(AttributeChangeListener listener) { return new AbstractVanSingleDataPane(listener) { @Override - protected SingleDataPane createSingleDataPane() { + protected SingleDataPane createSingleDataPane(VanChart vanChart) { return new SingleDataPane(new MultiCategoryDataSetFieldsPane(), new MultiCategoryCellDataFieldsPane()); } }; diff --git a/designer-chart/src/main/java/com/fr/van/chart/wordcloud/designer/WordCloudIndependentVanChartInterface.java b/designer-chart/src/main/java/com/fr/van/chart/wordcloud/designer/WordCloudIndependentVanChartInterface.java index b978d9355..b40f5f76c 100644 --- a/designer-chart/src/main/java/com/fr/van/chart/wordcloud/designer/WordCloudIndependentVanChartInterface.java +++ b/designer-chart/src/main/java/com/fr/van/chart/wordcloud/designer/WordCloudIndependentVanChartInterface.java @@ -15,6 +15,7 @@ import com.fr.design.mainframe.chart.AbstractChartAttrPane; import com.fr.design.mainframe.chart.gui.ChartDataPane; import com.fr.design.mainframe.chart.gui.ChartStylePane; import com.fr.design.mainframe.chart.gui.type.AbstractChartTypePane; +import com.fr.plugin.chart.vanchart.VanChart; import com.fr.van.chart.designer.other.VanChartInteractivePaneWithOutSort; import com.fr.van.chart.designer.other.VanChartOtherPane; import com.fr.van.chart.designer.other.zoom.ZoomPane; @@ -102,7 +103,7 @@ public class WordCloudIndependentVanChartInterface extends AbstractIndependentVa public ChartDataPane getChartDataPane(AttributeChangeListener listener) { return new AbstractVanSingleDataPane(listener) { @Override - protected SingleDataPane createSingleDataPane() { + protected SingleDataPane createSingleDataPane(VanChart vanChart) { return new SingleDataPane(new WordCloudDataSetFieldsPane(), new WordCloudCellDataFieldsPane()); } }; From edae2bdcbf58abc88d3943320457c636b41e8158 Mon Sep 17 00:00:00 2001 From: "Wim.Zhai" Date: Mon, 4 Nov 2019 14:09:06 +0800 Subject: [PATCH 3/3] =?UTF-8?q?style=20=E8=BF=98=E9=9C=80=E6=8C=89?= =?UTF-8?q?=E5=9B=BE=E8=A1=A8=E7=B1=BB=E5=9E=8B=E5=88=87=E6=8D=A2=E6=95=B0?= =?UTF-8?q?=E6=8D=AE=E9=9D=A2=E6=9D=BF=20#CHART-4248?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/fr/design/chartx/AbstractChartDataPane.java | 2 +- .../fr/design/chartx/AbstractVanSingleDataPane.java | 7 +++---- .../com/fr/design/chartx/CustomChartDataPane.java | 8 ++++---- .../com/fr/design/chartx/GanttChartDataPane.java | 5 ++--- .../fr/design/mainframe/chart/gui/ChartDataPane.java | 8 ++------ .../bubble/BubbleIndependentVanChartInterface.java | 12 ++---------- .../designer/FunnelIndependentVanChartInterface.java | 3 +-- .../MultiPieIndependentVanChartInterface.java | 3 +-- .../scatter/ScatterIndependentVanChartInterface.java | 3 +-- .../structure/desinger/VanStructureChartTypeUI.java | 3 +-- .../vanchart/AbstractIndependentVanChartUI.java | 3 +-- .../vanchart/AbstractMultiCategoryVanChartUI.java | 3 +-- .../WordCloudIndependentVanChartInterface.java | 3 +-- 13 files changed, 21 insertions(+), 42 deletions(-) diff --git a/designer-chart/src/main/java/com/fr/design/chartx/AbstractChartDataPane.java b/designer-chart/src/main/java/com/fr/design/chartx/AbstractChartDataPane.java index aa776f489..61359d91b 100644 --- a/designer-chart/src/main/java/com/fr/design/chartx/AbstractChartDataPane.java +++ b/designer-chart/src/main/java/com/fr/design/chartx/AbstractChartDataPane.java @@ -32,7 +32,7 @@ public abstract class AbstractChartDataPane