Browse Source

Merge pull request #6399 in DESIGN/design from final/10.0 to release/10.0

* commit 'c73dd20885961a8fbfbd36378ace96fdb38d41af':
  REPORT-50016 填报属性设置-智能添加单元格组-出现重复单元格
zheng-1641779399395
superman 3 years ago
parent
commit
8226b0d95a
  1. 9
      designer-realize/src/main/java/com/fr/design/write/submit/SmartInsertDBManipulationPane.java

9
designer-realize/src/main/java/com/fr/design/write/submit/SmartInsertDBManipulationPane.java

@ -431,7 +431,7 @@ public class SmartInsertDBManipulationPane extends DBManipulationPane {
if (oriCellSelection != null && isSameStartPoint(cellselection, oriCellSelection)) {
dealDragSelection(add, cellselection, newValue);
} else if (cellselection.getSelectedType() == CellSelection.CHOOSE_ROW || cellselection.getSelectedType() == CellSelection.CHOOSE_COLUMN) {
dealSelectColRow(add, cellselection);
dealSelectColRow(add, cellselection, newValue);
} else {
ColumnRow columnRow = ColumnRow.valueOf(cellselection.getColumn(), cellselection.getRow());
String allColumnRow = newValue.toString();
@ -503,12 +503,15 @@ public class SmartInsertDBManipulationPane extends DBManipulationPane {
return cs1.getColumn() == cs2.getColumn() && cs1.getRow() == cs2.getRow();
}
private void dealSelectColRow(ColumnRowGroup add, CellSelection se) {
private void dealSelectColRow(ColumnRowGroup add, CellSelection se, ColumnRowGroup newValue) {
int c = se.getColumn(), cs = se.getColumnSpan(),
r = se.getRow(), rs = se.getRowSpan();
for (int i = 0; i < cs; i++) {
for (int j = 0; j < rs; j++) {
add.addColumnRow(ColumnRow.valueOf(c + i, r + j));
ColumnRow columnRow = ColumnRow.valueOf(c + i, r + j);
if (!newValue.contains(columnRow)) {
add.addColumnRow(columnRow);
}
}
}
}

Loading…
Cancel
Save