feat: rbac完善,file接入完成

This commit is contained in:
Blizzard
2026-05-01 12:56:08 +08:00
parent bbd3f834b9
commit a93477ea8e
81 changed files with 5470 additions and 371 deletions
+37 -1
View File
@@ -21,12 +21,48 @@ func RegisterHandlers(server *rest.Server, serverCtx *svc.ServiceContext) {
Path: "/:id",
Handler: file.GetFileByIdHandler(serverCtx),
},
{
// 创建存储配置
Method: http.MethodPost,
Path: "/config/create",
Handler: file.CreateStorageConfigHandler(serverCtx),
},
{
// 删除存储配置
Method: http.MethodPost,
Path: "/config/delete",
Handler: file.DeleteStorageConfigHandler(serverCtx),
},
{
// 获取存储配置列表
Method: http.MethodPost,
Path: "/config/list",
Handler: file.GetStorageConfigListHandler(serverCtx),
},
{
// 设置默认存储配置
Method: http.MethodPost,
Path: "/config/setDefault",
Handler: file.SetDefaultStorageConfigHandler(serverCtx),
},
{
// 更新存储配置
Method: http.MethodPost,
Path: "/config/update",
Handler: file.UpdateStorageConfigHandler(serverCtx),
},
{
// 删除文件
Method: http.MethodDelete,
Method: http.MethodPost,
Path: "/delete",
Handler: file.DeleteFileHandler(serverCtx),
},
{
// 下载文件
Method: http.MethodGet,
Path: "/download/:id",
Handler: file.DownloadFileHandler(serverCtx),
},
{
// 文件列表
Method: http.MethodPost,