|
@@ -47,11 +47,16 @@ class MessagesResource(Resource): |
|
|
wx_config = gewe_chat.wxchat.get_wxchat_config_from_cache(wxid) |
|
|
wx_config = gewe_chat.wxchat.get_wxchat_config_from_cache(wxid) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if not bool(wx_config.get("agentEnabled",False)): |
|
|
|
|
|
logger.info(f'微信ID {wxid} 未托管,不处理') |
|
|
|
|
|
return jsonify({"message": "收到微信回调消息"}) |
|
|
|
|
|
|
|
|
# if not bool(wx_config.get("agentEnabled",False)): |
|
|
|
|
|
# logger.info(f'微信ID {wxid} 未托管,不处理') |
|
|
|
|
|
# return jsonify({"message": "收到微信回调消息"}) |
|
|
|
|
|
|
|
|
if type_name=='AddMsg': |
|
|
if type_name=='AddMsg': |
|
|
|
|
|
|
|
|
|
|
|
if not bool(wx_config.get("agentEnabled",False)): |
|
|
|
|
|
logger.info(f'微信ID {wxid} 未托管,不处理') |
|
|
|
|
|
return jsonify({"message": "收到微信回调消息"}) |
|
|
|
|
|
|
|
|
#wxid = msg.get("Wxid") |
|
|
#wxid = msg.get("Wxid") |
|
|
msg_data = msg.get("Data") |
|
|
msg_data = msg.get("Data") |
|
|
msg_type = msg_data.get("MsgType",None) |
|
|
msg_type = msg_data.get("MsgType",None) |
|
|