diff --git a/common/changes/@visactor/vtable/fix-issue-5213-aggregation-series-number_2026-07-14-20-50.json b/common/changes/@visactor/vtable/fix-issue-5213-aggregation-series-number_2026-07-14-20-50.json
new file mode 100644
index 000000000..13a5b655a
--- /dev/null
+++ b/common/changes/@visactor/vtable/fix-issue-5213-aggregation-series-number_2026-07-14-20-50.json
@@ -0,0 +1,11 @@
+{
+ "changes": [
+ {
+ "comment": "fix: hide row series number in aggregation rows",
+ "type": "none",
+ "packageName": "@visactor/vtable"
+ }
+ ],
+ "packageName": "@visactor/vtable",
+ "email": "biukam.w@gmail.com"
+}
\ No newline at end of file
diff --git a/packages/vtable/__tests__/options/listTable-row-series-number-aggregation.test.ts b/packages/vtable/__tests__/options/listTable-row-series-number-aggregation.test.ts
new file mode 100644
index 000000000..188afc922
--- /dev/null
+++ b/packages/vtable/__tests__/options/listTable-row-series-number-aggregation.test.ts
@@ -0,0 +1,39 @@
+// @ts-nocheck
+import { ListTable, TYPES } from '../../src';
+import { createDiv } from '../dom';
+
+global.__VERSION__ = 'none';
+
+describe('ListTable row series number with aggregation', () => {
+ const container = createDiv();
+ container.style.width = '600px';
+ container.style.height = '400px';
+
+ const table = new ListTable(container, {
+ records: [{ value: 1 }, { value: 2 }],
+ columns: [
+ {
+ field: 'value',
+ title: 'Value',
+ aggregation: {
+ aggregationType: TYPES.AggregationType.SUM
+ }
+ }
+ ],
+ rowSeriesNumber: {
+ title: 'No.'
+ }
+ });
+
+ afterAll(() => {
+ table.release();
+ });
+
+ test('does not display a series number in the aggregation row', () => {
+ const aggregationRow = table.rowCount - 1;
+
+ expect(table.internalProps.layoutMap.isAggregation(0, aggregationRow)).toBe(true);
+ expect(table.getCellValue(0, aggregationRow)).toBe('');
+ expect(table.getCellOriginValue(0, aggregationRow)).toBe('');
+ });
+});
diff --git a/packages/vtable/examples/debug/issue-5213-row-series-number-aggregation.ts b/packages/vtable/examples/debug/issue-5213-row-series-number-aggregation.ts
new file mode 100644
index 000000000..42efd2690
--- /dev/null
+++ b/packages/vtable/examples/debug/issue-5213-row-series-number-aggregation.ts
@@ -0,0 +1,84 @@
+import * as VTable from '../../src';
+
+const CONTAINER_ID = 'vTable';
+
+const removeDemoToolbar = () => {
+ document.getElementById('issue5213Toolbar')?.remove();
+};
+
+const setStatus = (message: string, pass: boolean) => {
+ const statusNode = document.getElementById('issue5213Status');
+ if (!statusNode) {
+ return;
+ }
+ statusNode.textContent = message;
+ statusNode.style.color = pass ? '#237804' : '#cf1322';
+};
+
+export function createTable() {
+ removeDemoToolbar();
+
+ const container = document.getElementById(CONTAINER_ID)!;
+ container.style.width = '640px';
+ container.style.height = '360px';
+
+ const toolbar = document.createElement('div');
+ toolbar.id = 'issue5213Toolbar';
+ toolbar.style.cssText = [
+ 'display: flex',
+ 'gap: 8px',
+ 'align-items: center',
+ 'height: 40px',
+ 'font-size: 12px'
+ ].join(';');
+ toolbar.innerHTML = `
+
+ 预期:聚合行序号列为空;旧逻辑会显示行号。
+
+ `;
+ container.before(toolbar);
+
+ const tableInstance = new VTable.ListTable(container, {
+ records: [{ value: 1 }, { value: 2 }],
+ columns: [
+ {
+ field: 'value',
+ title: 'Value',
+ width: 160,
+ aggregation: {
+ aggregationType: VTable.TYPES.AggregationType.SUM
+ }
+ }
+ ],
+ rowSeriesNumber: {
+ title: 'No.'
+ },
+ defaultRowHeight: 36
+ });
+
+ const checkAggregationSeriesNumber = () => {
+ const aggregationRow = tableInstance.rowCount - 1;
+ const displayValue = tableInstance.getCellValue(0, aggregationRow);
+ const originValue = tableInstance.getCellOriginValue(0, aggregationRow);
+ const isAggregation = tableInstance.internalProps.layoutMap.isAggregation(0, aggregationRow);
+ const pass = isAggregation && displayValue === '' && originValue === '';
+
+ setStatus(
+ `${pass ? 'PASS' : 'FAIL'} | aggregationRow=${aggregationRow}, display=${String(displayValue)}, origin=${String(
+ originValue
+ )}`,
+ pass
+ );
+ };
+
+ document.getElementById('issue5213Check')?.addEventListener('click', checkAggregationSeriesNumber);
+ requestAnimationFrame(checkAggregationSeriesNumber);
+
+ const release = tableInstance.release.bind(tableInstance);
+ tableInstance.release = () => {
+ removeDemoToolbar();
+ release();
+ };
+
+ (window as any).tableInstance = tableInstance;
+}
diff --git a/packages/vtable/examples/menu.ts b/packages/vtable/examples/menu.ts
index 5f040cb70..2474d4e3a 100644
--- a/packages/vtable/examples/menu.ts
+++ b/packages/vtable/examples/menu.ts
@@ -50,6 +50,10 @@ export const menus = [
path: 'debug',
name: 'issue-5187-max-frozen-width'
},
+ {
+ path: 'debug',
+ name: 'issue-5213-row-series-number-aggregation'
+ },
{
path: 'debug',
name: 'header-frame-border-null-color'
diff --git a/packages/vtable/src/ListTable.ts b/packages/vtable/src/ListTable.ts
index c11e7b061..c72ae28f2 100644
--- a/packages/vtable/src/ListTable.ts
+++ b/packages/vtable/src/ListTable.ts
@@ -590,6 +590,9 @@ export class ListTable extends BaseTable implements ListTableAPI {
const { title } = table.internalProps.layoutMap.getSeriesNumberHeader(col, row);
return title;
}
+ if (table.internalProps.layoutMap.isAggregation(col, row)) {
+ return '';
+ }
let value;
if ((this.internalProps as ListTableProtected).groupBy) {
const record = table.getCellRawRecord(col, row);
@@ -640,6 +643,9 @@ export class ListTable extends BaseTable implements ListTableAPI {
const { title } = table.internalProps.layoutMap.getSeriesNumberHeader(col, row);
return title;
}
+ if (table.internalProps.layoutMap.isAggregation(col, row)) {
+ return '';
+ }
const { format } = table.internalProps.layoutMap.getSeriesNumberBody(col, row);
return typeof format === 'function' ? format(col, row, this) : row - this.columnHeaderLevelCount;
} else if (table.internalProps.layoutMap.isHeader(col, row)) {