|
@@ -184,6 +184,8 @@ async def v1(request: Request, background_tasks: BackgroundTasks, db: Session =
|
|
|
elif key !='page' and key != 'limit' and key !='create_time':
|
|
|
if isinstance(val, int):
|
|
|
val = str(val)
|
|
|
+ if isinstance(val, float):
|
|
|
+ val = str(val)
|
|
|
sql = sql.replace("{" + key + "}", val)
|
|
|
elif key =='create_time':
|
|
|
if val != '全部':
|
|
@@ -707,6 +709,8 @@ async def v2(serviceid:str,request: Request, db: Session = Depends(get_db)):
|
|
|
for (key, val) in body['query'].items():
|
|
|
if isinstance(val, int):
|
|
|
val = str(val)
|
|
|
+ if isinstance(val, float):
|
|
|
+ val = str(val)
|
|
|
if contains_special_characters(val):
|
|
|
return JSONResponse(status_code=411, content={
|
|
|
'code': 411,
|