Browse Source
Merge pull request #401 from colinin/4.4.2
fix(json): 统一DateTime序列化格式
pull/404/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
48 additions and
0 deletions
-
aspnet-core/services/account/AuthServer.Host/AuthIdentityServerModule.Configure.cs
-
aspnet-core/services/admin/LINGYUN.Abp.BackendAdmin.HttpApi.Host/BackendAdminHostModule.Configure.cs
-
aspnet-core/services/apigateway/LINGYUN.ApiGateway.Host/ApiGatewayHostModule.Configure.cs
-
aspnet-core/services/apigateway/LINGYUN.ApiGateway.HttpApi.Host/ApiGatewayHttpApiHostModule.Configure.cs
-
aspnet-core/services/identity-server/LINGYUN.Abp.IdentityServer4.HttpApi.Host/AbpIdentityServerAdminHttpApiHostModule.Configure.cs
-
aspnet-core/services/localization/LINGYUN.Abp.LocalizationManagement.HttpApi.Host/AbpLocalizationManagementHttpApiHostModule.Configure.cs
-
aspnet-core/services/messages/LINGYUN.Abp.MessageService.HttpApi.Host/AbpMessageServiceHttpApiHostModule.Configure.cs
-
aspnet-core/services/platform/LINGYUN.Platform.HttpApi.Host/AppPlatformHttpApiHostModule.Configure.cs
|
|
|
@ -22,6 +22,7 @@ using Volo.Abp.Auditing; |
|
|
|
using Volo.Abp.Caching; |
|
|
|
using Volo.Abp.EntityFrameworkCore; |
|
|
|
using Volo.Abp.IdentityServer; |
|
|
|
using Volo.Abp.Json; |
|
|
|
using Volo.Abp.Json.SystemTextJson; |
|
|
|
using Volo.Abp.Localization; |
|
|
|
using Volo.Abp.MultiTenancy; |
|
|
|
@ -98,6 +99,11 @@ namespace AuthServer.Host |
|
|
|
|
|
|
|
private void ConfigureJsonSerializer() |
|
|
|
{ |
|
|
|
// 统一时间日期格式
|
|
|
|
Configure<AbpJsonOptions>(options => |
|
|
|
{ |
|
|
|
options.DefaultDateTimeFormat = "yyyy-MM-dd HH:mm:ss"; |
|
|
|
}); |
|
|
|
// 中文序列化的编码问题
|
|
|
|
Configure<AbpSystemTextJsonSerializerOptions>(options => |
|
|
|
{ |
|
|
|
|
|
|
|
@ -19,6 +19,7 @@ using Volo.Abp.Caching; |
|
|
|
using Volo.Abp.Domain.Entities.Events.Distributed; |
|
|
|
using Volo.Abp.EntityFrameworkCore; |
|
|
|
using Volo.Abp.Identity.Localization; |
|
|
|
using Volo.Abp.Json; |
|
|
|
using Volo.Abp.Json.SystemTextJson; |
|
|
|
using Volo.Abp.Localization; |
|
|
|
using Volo.Abp.MultiTenancy; |
|
|
|
@ -62,6 +63,11 @@ namespace LINGYUN.Abp.BackendAdmin |
|
|
|
|
|
|
|
private void ConfigureJsonSerializer() |
|
|
|
{ |
|
|
|
// 统一时间日期格式
|
|
|
|
Configure<AbpJsonOptions>(options => |
|
|
|
{ |
|
|
|
options.DefaultDateTimeFormat = "yyyy-MM-dd HH:mm:ss"; |
|
|
|
}); |
|
|
|
// 中文序列化的编码问题
|
|
|
|
Configure<AbpSystemTextJsonSerializerOptions>(options => |
|
|
|
{ |
|
|
|
|
|
|
|
@ -21,6 +21,7 @@ using System.Text.Encodings.Web; |
|
|
|
using System.Text.Unicode; |
|
|
|
using Volo.Abp.AutoMapper; |
|
|
|
using Volo.Abp.Caching; |
|
|
|
using Volo.Abp.Json; |
|
|
|
using Volo.Abp.Json.SystemTextJson; |
|
|
|
using Volo.Abp.Localization; |
|
|
|
using Volo.Abp.VirtualFileSystem; |
|
|
|
@ -95,6 +96,11 @@ namespace LINGYUN.ApiGateway |
|
|
|
|
|
|
|
private void ConfigureJsonSerializer() |
|
|
|
{ |
|
|
|
// 统一时间日期格式
|
|
|
|
Configure<AbpJsonOptions>(options => |
|
|
|
{ |
|
|
|
options.DefaultDateTimeFormat = "yyyy-MM-dd HH:mm:ss"; |
|
|
|
}); |
|
|
|
// 中文序列化的编码问题
|
|
|
|
Configure<AbpSystemTextJsonSerializerOptions>(options => |
|
|
|
{ |
|
|
|
|
|
|
|
@ -14,6 +14,7 @@ using Volo.Abp.Auditing; |
|
|
|
using Volo.Abp.AutoMapper; |
|
|
|
using Volo.Abp.Caching; |
|
|
|
using Volo.Abp.EntityFrameworkCore; |
|
|
|
using Volo.Abp.Json; |
|
|
|
using Volo.Abp.Json.SystemTextJson; |
|
|
|
using Volo.Abp.Localization; |
|
|
|
using Volo.Abp.MultiTenancy; |
|
|
|
@ -64,6 +65,11 @@ namespace LINGYUN.ApiGateway |
|
|
|
|
|
|
|
private void ConfigureJsonSerializer() |
|
|
|
{ |
|
|
|
// 统一时间日期格式
|
|
|
|
Configure<AbpJsonOptions>(options => |
|
|
|
{ |
|
|
|
options.DefaultDateTimeFormat = "yyyy-MM-dd HH:mm:ss"; |
|
|
|
}); |
|
|
|
// 中文序列化的编码问题
|
|
|
|
Configure<AbpSystemTextJsonSerializerOptions>(options => |
|
|
|
{ |
|
|
|
|
|
|
|
@ -20,6 +20,7 @@ using Volo.Abp.Caching; |
|
|
|
using Volo.Abp.Domain.Entities.Events.Distributed; |
|
|
|
using Volo.Abp.EntityFrameworkCore; |
|
|
|
using Volo.Abp.Identity.Localization; |
|
|
|
using Volo.Abp.Json; |
|
|
|
using Volo.Abp.Json.SystemTextJson; |
|
|
|
using Volo.Abp.Localization; |
|
|
|
using Volo.Abp.MultiTenancy; |
|
|
|
@ -71,6 +72,11 @@ namespace LINGYUN.Abp.IdentityServer4 |
|
|
|
|
|
|
|
private void ConfigureJsonSerializer() |
|
|
|
{ |
|
|
|
// 统一时间日期格式
|
|
|
|
Configure<AbpJsonOptions>(options => |
|
|
|
{ |
|
|
|
options.DefaultDateTimeFormat = "yyyy-MM-dd HH:mm:ss"; |
|
|
|
}); |
|
|
|
// 中文序列化的编码问题
|
|
|
|
Configure<AbpSystemTextJsonSerializerOptions>(options => |
|
|
|
{ |
|
|
|
|
|
|
|
@ -16,6 +16,7 @@ using Volo.Abp; |
|
|
|
using Volo.Abp.Auditing; |
|
|
|
using Volo.Abp.Caching; |
|
|
|
using Volo.Abp.EntityFrameworkCore; |
|
|
|
using Volo.Abp.Json; |
|
|
|
using Volo.Abp.Json.SystemTextJson; |
|
|
|
using Volo.Abp.Localization; |
|
|
|
using Volo.Abp.MultiTenancy; |
|
|
|
@ -59,6 +60,11 @@ namespace LINGYUN.Abp.LocalizationManagement |
|
|
|
|
|
|
|
private void ConfigureJsonSerializer() |
|
|
|
{ |
|
|
|
// 统一时间日期格式
|
|
|
|
Configure<AbpJsonOptions>(options => |
|
|
|
{ |
|
|
|
options.DefaultDateTimeFormat = "yyyy-MM-dd HH:mm:ss"; |
|
|
|
}); |
|
|
|
// 中文序列化的编码问题
|
|
|
|
Configure<AbpSystemTextJsonSerializerOptions>(options => |
|
|
|
{ |
|
|
|
|
|
|
|
@ -20,6 +20,7 @@ using Volo.Abp.AspNetCore.Auditing; |
|
|
|
using Volo.Abp.Auditing; |
|
|
|
using Volo.Abp.Caching; |
|
|
|
using Volo.Abp.EntityFrameworkCore; |
|
|
|
using Volo.Abp.Json; |
|
|
|
using Volo.Abp.Json.SystemTextJson; |
|
|
|
using Volo.Abp.Localization; |
|
|
|
using Volo.Abp.MultiTenancy; |
|
|
|
@ -62,6 +63,11 @@ namespace LINGYUN.Abp.MessageService |
|
|
|
|
|
|
|
private void ConfigureJsonSerializer() |
|
|
|
{ |
|
|
|
// 统一时间日期格式
|
|
|
|
Configure<AbpJsonOptions>(options => |
|
|
|
{ |
|
|
|
options.DefaultDateTimeFormat = "yyyy-MM-dd HH:mm:ss"; |
|
|
|
}); |
|
|
|
// 中文序列化的编码问题
|
|
|
|
Configure<AbpSystemTextJsonSerializerOptions>(options => |
|
|
|
{ |
|
|
|
|
|
|
|
@ -20,6 +20,7 @@ using Volo.Abp.BlobStoring; |
|
|
|
using Volo.Abp.BlobStoring.FileSystem; |
|
|
|
using Volo.Abp.Caching; |
|
|
|
using Volo.Abp.EntityFrameworkCore; |
|
|
|
using Volo.Abp.Json; |
|
|
|
using Volo.Abp.Json.SystemTextJson; |
|
|
|
using Volo.Abp.Localization; |
|
|
|
using Volo.Abp.MultiTenancy; |
|
|
|
@ -62,6 +63,11 @@ namespace LINGYUN.Platform |
|
|
|
|
|
|
|
private void ConfigureJsonSerializer() |
|
|
|
{ |
|
|
|
// 统一时间日期格式
|
|
|
|
Configure<AbpJsonOptions>(options => |
|
|
|
{ |
|
|
|
options.DefaultDateTimeFormat = "yyyy-MM-dd HH:mm:ss"; |
|
|
|
}); |
|
|
|
// 中文序列化的编码问题
|
|
|
|
Configure<AbpSystemTextJsonSerializerOptions>(options => |
|
|
|
{ |
|
|
|
|