From bd00d3d0b8cf4969a96e9df4d2d73b420af9f623 Mon Sep 17 00:00:00 2001 From: liguoyang Date: Fri, 23 Feb 2024 21:43:09 +0800 Subject: [PATCH] =?UTF-8?q?fix=20=E6=9B=B4=E6=96=B0=E9=9B=AA=E8=8A=B1id?= =?UTF-8?q?=E6=95=B0=E6=8D=AE=E8=8A=82=E7=82=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Src/Dlhis.Canteen/Program.cs | 8 ++++++++ Src/Dlhis.Entity/Dlhis.Entity.csproj | 2 +- Src/Dlhis.ScheduledTask/Dlhis.ScheduledTask.csproj | 2 +- Src/Dlhis.ScheduledTask/Program.cs | 6 ++++++ 4 files changed, 16 insertions(+), 2 deletions(-) diff --git a/Src/Dlhis.Canteen/Program.cs b/Src/Dlhis.Canteen/Program.cs index d64882de..1a52e899 100644 --- a/Src/Dlhis.Canteen/Program.cs +++ b/Src/Dlhis.Canteen/Program.cs @@ -1,4 +1,5 @@ using Kurisu.AspNetCore.Startup; +using Kurisu.AspNetCore.Utils.Extensions; using Kurisu.Startup; using Microsoft.IdentityModel.Logging; @@ -18,4 +19,11 @@ public class Startup : DefaultStartup { IdentityModelEventSource.ShowPII = true; } + + public override void ConfigureServices(IServiceCollection services) + { + base.ConfigureServices(services); + + services.AddRedis(); + } } \ No newline at end of file diff --git a/Src/Dlhis.Entity/Dlhis.Entity.csproj b/Src/Dlhis.Entity/Dlhis.Entity.csproj index 8245cd0d..6aee2f83 100644 --- a/Src/Dlhis.Entity/Dlhis.Entity.csproj +++ b/Src/Dlhis.Entity/Dlhis.Entity.csproj @@ -11,7 +11,7 @@ - + diff --git a/Src/Dlhis.ScheduledTask/Dlhis.ScheduledTask.csproj b/Src/Dlhis.ScheduledTask/Dlhis.ScheduledTask.csproj index 74406a5b..03b573b7 100644 --- a/Src/Dlhis.ScheduledTask/Dlhis.ScheduledTask.csproj +++ b/Src/Dlhis.ScheduledTask/Dlhis.ScheduledTask.csproj @@ -20,7 +20,7 @@ - + diff --git a/Src/Dlhis.ScheduledTask/Program.cs b/Src/Dlhis.ScheduledTask/Program.cs index 4c81132c..fa11b1b8 100644 --- a/Src/Dlhis.ScheduledTask/Program.cs +++ b/Src/Dlhis.ScheduledTask/Program.cs @@ -29,4 +29,10 @@ public class Startup : DefaultStartup .SetApplicationName("scheduled") .PersistKeysToStackExchangeRedis(redis, "DataProtection-Keys"); } + + public override void Configure(IApplicationBuilder app, IWebHostEnvironment env) + { + base.Configure(app, env); + app.UseSnowFlakeInit(); + } } \ No newline at end of file