Browse Source
Merge pull request #450 from colinin/5.0.0
fix(configuration): use context.Services.GetConfiguration()
pull/474/head
yx lin
4 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
8 changed files with
10 additions and
10 deletions
-
apps/vue/src/views/oss-management/objects/hooks/useObjects.ts
-
aspnet-core/modules/oss-management/LINGYUN.Abp.OssManagement.FileSystem/LINGYUN/Abp/OssManagement/FileSystem/FileSystemOssContainer.cs
-
aspnet-core/services/LY.MicroService.BackendAdmin.HttpApi.Host/BackendAdminHttpApiHostModule.cs
-
aspnet-core/services/LY.MicroService.PlatformManagement.HttpApi.Host/PlatformManagementHttpApiHostModule.cs
-
aspnet-core/services/LY.MicroService.PlatformManagement.HttpApi.Host/Properties/launchSettings.json
-
aspnet-core/services/LY.MicroService.RealtimeMessage.HttpApi.Host/RealtimeMessageHttpApiHostModule.cs
-
aspnet-core/services/LY.MicroService.identityServer.HttpApi.Host/IdentityServerHttpApiHostModule.cs
-
aspnet-core/services/LY.MicroService.identityServer/IdentityServerModule.cs
|
|
|
@ -28,7 +28,7 @@ export function useObjects() { |
|
|
|
marker: '', |
|
|
|
sorting: '', |
|
|
|
skipCount: 0, |
|
|
|
maxResultCount: 100, |
|
|
|
maxResultCount: 1000, |
|
|
|
}).then((res) => { |
|
|
|
containers.value = res.containers; |
|
|
|
}); |
|
|
|
@ -58,7 +58,7 @@ export function useObjects() { |
|
|
|
encodingType: '', |
|
|
|
sorting: '', |
|
|
|
skipCount: 0, |
|
|
|
maxResultCount: 100, |
|
|
|
maxResultCount: 1000, |
|
|
|
}).then((res) => { |
|
|
|
const fs = res.objects |
|
|
|
.filter((item) => item.isFolder) |
|
|
|
|
|
|
|
@ -394,8 +394,9 @@ namespace LINGYUN.Abp.OssManagement.FileSystem |
|
|
|
} |
|
|
|
DirectoryHelper.CreateIfNotExists(filePath); |
|
|
|
// 目录也属于Oss对象,需要抽象的文件系统集合来存储
|
|
|
|
var fileSystemNames = Directory.GetFileSystemEntries(filePath); |
|
|
|
int maxFilesCount = fileSystemNames.Length; |
|
|
|
var fileSystemNames = string.Equals(request.Delimiter, "/") |
|
|
|
? Directory.GetDirectories(filePath) |
|
|
|
: Directory.GetFileSystemEntries(filePath); |
|
|
|
|
|
|
|
// 排序所有文件与目录
|
|
|
|
Array.Sort(fileSystemNames, delegate (string x, string y) |
|
|
|
|
|
|
|
@ -91,7 +91,6 @@ public partial class BackendAdminHttpApiHostModule : AbpModule |
|
|
|
|
|
|
|
public override void ConfigureServices(ServiceConfigurationContext context) |
|
|
|
{ |
|
|
|
context.Services.AddAlwaysAllowAuthorization(); |
|
|
|
var hostingEnvironment = context.Services.GetHostingEnvironment(); |
|
|
|
var configuration = context.Services.GetConfiguration(); |
|
|
|
|
|
|
|
|
|
|
|
@ -89,7 +89,7 @@ public partial class PlatformManagementHttpApiHostModule : AbpModule |
|
|
|
public override void ConfigureServices(ServiceConfigurationContext context) |
|
|
|
{ |
|
|
|
var hostingEnvironment = context.Services.GetHostingEnvironment(); |
|
|
|
var configuration = hostingEnvironment.BuildConfiguration(); |
|
|
|
var configuration = context.Services.GetConfiguration(); |
|
|
|
|
|
|
|
ConfigureDbContext(); |
|
|
|
ConfigureJsonSerializer(); |
|
|
|
|
|
|
|
@ -11,7 +11,7 @@ |
|
|
|
"LY.MicroService.PlatformManagement.HttpApi.Host": { |
|
|
|
"commandName": "Project", |
|
|
|
"dotnetRunMessages": true, |
|
|
|
"launchBrowser": true, |
|
|
|
"launchBrowser": false, |
|
|
|
"applicationUrl": "http://127.0.0.1:30025", |
|
|
|
"environmentVariables": { |
|
|
|
"ASPNETCORE_ENVIRONMENT": "Development" |
|
|
|
|
|
|
|
@ -85,7 +85,7 @@ namespace LY.MicroService.RealtimeMessage |
|
|
|
public override void ConfigureServices(ServiceConfigurationContext context) |
|
|
|
{ |
|
|
|
var hostingEnvironment = context.Services.GetHostingEnvironment(); |
|
|
|
var configuration = hostingEnvironment.BuildConfiguration(); |
|
|
|
var configuration = context.Services.GetConfiguration(); |
|
|
|
|
|
|
|
ConfigureDbContext(); |
|
|
|
ConfigureJsonSerializer(); |
|
|
|
|
|
|
|
@ -69,7 +69,7 @@ public partial class IdentityServerHttpApiHostModule : AbpModule |
|
|
|
public override void ConfigureServices(ServiceConfigurationContext context) |
|
|
|
{ |
|
|
|
var hostingEnvironment = context.Services.GetHostingEnvironment(); |
|
|
|
var configuration = hostingEnvironment.BuildConfiguration(); |
|
|
|
var configuration = context.Services.GetConfiguration(); |
|
|
|
|
|
|
|
ConfigureDbContext(); |
|
|
|
ConfigureJsonSerializer(); |
|
|
|
|
|
|
|
@ -83,7 +83,7 @@ public partial class IdentityServerModule : AbpModule |
|
|
|
public override void ConfigureServices(ServiceConfigurationContext context) |
|
|
|
{ |
|
|
|
var hostingEnvironment = context.Services.GetHostingEnvironment(); |
|
|
|
var configuration = hostingEnvironment.BuildConfiguration(); |
|
|
|
var configuration = context.Services.GetConfiguration(); |
|
|
|
|
|
|
|
ConfigureDbContext(); |
|
|
|
ConfigureJsonSerializer(); |
|
|
|
|