소스 검색

调整

develop
H Vs 1 개월 전
부모
커밋
ba5fab6bb8
1개의 변경된 파일12개의 추가작업 그리고 2개의 파일을 삭제
  1. +12
    -2
      resources/login_resources.py

+ 12
- 2
resources/login_resources.py 파일 보기

@@ -69,7 +69,15 @@ class GetLoginWxQRCodeResource(Resource):
app_id=loginfo.get('appId','')
qr_code = gewe_chat.wxchat.get_login_qr_code(token_id, app_id,region_id)
base64_string = qr_code.get('qrImgBase64',None)

if not qr_code:
msg=f"获取二维码失败,qr_code: {qr_code}"
gewe_chat.wxchat.release_login_lock(token_id)
logger.info(msg)
response=jsonify({'code': 501, 'message': msg})
response.status_code = 501
return response

uuid = qr_code.get('uuid',None)
if not uuid:
msg=f"uuid获取二维码失败,uuid: {uuid}"
@@ -80,8 +88,10 @@ class GetLoginWxQRCodeResource(Resource):
return response


app_id = app_id or qr_code.get('appId')

base64_string = qr_code.get('qrImgBase64',None)
gewe_chat.wxchat.qrCallback(uuid,base64_string)
hash_key = f"__AI_OPS_WX__:LOGININFO:{tel}"
thread = threading.Thread(target=waitting_login_result, args=(gewe_chat.wxchat,token_id, app_id,region_id, agent_token_id,hash_key, uuid,now))


Loading…
취소
저장