浏览代码

调整

develop
H Vs 1 天前
父节点
当前提交
5e449be9f2
共有 1 个文件被更改,包括 4 次插入3 次删除
  1. +4
    -3
      app/endpoints/pipeline_endpoint.py

+ 4
- 3
app/endpoints/pipeline_endpoint.py 查看文件

@@ -83,8 +83,9 @@ async def handle_self_cmd_async(request: Request,wxid,msg):
'''
msg_data=msg.get("Data")
to_wxid=msg_data["ToUserName"]["string"]
from_wxid=msg_data["FromUserName"]["string"]
msg_content=msg_data["Content"]["string"]
if wxid == to_wxid:
if from_wxid == to_wxid:
commands = {
'启用托管': True,
'关闭托管': False
@@ -381,7 +382,7 @@ async def handle_text_async(request: Request,token_id,app_id, wxid,msg_data,from


msg_content=msg_data["Content"]["string"]
if wxid == to_wxid: #手动发送消息
if from_wxid == to_wxid: #手动发送消息
logger.info("Active message sending detected")
await request.app.state.gewe_service.save_contacts_brief_to_cache_async(token_id,app_id,wxid,[to_wxid])
@@ -678,7 +679,7 @@ async def handle_text_group_async(request: Request,token_id,app_id, wxid,msg_dat
logger.warning(f"微信号 {wxid} 关闭好友和群自动回复功能,{handle_text_group_async.__name__} 不回复消息")
return

if wxid == to_wxid: #手动发送消息
if from_wxid == to_wxid: #手动发送消息
logger.info("Active message sending detected")
await request.app.state.gewe_service.save_contacts_brief_to_cache_async(token_id,app_id,wxid,[to_wxid])


正在加载...
取消
保存