fix: omit admin-only actions from group notices
This commit is contained in:
+2
-2
@@ -5451,11 +5451,11 @@ func serveIMGroupGovernance(wrt http.ResponseWriter, req *http.Request, topic st
|
||||
text = "群聊邀请确认已启用,群成员邀请好友进群需要群主或管理员确认。"
|
||||
}
|
||||
publishIMConversationSystemNotice(principal.TenantID, topic,
|
||||
"system_action", template, text,
|
||||
"system_notice", template, text,
|
||||
[]imSystemMessageActor{
|
||||
{UserID: principal.Uid.UserId(), Click: map[string]any{"type": "user_profile", "target_id": principal.Uid.UserId()}},
|
||||
},
|
||||
[]imSystemMessageAction{{Type: "open_group_invite_settings", Label: "群聊邀请确认", TargetID: topic, MinRole: "admin"}},
|
||||
nil,
|
||||
map[string]any{"join_approval": *body.JoinApproval, "version": settings.Version})
|
||||
}
|
||||
if body.MemberPrivateChat != nil && imReliableHTTPEventsEnabled(req) {
|
||||
|
||||
Reference in New Issue
Block a user