You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix(detail): the approval band honors the node's lockRecord instead of assuming every approval locks (#2902) (#2906)
The detail page treated "a pending approval request exists" as "this record is
locked". An approval node declares `lockRecord` (default `true`), and on
`lockRecord: false` the server keeps accepting writes while that node waits —
so the console asserted a lock the backend did not enforce.
The label was the smaller half. The same conflated signal fed `canEdit`, so the
record-level inline-edit session was suppressed too: no pencils, `enter()` a
no-op. On a single-approver step — the case `lockRecord: false` exists for,
where the approver is meant to fill in the missing detail before deciding — the
capability was unreachable from the UI. And a flow chaining nodes with different
policies drew one identical band for "edit freely" and "your save dies with
RECORD_LOCKED", so the states were indistinguishable until Save failed.
Approval state is now two signals: `approvalPending` (an approval is running —
drives the band and recall, both meaningful either way) and `locked` (it also
forbids edits, from the pending node's `lock_record`). The band renders amber
lock + "Locked for approval" or sky clock + "In approval · editable", each with
its own tooltip; recall left the locked branch, since an editable pending
approval is just as recallable.
`InlineEditProvider`'s new `approvalPending` prop defaults to `locked`, so a
host threading only `locked` is unchanged. The `approval_status` fallback has no
node granularity and still reads as locked, as does a pending request from a
backend too old to report the policy — failing closed beats offering an edit the
server rejects.
Needs framework#3814 for `lock_record` on the request row.
Closes#2902
Co-authored-by: Claude Opus 5 <noreply@anthropic.com>
0 commit comments