update
This commit is contained in:
parent
8da308aade
commit
bafd5eb5ac
2
xumu.py
2
xumu.py
|
@ -36,7 +36,7 @@ class DataQuery(BaseModel):
|
||||||
async def data_query(params: DataQuery):
|
async def data_query(params: DataQuery):
|
||||||
try:
|
try:
|
||||||
deviceId = params.deviceId
|
deviceId = params.deviceId
|
||||||
if deviceId == None or deviceId == "":
|
if deviceId is None or deviceId == "" or len(deviceId) != 4:
|
||||||
return BaseResponse(code=500, msg="参数错误")
|
return BaseResponse(code=500, msg="参数错误")
|
||||||
sql = f"select last * from root.farm.{deviceId}"
|
sql = f"select last * from root.farm.{deviceId}"
|
||||||
send_json = {
|
send_json = {
|
||||||
|
|
Loading…
Reference in New Issue