Merge remote-tracking branch 'origin/test/export_add_number_column' into develop
This commit is contained in:
commit
e138171039
1 changed files with 9 additions and 4 deletions
|
|
@ -88,7 +88,10 @@ public class ExportGridV2Service extends GridV2ServiceImpl {
|
|||
int minWidth = 20;
|
||||
int padding = 5;
|
||||
|
||||
int colIndex = hasAggregationValues ? 1 : 0;
|
||||
createCell(row, 0, "№", style);
|
||||
autosizeByHeader(sheet, 0, "№", 5, 3);
|
||||
|
||||
int colIndex = hasAggregationValues ? 2 : 1;
|
||||
for (GridColumn column : orderedColumns) {
|
||||
createCell(row, colIndex, column.displayName, style);
|
||||
autosizeByHeader(sheet, colIndex, column.displayName, minWidth, padding);
|
||||
|
|
@ -134,8 +137,9 @@ public class ExportGridV2Service extends GridV2ServiceImpl {
|
|||
GridColumnAggregationValues aggregationValues = gridRows.getAggregationValues();
|
||||
|
||||
for (GridRow gridRow : gridRows.getRows()) {
|
||||
int columnCount = aggregationValues != null ? 1 : 0;
|
||||
Row row = sheet.createRow(rowCount++);
|
||||
Row row = sheet.createRow(rowCount);
|
||||
createCell(row, 0, rowCount, style);
|
||||
int columnCount = aggregationValues != null ? 2 : 1;
|
||||
row.setHeight((short) -1);
|
||||
for (GridColumn gridColumn : orderedColumns) {
|
||||
createCell(row, columnCount,
|
||||
|
|
@ -143,6 +147,7 @@ public class ExportGridV2Service extends GridV2ServiceImpl {
|
|||
);
|
||||
columnCount++;
|
||||
}
|
||||
rowCount++;
|
||||
}
|
||||
|
||||
if (aggregationValues != null) {
|
||||
|
|
@ -150,7 +155,7 @@ public class ExportGridV2Service extends GridV2ServiceImpl {
|
|||
CellStyle boldStyle = createBoldStyle(workbook);
|
||||
createCell(aggregationRow, 0, aggregationHeaderForExport, boldStyle);
|
||||
|
||||
int columnCount = 1;
|
||||
int columnCount = 2;
|
||||
for (GridColumn gridColumn : orderedColumns) {
|
||||
createCell(aggregationRow, columnCount,
|
||||
aggregationValues.get(getClientColumnId(gridColumn)), boldStyle
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue