feat: 完成bbs头像功能
This commit is contained in:
@@ -4,6 +4,7 @@ using System.Net;
|
||||
using Mapster;
|
||||
using SqlSugar;
|
||||
using Volo.Abp.Auditing;
|
||||
using Volo.Abp.DependencyInjection;
|
||||
using Volo.Abp.Domain.Entities;
|
||||
using Volo.Abp.Domain.Repositories;
|
||||
using Yi.AuditLogging.SqlSugarCore.Entities;
|
||||
|
||||
@@ -1,4 +1,7 @@
|
||||
using Volo.Abp.AuditLogging;
|
||||
using Microsoft.Extensions.DependencyInjection;
|
||||
using Microsoft.Extensions.DependencyInjection.Extensions;
|
||||
using Volo.Abp.AuditLogging;
|
||||
using Volo.Abp.AuditLogging.EntityFrameworkCore;
|
||||
using Volo.Abp.Modularity;
|
||||
using Yi.Framework.SqlSugarCore;
|
||||
|
||||
@@ -10,7 +13,9 @@ namespace Yi.AuditLogging.SqlSugarCore
|
||||
{
|
||||
public override void ConfigureServices(ServiceConfigurationContext context)
|
||||
{
|
||||
context.Services.Replace(new ServiceDescriptor(typeof(IAuditLogRepository), typeof(SqlSugarCoreAuditLogRepository), lifetime: ServiceLifetime.Transient));
|
||||
context.Services.AddYiDbContext<YiAuditLoggingDbContext>();
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -18,5 +18,13 @@ namespace Yi.Framework.Bbs.Application.Services
|
||||
{
|
||||
return Task.FromResult("你好世界");
|
||||
}
|
||||
|
||||
|
||||
public List<string> GetIcon()
|
||||
{
|
||||
|
||||
return Directory.GetFiles("wwwroot/icon").Select(x => "wwwroot/icon/"+ Path.GetFileName(x)).ToList();
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -21,13 +21,11 @@ namespace Yi.Framework.Rbac.Application.Services
|
||||
public class FileService : ApplicationService, IFileService
|
||||
{
|
||||
private readonly IRepository<FileAggregateRoot> _repository;
|
||||
private readonly HttpContext _httpContext;
|
||||
private IGuidGenerator _guidGenerator;
|
||||
public FileService(IRepository<FileAggregateRoot> repository, IHttpContextAccessor httpContextAccessor, IGuidGenerator guidGenerator)
|
||||
public FileService(IRepository<FileAggregateRoot> repository, IGuidGenerator guidGenerator)
|
||||
{
|
||||
_guidGenerator = guidGenerator;
|
||||
_repository = repository;
|
||||
_httpContext = httpContextAccessor.HttpContext;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
||||
Reference in New Issue
Block a user