You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
tailchat/website/i18n/zh-Hans/docusaurus-plugin-content-blog/2023-09-19-view-panel-permi...

28 lines
694 B
Markdown

This file contains ambiguous Unicode characters!

This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.

---
title: 群组查看面板权限问题
authors: moonrailgun
image: /img/logo.svg
slug: view-panel-permission
keywords:
- tailchat
tags: []
---
由于新版本的群组权限,所有之前创建群组的群组用户都无法查看面板,因为失去了查看面板权限。
要批量更新所有群组权限,您可能需要下面的脚本。
进入 `mongodb bash`您可以在bash中使用脚本如下操作`docker exec -it <your-mongodb-container-name> mongo`
### 切换到 tailchat 数据库
```
use tailchat
```
### 更新所有组并向所有组附加 `core.viewPanel` 权限
```
db.groups.updateMany({}, { $addToSet: {fallbackPermissions: "core.viewPanel" } })
```