mirror of
https://github.com/langgenius/dify.git
synced 2026-04-26 02:06:35 +08:00
notion fix
This commit is contained in:
parent
05e96e56e5
commit
94a0fb6dc1
@ -226,9 +226,9 @@ class OnlineDocumentInfo(BaseModel):
|
|||||||
Online document info
|
Online document info
|
||||||
"""
|
"""
|
||||||
|
|
||||||
workspace_id: str = Field(..., description="The workspace id")
|
workspace_id: Optional[str] = Field(None, description="The workspace id")
|
||||||
workspace_name: str = Field(..., description="The workspace name")
|
workspace_name: Optional[str] = Field(None, description="The workspace name")
|
||||||
workspace_icon: str = Field(..., description="The workspace icon")
|
workspace_icon: Optional[str] = Field(None, description="The workspace icon")
|
||||||
total: int = Field(..., description="The total number of documents")
|
total: int = Field(..., description="The total number of documents")
|
||||||
pages: list[OnlineDocumentPage] = Field(..., description="The pages of the online document")
|
pages: list[OnlineDocumentPage] = Field(..., description="The pages of the online document")
|
||||||
|
|
||||||
|
|||||||
@ -107,10 +107,10 @@ class OnlineDocumentInfo(BaseModel):
|
|||||||
"""
|
"""
|
||||||
|
|
||||||
provider: str
|
provider: str
|
||||||
workspace_id: str
|
workspace_id: Optional[str] = None
|
||||||
page_id: str
|
page_id: str
|
||||||
page_type: str
|
page_type: str
|
||||||
icon: OnlineDocumentIcon
|
icon: Optional[OnlineDocumentIcon] = None
|
||||||
|
|
||||||
|
|
||||||
class WebsiteInfo(BaseModel):
|
class WebsiteInfo(BaseModel):
|
||||||
|
|||||||
@ -1370,7 +1370,7 @@ class DocumentService:
|
|||||||
)
|
)
|
||||||
return
|
return
|
||||||
db.session.add(dataset_process_rule)
|
db.session.add(dataset_process_rule)
|
||||||
db.session.commit()
|
db.session.flush()
|
||||||
lock_name = f"add_document_lock_dataset_id_{dataset.id}"
|
lock_name = f"add_document_lock_dataset_id_{dataset.id}"
|
||||||
with redis_client.lock(lock_name, timeout=600):
|
with redis_client.lock(lock_name, timeout=600):
|
||||||
position = DocumentService.get_documents_position(dataset.id)
|
position = DocumentService.get_documents_position(dataset.id)
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user