Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

修复多仓库默认绑定当前群聊 #235

Merged
merged 3 commits into from
Feb 26, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 5 additions & 3 deletions server/tasks/lark/manage.py
Original file line number Diff line number Diff line change
Expand Up @@ -340,12 +340,14 @@ def create_chat_group_for_repo(
# 把user_id_list中的每个user_id查User表,获取每个人的名字
user_name_list = [
name
for name, in db.session.query(IMUser.name).filter(
for name, in db.session.query(IMUser.name)
.filter(
IMUser.openid.in_(user_id_list),
)
.distinct()
]
try:
chat_id == args[1]["event"]["message"]["chat_id"]
chat_id = args[1]["event"]["message"]["chat_id"]
except Exception as e:
chat_id = ""

Expand Down Expand Up @@ -382,7 +384,7 @@ def create_chat_group_for_repo(

content = "\n".join(
[
f"1. 成功绑定名为「{chat_name}」的项目群",
f"1. 成功绑定名为「{chat_name if chat_name else exists_chat_group.name}」的项目群",
invite_message,
]
)
Expand Down
Loading