mirror of
https://github.com/infiniflow/ragflow.git
synced 2026-08-26 01:52:16 +08:00
feat: Implement file upload and folder creation features by GO (#13903)
### What problem does this PR solve? feat: Implement file upload and folder creation features - Add file upload route in router.go - Add file operation methods in dao/file.go - Add util/file.go for file type detection and filename handling - Implement file upload and folder creation endpoints in handler/file.go - Implement file upload and folder creation logic in service/file.go - Modify response message format in memory.go - Add document count method in dao/document.go ### Type of change - [x] New Feature (non-breaking change which adds functionality)
This commit is contained in:
@@ -189,6 +189,12 @@ func (r *Router) Setup(engine *gin.Engine) {
|
||||
// message.GET("", r.memoryHandler.GetMessages)
|
||||
// message.GET("/:memory_id/:message_id/content", r.memoryHandler.GetMessageContent)
|
||||
// }
|
||||
|
||||
file := v1.Group("/files")
|
||||
{
|
||||
file.POST("", r.fileHandler.UploadFile)
|
||||
}
|
||||
|
||||
// provider pool route group
|
||||
provider := v1.Group("/providers")
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user