diff --git a/Tiobon.Core.Api/Controllers/FileController.cs b/Tiobon.Core.Api/Controllers/FileController.cs
index 358bd470..2edeb900 100644
--- a/Tiobon.Core.Api/Controllers/FileController.cs
+++ b/Tiobon.Core.Api/Controllers/FileController.cs
@@ -7,7 +7,7 @@ namespace Tiobon.Core.Controllers;
/// 文件服务
///
[Produces("application/json")]
-[Route("api/File"), ApiExplorerSettings(GroupName = Grouping.GroupName_Ghre)]
+[Route("api/File"), ApiExplorerSettings(GroupName = Grouping.GroupName_System)]
public class FileController : BaseApiController
{
public ITiobonArticleServices _TiobonArticleServices { get; set; }
@@ -91,6 +91,11 @@ public class FileController : BaseApiController
#region 获取图片
+ ///
+ /// 获取图片
+ ///
+ /// 主键ID
+ ///
[HttpGet("Download/{Id}"), AllowAnonymous]
public async Task Download(long Id)
{
@@ -98,8 +103,7 @@ public class FileController : BaseApiController
{
var webRootPath = _hostingEnvironment.WebRootPath;
- using var _context = ContextFactory.CreateContext();
- //var file = await _context.Ghre_Attachment.Where(o => o.Id == Id).FirstOrDefaultAsync();
+ using var _context = ContextFactory.CreateContext();
var file = await _ghre_AttachmentServices.QueryById(Id);
if (file == null)
return Ok("找不到文件");