Browse Source

REPORT-35149 预定义样式优化及与图表统一

research/11.0
kerry 4 years ago
parent
commit
cb871b2bf2
  1. 6
      designer-realize/src/main/java/com/fr/design/mainframe/CellWidgetPropertyPane.java
  2. 4
      designer-realize/src/main/java/com/fr/design/mainframe/cell/CellElementEditPane.java
  3. 4
      designer-realize/src/main/java/com/fr/design/present/ConditionAttributesGroupPane.java
  4. 8
      designer-realize/src/main/java/com/fr/grid/Grid.java

6
designer-realize/src/main/java/com/fr/design/mainframe/CellWidgetPropertyPane.java

@ -11,7 +11,7 @@ import com.fr.grid.selection.Selection;
import com.fr.log.FineLoggerFactory;
import com.fr.privilege.finegrain.WidgetPrivilegeControl;
import com.fr.report.cell.CellElement;
import com.fr.report.cell.DefaultTemplateCellElement;
import com.fr.report.cell.DefaultPredefinedTemplateCellElement;
import com.fr.report.cell.TemplateCellElement;
import com.fr.report.elementcase.TemplateElementCase;
@ -59,7 +59,7 @@ public class CellWidgetPropertyPane extends BasicPane {
public void populate(TemplateCellElement cellElement) {
if (cellElement == null) {// 利用默认的CellElement.
cellElement = new DefaultTemplateCellElement(0, 0, null);
cellElement = new DefaultPredefinedTemplateCellElement(0, 0, null);
}
Widget cellWidget = cellElement.getWidget();
@ -88,7 +88,7 @@ public class CellWidgetPropertyPane extends BasicPane {
final TemplateElementCase tplEC = ePane.getEditingElementCase();
TemplateCellElement editCellElement = tplEC.getTemplateCellElement(cs.getColumn(), cs.getRow());
if (editCellElement == null) {
editCellElement = new DefaultTemplateCellElement(cs.getColumn(), cs.getRow());
editCellElement = new DefaultPredefinedTemplateCellElement(cs.getColumn(), cs.getRow());
}
this.cellElement = editCellElement;
this.populate(editCellElement);

4
designer-realize/src/main/java/com/fr/design/mainframe/cell/CellElementEditPane.java

@ -14,7 +14,7 @@ import com.fr.general.ComparatorUtils;
import com.fr.grid.selection.CellSelection;
import com.fr.grid.selection.Selection;
import com.fr.report.cell.CellElement;
import com.fr.report.cell.DefaultTemplateCellElement;
import com.fr.report.cell.DefaultPredefinedTemplateCellElement;
import com.fr.report.cell.TemplateCellElement;
import com.fr.report.elementcase.TemplateElementCase;
@ -112,7 +112,7 @@ public class CellElementEditPane extends BasicPane {
CellElement cellElement = elementCase.getCellElement(cs.getColumn(), cs.getRow());
if (cellElement == null) {
cellElement = new DefaultTemplateCellElement(cs.getColumn(), cs.getRow());
cellElement = new DefaultPredefinedTemplateCellElement(cs.getColumn(), cs.getRow());
//默认选中的是A1单元格,所以若是A1单元格没有加到列表时要加上,否则在聚合报表时会出错
if (cs.isSelectedOneCell(elementCasePane) && (cs.getColumn() + cs.getRow() == 0)) {
elementCase.addCellElement((TemplateCellElement) cellElement);

4
designer-realize/src/main/java/com/fr/design/present/ConditionAttributesGroupPane.java

@ -12,7 +12,7 @@ import com.fr.grid.selection.CellSelection;
import com.fr.grid.selection.Selection;
import com.fr.log.FineLoggerFactory;
import com.fr.report.cell.CellElement;
import com.fr.report.cell.DefaultTemplateCellElement;
import com.fr.report.cell.DefaultPredefinedTemplateCellElement;
import com.fr.report.cell.TemplateCellElement;
import com.fr.report.cell.cellattr.highlight.DefaultHighlight;
import com.fr.report.cell.cellattr.highlight.Highlight;
@ -82,7 +82,7 @@ public class ConditionAttributesGroupPane extends UIListControlPane {
final TemplateElementCase tplEC = ePane.getEditingElementCase();
editCellElement = tplEC.getTemplateCellElement(cs.getColumn(), cs.getRow());
if (editCellElement == null) {
editCellElement = new DefaultTemplateCellElement(cs.getColumn(), cs.getRow());
editCellElement = new DefaultPredefinedTemplateCellElement(cs.getColumn(), cs.getRow());
}
SheetUtils.calculateDefaultParent(tplEC); // 不知道这行代码的作用,怕去掉之后会出问题,先放在这里

8
designer-realize/src/main/java/com/fr/grid/Grid.java

@ -28,7 +28,7 @@ import com.fr.grid.selection.FloatSelection;
import com.fr.grid.selection.Selection;
import com.fr.report.ReportHelper;
import com.fr.report.cell.CellElement;
import com.fr.report.cell.DefaultTemplateCellElement;
import com.fr.report.cell.DefaultPredefinedTemplateCellElement;
import com.fr.report.cell.FloatElement;
import com.fr.report.cell.TemplateCellElement;
import com.fr.report.cell.cellattr.CellGUIAttr;
@ -865,7 +865,7 @@ public class Grid extends BaseGridComponent {
}
// 必须保证editingCellElement不是null。
if (editingCellElement == null) {
editingCellElement = new DefaultTemplateCellElement(column, row);
editingCellElement = new DefaultPredefinedTemplateCellElement(column, row);
}
editorComponent = getCellEditingComp();
if (editorComponent == null) {
@ -1029,7 +1029,7 @@ public class Grid extends BaseGridComponent {
}
// 必须保证editingCellElement不是null。
if (editingCellElement == null) {
editingCellElement = new DefaultTemplateCellElement(editingColumn, editingRow);
editingCellElement = new DefaultPredefinedTemplateCellElement(editingColumn, editingRow);
tplEC.addCellElement(editingCellElement);
}
if (setValue4EditingElement(newValue)) {
@ -1455,4 +1455,4 @@ public class Grid extends BaseGridComponent {
this.paginateLineShowType = paginateLineShowType;
this.getElementCasePane().repaint();
}
}
}

Loading…
Cancel
Save