This commit is contained in:
parent
95ccf2865d
commit
d4a5735d57
@ -1,4 +1,6 @@
|
||||
# pzx-web-api
|
||||
|
||||
[![Build Status](https://drone.bearcatlog.com/api/badges/Bryant/pzx-web-api/status.svg)](https://drone.bearcatlog.com/Bryant/pzx-web-api)
|
||||
|
||||
pzx 专属的 web api 服务
|
||||
|
||||
|
@ -9,9 +9,9 @@ auth = APIBlueprint('auth', __name__)
|
||||
@auth.post('/wechat_login')
|
||||
@auth.input(WechatLoginIn)
|
||||
@auth.output(WechatLoginOut)
|
||||
def wechat_login(data):
|
||||
def wechat_login(json_data):
|
||||
try:
|
||||
result = rpc.admin.wechat_login(data['code'])
|
||||
result = rpc.admin.wechat_login(json_data['code'])
|
||||
except Exception as e:
|
||||
raise e
|
||||
return result
|
||||
@ -20,6 +20,6 @@ def wechat_login(data):
|
||||
@auth.get('/refresh_token')
|
||||
@auth.input(RefreshTokenIn, location='query')
|
||||
@auth.output(RefreshTokenOut)
|
||||
def refresh_token(data):
|
||||
result = rpc.admin.refresh_token(data['refresh_token'])
|
||||
def refresh_token(query_data):
|
||||
result = rpc.admin.refresh_token(query_data['refresh_token'])
|
||||
return result
|
Loading…
Reference in New Issue
Block a user