diff --git a/GPW.CORE.Api/Program.cs b/GPW.CORE.Api/Program.cs index 6cb825a..1c7e797 100644 --- a/GPW.CORE.Api/Program.cs +++ b/GPW.CORE.Api/Program.cs @@ -1,9 +1,11 @@ using GPW.CORE.Api.Data; using GPW.CORE.Data; using Microsoft.AspNetCore.Identity.UI.Services; +using Microsoft.AspNetCore.Localization; using StackExchange.Redis; using StackExchange.Redis.Extensions.Core.Configuration; using StackExchange.Redis.Extensions.Newtonsoft; +using System.Globalization; using System.Text.Json.Serialization; var builder = WebApplication.CreateBuilder(args); @@ -69,6 +71,19 @@ if (app.Environment.IsDevelopment()) app.UseSwaggerUI(); } +// cultura IT... +var supportedCultures = new[]{ + new CultureInfo("it-IT") + }; +app.UseRequestLocalization(new RequestLocalizationOptions +{ + DefaultRequestCulture = new RequestCulture("it-IT"), + SupportedCultures = supportedCultures, + FallBackToParentCultures = false +}); +CultureInfo.DefaultThreadCurrentCulture = CultureInfo.CreateSpecificCulture("it-IT"); + + app.UseHttpsRedirection(); app.UseAuthorization(); diff --git a/GPW.CORE.WRKLOG/Program.cs b/GPW.CORE.WRKLOG/Program.cs index fa5f246..a2b1765 100644 --- a/GPW.CORE.WRKLOG/Program.cs +++ b/GPW.CORE.WRKLOG/Program.cs @@ -4,7 +4,9 @@ using Microsoft.AspNetCore.Authentication.Negotiate; using Microsoft.AspNetCore.Components; using Microsoft.AspNetCore.Components.Web; using Microsoft.AspNetCore.Identity.UI.Services; +using Microsoft.AspNetCore.Localization; using StackExchange.Redis; +using System.Globalization; var builder = WebApplication.CreateBuilder(args); @@ -63,6 +65,20 @@ if (!app.Environment.IsDevelopment()) app.UseHsts(); } + +// cultura IT... +var supportedCultures = new[]{ + new CultureInfo("it-IT") + }; +app.UseRequestLocalization(new RequestLocalizationOptions +{ + DefaultRequestCulture = new RequestCulture("it-IT"), + SupportedCultures = supportedCultures, + FallBackToParentCultures = false +}); +CultureInfo.DefaultThreadCurrentCulture = CultureInfo.CreateSpecificCulture("it-IT"); + + app.UseHttpsRedirection(); app.UseStaticFiles(); diff --git a/Resources/manifest.xml b/Resources/manifest.xml index 59c05d1..97a4a75 100644 --- a/Resources/manifest.xml +++ b/Resources/manifest.xml @@ -1,7 +1,7 @@ 3.0.2301.2518 - http://nexus.steamware.net/repository/SWS/GPW/stable/GPW.Smart.zip + http://nexus.steamware.net/repository/SWS/GPW/stable/GPW.UI.zip http://nexus.steamware.net/repository/SWS/GPW/stable/ChangeLog.html false