Commit 13cae9ed by jiaqiying

fix bug

parent ccdd341b
...@@ -18,8 +18,8 @@ def request_main(url, headers, method, data): ...@@ -18,8 +18,8 @@ def request_main(url, headers, method, data):
if method.upper() == "GET": if method.upper() == "GET":
res = requests.get(url=url, headers=headers, params=data) res = requests.get(url=url, headers=headers, params=data)
elif method.upper() == "POST": elif method.upper() == "POST":
if header_content_type in ["application/x-www-form-urlencoded"]: # if header_content_type in ["application/x-www-form-urlencoded"]:
res = requests.post(url=url, headers=headers, ) res = requests.post(url=url, headers=headers, data=data)
elif header_content_type == "application/json": elif header_content_type == "application/json":
res = requests.post(url=url, headers=headers, data=json.dumps(data)) res = requests.post(url=url, headers=headers, data=json.dumps(data))
except Exception as e: except Exception as e:
......
...@@ -7,7 +7,7 @@ class BaseConfig(): ...@@ -7,7 +7,7 @@ class BaseConfig():
# 当前运行的产品名 # 当前运行的产品名
current_product = "" current_product = ""
class BMCConfig(BaseConfig): class BMCConfig(BaseConfig):
"""斑马信用app的配置类""" """斑马信用app的配置类"""
pass pass
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment