mirror of
https://github.com/csunny/DB-GPT.git
synced 2025-10-22 17:39:02 +00:00
fix: dashboard editor run error (#1380)
This commit is contained in:
11
dbgpt/util/date_utils.py
Normal file
11
dbgpt/util/date_utils.py
Normal file
@@ -0,0 +1,11 @@
|
||||
import datetime
|
||||
|
||||
|
||||
def is_datetime(value):
|
||||
return isinstance(value, datetime.datetime)
|
||||
|
||||
|
||||
def convert_datetime_in_row(row):
|
||||
return [value.strftime('%Y-%m-%d %H:%M:%S') if is_datetime(value)
|
||||
else value for value in row]
|
||||
|
Reference in New Issue
Block a user