Commit 89572c24 by tinywell

工具接口返回数据泛型修正

parent fd78ff71
...@@ -104,7 +104,7 @@ class RateClient(BaseHttpClient): ...@@ -104,7 +104,7 @@ class RateClient(BaseHttpClient):
'endDate': endDate 'endDate': endDate
} }
) )
return BaseResponse[Dict](**data) return BaseResponse[List](**data)
def query_rates_ranking_sync(self, rank_type: int) -> BaseResponse[Dict]: def query_rates_ranking_sync(self, rank_type: int) -> BaseResponse[Dict]:
"""同步查询在线率排名信息""" """同步查询在线率排名信息"""
...@@ -113,7 +113,7 @@ class RateClient(BaseHttpClient): ...@@ -113,7 +113,7 @@ class RateClient(BaseHttpClient):
const_url_rate_ranking, const_url_rate_ranking,
json={'type': rank_type} json={'type': rank_type}
) )
return BaseResponse[Dict](**data) return BaseResponse[List](**data)
async def query_rates_ranking(self, rank_type: int) -> BaseResponse[Dict]: async def query_rates_ranking(self, rank_type: int) -> BaseResponse[Dict]:
"""异步查询在线率排名信息""" """异步查询在线率排名信息"""
...@@ -122,7 +122,7 @@ class RateClient(BaseHttpClient): ...@@ -122,7 +122,7 @@ class RateClient(BaseHttpClient):
const_url_rate_ranking, const_url_rate_ranking,
json={'type': rank_type} json={'type': rank_type}
) )
return BaseResponse[Dict](**data) return BaseResponse[List](**data)
# 使用示例 # 使用示例
async def example_async_usage(): async def example_async_usage():
......
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