This commit is contained in:
dataeaseShu
2025-07-25 11:19:44 +08:00
3 changed files with 3 additions and 1 deletions
+1
View File
@@ -85,6 +85,7 @@ def get_chat_with_records(session: SessionDep, chart_id: int, current_user: Curr
else:
chat_info.datasource_exists = True
chat_info.datasource_name = ds.name
chat_info.ds_type = ds.type
record_list = session.query(ChatRecord).options(
load_only(ChatRecord.id, ChatRecord.chat_id, ChatRecord.create_time, ChatRecord.finish_time,
+1
View File
@@ -89,6 +89,7 @@ class ChatInfo(BaseModel):
chat_type: str = "chat"
datasource: Optional[int] = None
engine_type: str = ''
ds_type: str = ''
datasource_name: str = ''
datasource_exists: bool = True
records: List[ChatRecord | dict] = []
+1 -1
View File
@@ -407,4 +407,4 @@ def filter_list(list_a, list_b):
def is_normal_user(current_user: CurrentUser):
return current_user.id != 1 and (current_user.weight is not None and current_user.weight != 1)
return current_user.id != 1