feat(approvals): display contract v2 — no raw identifiers anywhere#1737
Merged
Conversation
A business reviewer of the revamped inbox still met raw ids in three places: lookup foreign keys inside the payload summary (e.g. an account shown as dpOfPMy7cbeEL1jk), user-id approvers in the waiting-on chips, and actor ids in the audit timeline. Extend the enrichment pass: - payload_display — lookup/master_detail fields in the snapshot resolve to the referenced record's display title (schema `reference`, batched one query per referenced object). - pending_approver_names — user-id approvers resolve via sys_user (id or email); role:<r> literals stay as-is, already readable. - object_label — the target object's schema label rides the row. - listActions rows carry actor_name so the timeline never shows an id. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Follow-up to #1728 after a business-UX pass on the revamped inbox: three surfaces still leaked raw identifiers. The enrichment pass now guarantees a client never has to render an id:
payload_display— lookup/master_detail foreign keys in the record snapshot resolve to the referenced record's display title (via the field's schemareference, batched one query per referenced object).Account: dpOfPMy7cbeEL1jk→Account: Fabrikam.pending_approver_names— user-id entries inpending_approversresolve viasys_user(id or email);role:<r>literals pass through, already readable.object_label— the target object's schema label (e.g. "Project" forshowcase_project).actor_nameonlistActionsrows — the audit timeline never shows an id.Test plan
payload_display: {account: "Contoso"},pending_approver_names,object_label: "Project"; Console drawer renders Fabrikam/Northwind/Contoso instead of foreign keys ✅🤖 Generated with Claude Code