소스 검색

小程序图片

wushaodong 4 년 전
부모
커밋
01ff1e1033
1개의 변경된 파일2개의 추가작업 그리고 2개의 파일을 삭제
  1. 2 2
      utils/wx/wechat.py

+ 2 - 2
utils/wx/wechat.py

@@ -230,7 +230,7 @@ class WeChat(object):
         '''获取小程序二维码'''
         url = 'https://api.weixin.qq.com/wxa/getwxacodeunlimit?access_token={}'.format(access_token)
         data = {"scene": "company_no={}".format(company_no),
-                "width": 1280,
+                # "width": 1280, # 默认430
                 "line_color": {"r": 43, "g": 162, "b": 69},  # 自定义颜色
                 "is_hyaline": True}
         result = requests.post(url, json=data)
@@ -251,7 +251,7 @@ class WeChat(object):
         '''获取设备二维码'''
         url = 'https://api.weixin.qq.com/wxa/getwxacodeunlimit?access_token={}'.format(access_token)
         data = {"scene": "company_no={}&device_id={}".format(company_no, device_id),
-                "width": 1280,
+                # "width": 1280, # 默认430
                 "line_color": {"r": 43, "g": 162, "b": 69},  # 自定义颜色
                 "is_hyaline": True}
         result = requests.post(url, json=data)