ApiSystem: System.Text.Json
This commit is contained in:
parent
5988855b61
commit
feba6bb1c0
@ -82,7 +82,7 @@ namespace ASC.ApiSystem.Controllers
|
||||
SettingsManager settingsManager,
|
||||
ApiSystemHelper apiSystemHelper,
|
||||
CommonMethods commonMethods,
|
||||
HostedSolution hostedSolution,
|
||||
IOptionsSnapshot<HostedSolution> hostedSolutionOptions,
|
||||
CoreSettings coreSettings,
|
||||
TenantDomainValidator tenantDomainValidator,
|
||||
UserFormatter userFormatter,
|
||||
@ -98,7 +98,7 @@ namespace ASC.ApiSystem.Controllers
|
||||
SettingsManager = settingsManager;
|
||||
ApiSystemHelper = apiSystemHelper;
|
||||
CommonMethods = commonMethods;
|
||||
HostedSolution = hostedSolution;
|
||||
HostedSolution = hostedSolutionOptions.Value;
|
||||
CoreSettings = coreSettings;
|
||||
TenantDomainValidator = tenantDomainValidator;
|
||||
UserFormatter = userFormatter;
|
||||
|
@ -50,12 +50,12 @@ namespace ASC.ApiSystem.Controllers
|
||||
private ILog Log { get; }
|
||||
public TariffController(
|
||||
CommonMethods commonMethods,
|
||||
HostedSolution hostedSolution,
|
||||
IOptionsSnapshot<HostedSolution> hostedSolutionOptions,
|
||||
IOptionsMonitor<ILog> option
|
||||
)
|
||||
{
|
||||
CommonMethods = commonMethods;
|
||||
HostedSolution = hostedSolution;
|
||||
HostedSolution = hostedSolutionOptions.Value;
|
||||
Log = option.Get("ASC.ApiSystem");
|
||||
}
|
||||
|
||||
|
@ -59,8 +59,12 @@ namespace ASC.ApiSystem
|
||||
|
||||
services.AddHttpContextAccessor();
|
||||
|
||||
services.AddControllers()
|
||||
.AddNewtonsoftJson();
|
||||
services.AddControllers()
|
||||
.AddJsonOptions(options =>
|
||||
{
|
||||
options.JsonSerializerOptions.WriteIndented = false;
|
||||
options.JsonSerializerOptions.IgnoreNullValues = true;
|
||||
});
|
||||
|
||||
services.AddMemoryCache();
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user