fix(alarms): historize the real operator for shelve/unshelve/enable/disable transitions
This commit is contained in:
@@ -512,7 +512,13 @@ public sealed class ScriptedAlarmHostActor : ReceiveActor
|
||||
{
|
||||
EmissionKind.Acknowledged => e.Condition.LastAckUser ?? "system",
|
||||
EmissionKind.Confirmed => e.Condition.LastConfirmUser ?? "system",
|
||||
EmissionKind.CommentAdded => e.Condition.Comments.Count > 0 ? e.Condition.Comments[^1].User : "system",
|
||||
// Shelve / unshelve / enable / disable / comment ops each append the acting user as the LAST audit
|
||||
// entry on the emitted condition (engine auto-unshelve appends "system"); read it from there.
|
||||
EmissionKind.CommentAdded
|
||||
or EmissionKind.Shelved
|
||||
or EmissionKind.Unshelved
|
||||
or EmissionKind.Enabled
|
||||
or EmissionKind.Disabled => e.Condition.Comments.Count > 0 ? e.Condition.Comments[^1].User : "system",
|
||||
_ => "system",
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user