1.优化用户查询功能(查询没有数据后报错的问题)
This commit is contained in:
parent
cc48dada37
commit
900c03d276
@ -2069,6 +2069,8 @@ async def user_property_model(
|
||||
df = await ckdb.query_dataframe(sql)
|
||||
except Exception as e:
|
||||
return schemas.Msg(code=0, msg='查询参数不匹配', data=e)
|
||||
if df.empty:
|
||||
return schemas.Msg(code=-9, msg='查无数据')
|
||||
# 转换成列表返回
|
||||
df.fillna(0, inplace=True)
|
||||
account_id = list(df['#account_id'])
|
||||
|
Loading…
Reference in New Issue
Block a user