Post separate decision comments as the approver
Description
Follow-up to AP-2224 (separate decision comments), split out in its review (PR 6279).
Problem
With separate decision comments on, every decision comment is posted by the Approval Path app user, with "by <name>" in its header. This applies to the work item comment (Jira) and to the reply in the approval's comment thread on the page (Confluence). Customers may want the comment to come from the person who decided.
Change
-
Global settings, under the separate decision comments setting, in Jira and Confluence: "Post decision comments as": Approval Path (default) / The approver.
-
Definition > Decision comments: the same choice, shown only when the effective choice is Separate. The global default is preselected and marked "(default)"; the definition stores nothing until a different value is picked.
-
The effective value is fixed when the approval starts, like the other decision comment options.
-
With The approver, the comment is posted as the decider. A delegate posts as the delegate, with "on behalf of <approver>" kept in the text. The header drops "by <name>", since Jira and Confluence show the author.
Acceptance criteria
-
The decision never fails because of the author choice. When the decider has no Atlassian account (email approver) or cannot comment on the work item (no Add Comments permission) or on the page (no permission to add comments), the comment is posted by the app, as today.
-
When the approver is a JSM portal customer, an internal decision comment never becomes public on the portal.
-
The settings text says that comments posted as the approver can be edited or deleted by them, so Approval Path stays the default for audit.
Manual tester notes
-
Global setting on, "Post decision comments as" = The approver: approve with a comment; the work item comment is authored by you and its header has no "by <name>".
-
The same in Confluence: the reply in the approval's thread on the page is authored by you and its header has no "by <name>".
-
Approver without Add Comments permission: the decision succeeds and the comment is posted by Approval Path.
-
Confluence approver without permission to comment on the page: the decision succeeds and the reply is posted by Approval Path.
-
Email approver: the comment is posted by Approval Path.
-
Delegate: the comment is authored by the delegate and says "on behalf of <approver>".
-
JSM: with JSM public comments off, a customer approver's decision comment stays internal.