Skip to content

Atlas 0.4.0: enum labels on Cypher tables, every record row and static properties in Current - #2

Merged
charlfourieflow merged 3 commits into
mainfrom
fix/atlas-cypher-table-enums
Dec 1, 2026
Merged

charlfourieflow merged 3 commits into
mainfrom
fix/atlas-cypher-table-enums

Conversation

@charlfourieflow

Copy link
Copy Markdown
Contributor

Three changes that let dashboards use picker selections instead of hand-written Cypher, and Atlas enumerations instead of hand-made value mappings.

Change Before After
Enum labels on Cypher tables RETURN p.AlarmCode.Value AS Alarm showed 53 Shows "Axis servo fault". Columns that return an enumeration-bound property of a typed variable get the same value mappings as the Data view. Expressions, functions and untyped variables are left as returned.
Every record row in Data > Current MaintainX LiveOpenWorkOrders showed one work order per machine One table row per open work order (Columns), ordered by sequential number; numbered parts in Rows
Static properties in Data > Current Specialty, SerialNumber could not be picked, and type or nested picks dropped them Listed in the selection tree as "fixed value" in Current mode only; Trend is unchanged

Why the record fix reads with a typed UNWIND

Atlas's node read (MATCH (n) ... RETURN n) returns one row of a multi-row record, and so does UNWIND over an untyped (n). MATCH (n:CNCMachine) ... UNWIND n.LiveOpenWorkOrders returns every current row. Live-checked on Atlas 2.0.1 against MaintainX: CNC03 gives #21, #27, #30, the same open work orders as MaintainX.

Testing

  • Go: go vet, go test ./pkg/... (new tests: cypherenums_test.go, records_test.go), gofmt clean.
  • Frontend: typecheck, lint, Prettier, Jest (new withStatic test), production build.
  • Live in the dev Grafana against the local cesmii-workshop domain: AlarmCode, Program, ControllerMode and AlarmActive columns labelled from Atlas enums; 12 open work orders across CNC01–CNC05 matching MaintainX; Technician Specialty read through a type selection. The CESMII workshop dashboard now uses selections for every panel except the cross-type attention list.

Version bumped to 0.4.0 (package.json, package-lock.json, CHANGELOG). After merge, tagging atlas-v0.4.0 publishes the pre-release.

🤖 Generated with Claude Code

charlfourieflow and others added 3 commits November 27, 2026 10:46
A Cypher table column is only a name, so enumeration-bound properties
showed raw keys (53 instead of "Axis servo fault") and dashboards needed
hand-made value mappings. The plugin now reads the query text: node
patterns give each variable its type, and RETURN items that are plain
property reads (p.Prop, p.Prop.Value, optional AS alias) are looked up
against the domain's enumerations. Matching columns get the same value
mappings the Data view attaches. Anything else is left as returned.

Live-checked on the local cesmii-workshop domain: AlarmCode, Program and
ControllerMode columns carry their labels; FeedRate and entityId do not.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Two gaps kept dashboards on hand-written Cypher:

- A multi-row record (MaintainX LiveOpenWorkOrders) showed one work
  order per machine. Atlas's node read returns one row, and so does an
  UNWIND over an untyped (n); MATCH (n:Type) ... UNWIND returns every
  current row (live-checked: CNC03 #21, #27, #30, as in MaintainX).
  Current now re-reads record properties that way and gives one table
  row per record row (Columns), ordered by the row's SequentialId, or
  numbered parts (Rows).
- Static properties (Specialty, SerialNumber) were neither offered in
  the tree nor read for type and nested picks. The tree resource now
  lists them per instance; the Data editor shows them, marked "fixed
  value", in Current mode only, and expandPicks accepts them for
  Current. Trend is unchanged.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…d static properties in Current

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@charlfourieflow
charlfourieflow merged commit 9587fbc into main Dec 1, 2026
1 check passed
@charlfourieflow
charlfourieflow deleted the fix/atlas-cypher-table-enums branch December 1, 2026 11:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant