Update 20210528 - mit LoginPopup
This commit is contained in:
@@ -20,6 +20,7 @@ namespace sf1
|
||||
{
|
||||
public class Startup
|
||||
{
|
||||
|
||||
public Startup(IConfiguration configuration)
|
||||
{
|
||||
Configuration = configuration;
|
||||
@@ -35,12 +36,23 @@ namespace sf1
|
||||
{
|
||||
options.SerializerSettings.ContractResolver = new DefaultContractResolver();
|
||||
});
|
||||
services.AddDistributedMemoryCache();
|
||||
services.AddSession(options =>
|
||||
{
|
||||
options.IdleTimeout= TimeSpan.FromSeconds(60);
|
||||
options.Cookie.Name = ".bwpm.Session";
|
||||
options.Cookie.IsEssential = true;
|
||||
});
|
||||
|
||||
APP.Models.SessionClass.SetSessionValue();
|
||||
|
||||
|
||||
}
|
||||
|
||||
// This method gets called by the runtime. Use this method to configure the HTTP request pipeline.
|
||||
public void Configure(IApplicationBuilder app, IWebHostEnvironment env)
|
||||
{
|
||||
|
||||
if (env.IsDevelopment())
|
||||
{
|
||||
app.UseDeveloperExceptionPage();
|
||||
@@ -57,7 +69,8 @@ namespace sf1
|
||||
app.UseRouting();
|
||||
|
||||
app.UseAuthorization();
|
||||
|
||||
app.UseSession();
|
||||
|
||||
app.UseEndpoints(endpoints =>
|
||||
{
|
||||
endpoints.MapControllerRoute(
|
||||
|
||||
Reference in New Issue
Block a user