feat(groups): allow renaming a group id

Add PUT /admin/api/groups/:id/rename (owner role) which re-points the group's routes, migrates the per-group webhook secret (tenant:{id}) and pending invites, and records an audit entry. The group editor's id field is now editable and the console renames first, then persists remaining edits under the new id.
This commit is contained in:
RhenCloud 2026-08-13 09:58:02 +08:00
parent 39bb639883
commit f4959eebf8
No known key found for this signature in database
GPG key ID: A574A617378C4E0B
11 changed files with 372 additions and 53 deletions

View file

@ -167,6 +167,8 @@ const en: Dict = {
"groupEditor.id": "ID",
"groupEditor.idPlaceholder": "my-team",
"groupEditor.idHint": "Unique, use a-z / 0-9 / dashes",
"groupEditor.renameHint":
"Changing the id also updates routes, webhook secrets and invites that reference this group.",
"groupEditor.language": "Message language",
"groupEditor.langPlaceholder": "en",
"groupEditor.langHint": "en or zh; custom via KV i18n:<lang>",
@ -416,6 +418,7 @@ const zh: Dict = {
"groupEditor.id": "ID",
"groupEditor.idPlaceholder": "my-team",
"groupEditor.idHint": "唯一,使用 a-z / 0-9 / 短横线",
"groupEditor.renameHint": "修改 id 会同步更新引用该分组的路由、webhook secret 与邀请链接。",
"groupEditor.language": "消息语言",
"groupEditor.langPlaceholder": "zh",
"groupEditor.langHint": "en 或 zh可通过 KV i18n:<lang> 自定义",