Skip to content

Commit 85f0238

Browse files
Copilothotlong
andcommitted
docs: add clarifying comment for count measure key mapping
Agent-Logs-Url: https://github.com/objectstack-ai/objectui/sessions/7e803790-d91b-4542-886e-743490f0dfc6 Co-authored-by: hotlong <50353452+hotlong@users.noreply.github.com>
1 parent bb317b4 commit 85f0238

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

packages/data-objectstack/src/index.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -855,6 +855,8 @@ export class ObjectStackAdapter<T = unknown> implements DataSource<T> {
855855

856856
// Map measure keys back to the original field name so that consumers
857857
// (ObjectChart, DashboardRenderer, etc.) can access values by field name.
858+
// This includes count → field (e.g. 'count' → 'amount') to match the
859+
// output format of aggregateClientSide() which always uses params.field.
858860
return rawRows.map((row: any) => {
859861
const mapped = { ...row };
860862
if (measureName !== params.field && measureName in mapped) {

0 commit comments

Comments
 (0)