update
This commit is contained in:
parent
56beae735b
commit
2d139a039f
7
api.py
7
api.py
|
@ -8,7 +8,8 @@ def add(data: LOT_DATA):
|
|||
add_kb_to_db(data)
|
||||
return BaseResponse()
|
||||
except Exception as e:
|
||||
return BaseResponse(code=500, msg=e)
|
||||
print(e)
|
||||
return BaseResponse(code=500, msg=str(e))
|
||||
|
||||
|
||||
def delete(start_time, end_time):
|
||||
|
@ -16,7 +17,7 @@ def delete(start_time, end_time):
|
|||
delete_kb_detail_by_time(start_time, end_time)
|
||||
return BaseResponse()
|
||||
except Exception as e:
|
||||
return BaseResponse(code=500, msg=e)
|
||||
return BaseResponse(code=500, msg=str(e))
|
||||
|
||||
|
||||
def get_data():
|
||||
|
@ -24,4 +25,4 @@ def get_data():
|
|||
data = get_kb_detail()
|
||||
return BaseResponse(data=data)
|
||||
except Exception as e:
|
||||
return BaseResponse(code=404, msg=e)
|
||||
return BaseResponse(code=404, msg=str(e))
|
||||
|
|
Loading…
Reference in New Issue