mirror of
https://github.com/csunny/DB-GPT.git
synced 2025-08-19 16:57:21 +00:00
fix(readme): discord id change
discord id change
This commit is contained in:
parent
c689a63a73
commit
de3bcd1f68
@ -28,6 +28,7 @@ from pilot.openapi.editor_view_model import (
|
||||
ChartDetail,
|
||||
ChatChartEditContext,
|
||||
ChatSqlEditContext,
|
||||
DbTable
|
||||
)
|
||||
|
||||
from pilot.scene.chat_dashboard.data_preparation.report_schma import ChartData
|
||||
@ -40,6 +41,13 @@ CHAT_FACTORY = ChatFactory()
|
||||
logger = build_logger("api_editor_v1", LOGDIR + "api_editor_v1.log")
|
||||
|
||||
|
||||
@router.get("/v1/editor/db/tables", response_model=Result[DbTable])
|
||||
async def get_editor_tables(db_name: str, page_index: int, page_size: int, search_str: str= ""):
|
||||
return Result.succ(None)
|
||||
|
||||
|
||||
|
||||
|
||||
@router.get("/v1/editor/sql/rounds", response_model=Result[ChatDbRounds])
|
||||
async def get_editor_sql_rounds(con_uid: str):
|
||||
return Result.succ(None)
|
||||
|
@ -2,6 +2,19 @@ from pydantic import BaseModel, Field
|
||||
from typing import TypeVar, Union, List, Generic, Any
|
||||
|
||||
|
||||
class DbField(BaseModel):
|
||||
colunm_name: str
|
||||
type: str
|
||||
colunm_len: str
|
||||
can_null: bool = True
|
||||
default_value: str = ""
|
||||
comment: str = ""
|
||||
|
||||
class DbTable(BaseModel):
|
||||
table_name: str
|
||||
comment: str
|
||||
colunm: List[DbField]
|
||||
|
||||
class ChatDbRounds(BaseModel):
|
||||
round: int
|
||||
db_name: str
|
||||
|
@ -70,13 +70,13 @@ app.add_middleware(
|
||||
)
|
||||
|
||||
|
||||
# app.include_router(api_v1, prefix="/api")
|
||||
# app.include_router(knowledge_router, prefix="/api")
|
||||
# app.include_router(api_editor_route_v1, prefix="/api")
|
||||
app.include_router(api_v1, prefix="/api")
|
||||
app.include_router(knowledge_router, prefix="/api")
|
||||
app.include_router(api_editor_route_v1, prefix="/api")
|
||||
|
||||
app.include_router(api_v1)
|
||||
app.include_router(knowledge_router)
|
||||
app.include_router(api_editor_route_v1)
|
||||
# app.include_router(api_v1)
|
||||
# app.include_router(knowledge_router)
|
||||
# app.include_router(api_editor_route_v1)
|
||||
|
||||
app.mount("/_next/static", StaticFiles(directory=static_file_path + "/_next/static"))
|
||||
app.mount("/", StaticFiles(directory=static_file_path, html=True), name="static")
|
||||
|
Loading…
Reference in New Issue
Block a user