Skip to content

refactor: move remaining admin reads to DEMI - #972

Merged
danieltruong merged 3 commits into
developfrom
chore-demi-cross-kind
Oct 14, 2026
Merged

danieltruong merged 3 commits into
developfrom
chore-demi-cross-kind

Conversation

@danieltruong

Copy link
Copy Markdown
Collaborator

Moves the remaining eagle-api reads in eagle-admin to DEMI native routes (slice A7a of the frontend read migration).

Reads moved:

  • Project groups read /groups?project=<demiId> from the resolved project; no second projects call.
  • Notification form, comment period detail and edit, downloads and private Update thumbnails read DEMI; getAll, getById, getPins, getGroupMembers, comment and comment period getById, document getById, getByMultiId, downloadResource, downloadDocument are deleted.
  • Application sort reads /documents?project=<demiId>&sort=sortOrder&documentSource=PROJECT with type, milestone and phase filters. The old List match by name and legislation picked the wrong 2002 row ('Application Review' is both a phase and a milestone); the filter now matches on type too.
  • toLegacyProject maps projectState to status and address to location.
  • isPublicDocument and blocksPublish read isPublished on DEMI rows, since DEMI hides read.

Cleanup:

  • One eagleWriteId, one saveBlob, one DEMI_MAX_PAGE_SIZE, one shared nativeSort/tableSort; orgSort and getFormattedTime removed; jszip dropped.
  • Table template whole-sort branch removed with the lastName column it served.
  • AppComponent dropdown spec no longer depends on the karma frame height.

Still on eagle-api, by decision: project and document edit-form loads, archived detail, fullProjectResolver, and the search page (next slice).

Checks: yarn test-ci 732 passed, 1 skipped; yarn lint and npm run build clean; anonymous document parity on test, project 5885109faaecd9001b81314c: match 871, missing 0, extra 0. Staff parity and the signed-in browser check still need a staff token and login.

- Remove eagle-api reads with no callers left: project getAll,
  getById, getPins, getGroupMembers; comment getById,
  getByPeriodId, getCountByPeriodId; comment period getById,
  getAllByProjectId; document getById, getByMultiId,
  downloadResource, downloadDocument.
- Related documents, downloads and private Update thumbnails read
  DEMI (by id, presigned URL).
- Project groups use the resolved project's demiId instead of a
  second projects read.
- toLegacyProject maps projectState to status, address to location.
- One eagleWriteId in demi-ids; saveBlob in shared utils; one
  DEMI_MAX_PAGE_SIZE constant; drop unused getFormattedTime.
- Pin the AppComponent dropdown spec host to the viewport: text the
  karma reporter drew above the fixture pushed the toggle out of
  the 437px frame, which the hide modifier treats as hidden.
- Application sort lists /documents with sort=sortOrder and native
  type, milestone and phase filters. List rows match on type too, so
  'Application Review' no longer resolves to the phase id.
- Publish checks read isPublished: DEMI rows carry no read list.
- One native name sort in table-template-utils replaces orgSort and
  its copies; shared Proponent type.
- Drop unused jszip.
@danieltruong
danieltruong merged commit bd21ce6 into develop Oct 14, 2026
4 checks passed
@danieltruong
danieltruong deleted the chore-demi-cross-kind branch October 14, 2026 17:33
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