Browse Source

时间

bjmzak
wxd 2 years ago
parent
commit
b9cfade714
  1. 1
      src/Shentun.Peis.Application/Shentun.Peis.Application.csproj
  2. 12
      src/Shentun.Peis.HttpApi.Host/PeisHttpApiHostModule.cs

1
src/Shentun.Peis.Application/Shentun.Peis.Application.csproj

@ -22,7 +22,6 @@
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<PackageReference Include="Aliyun.OSS.SDK.NetCore" Version="2.13.0" />
<PackageReference Include="Microsoft.AspNetCore.Mvc.Core" Version="2.1.0" /> <PackageReference Include="Microsoft.AspNetCore.Mvc.Core" Version="2.1.0" />
<PackageReference Include="System.DirectoryServices" Version="8.0.0" /> <PackageReference Include="System.DirectoryServices" Version="8.0.0" />
<PackageReference Include="System.IO.FileSystem" Version="4.3.0" /> <PackageReference Include="System.IO.FileSystem" Version="4.3.0" />

12
src/Shentun.Peis.HttpApi.Host/PeisHttpApiHostModule.cs

@ -191,12 +191,12 @@ public class PeisHttpApiHostModule : AbpModule
// options.JsonSerializerOptions.Encoder = JavaScriptEncoder.Create(UnicodeRanges.All); // options.JsonSerializerOptions.Encoder = JavaScriptEncoder.Create(UnicodeRanges.All);
// options.JsonSerializerOptions.PropertyNamingPolicy = null; // options.JsonSerializerOptions.PropertyNamingPolicy = null;
//}); //});
Configure<JsonOptions>(x =>
{
x.JsonSerializerOptions.Encoder = JavaScriptEncoder.Create(UnicodeRanges.All);
x.JsonSerializerOptions.PropertyNamingPolicy = null;
x.JsonSerializerOptions.Converters.Add(new JsonTimeSpanConverter());
});
//Configure<JsonOptions>(x =>
//{
// x.JsonSerializerOptions.Encoder = JavaScriptEncoder.Create(UnicodeRanges.All);
// //x.JsonSerializerOptions.PropertyNamingPolicy = null;
// x.JsonSerializerOptions.Converters.Add(new JsonTimeSpanConverter());
//});
Configure<AbpJsonOptions>(x => Configure<AbpJsonOptions>(x =>
{ {

Loading…
Cancel
Save