1
0
mirror of https://github.com/RaidMax/IW4M-Admin.git synced 2025-06-10 15:20:48 -05:00

re-enable login to webfront with password

update cookie to last 3 months
add configuration option to limit # of rss feed items
prevent database tracking of bots if ignore bots requested
add last map and last server played to profile
This commit is contained in:
RaidMax
2019-02-22 19:06:51 -06:00
parent 5755775b85
commit 88c013be20
15 changed files with 864 additions and 27 deletions

View File

@ -4,6 +4,7 @@ using SharedLibraryCore.Database.Models;
using SharedLibraryCore.Interfaces;
using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.IO;
using System.Linq;
using System.Reflection;
@ -22,7 +23,7 @@ namespace SharedLibraryCore.Database
static string _ConnectionString;
static string _provider;
private static readonly string _migrationPluginDirectory = @"X:\IW4MAdmin\BUILD\Plugins\";
private static readonly string _migrationPluginDirectory = @"X:\IW4MAdmin\BUILD\Plugins";
public DatabaseContext(DbContextOptions<DatabaseContext> opt) : base(opt) { }
@ -123,6 +124,11 @@ namespace SharedLibraryCore.Database
ent.HasIndex(a => a.Name);
});
modelBuilder.Entity<EFMeta>(ent =>
{
ent.HasIndex(_meta => _meta.Key);
});
// force full name for database conversion
modelBuilder.Entity<EFClient>().ToTable("EFClients");
modelBuilder.Entity<EFAlias>().ToTable("EFAlias");
@ -138,7 +144,6 @@ namespace SharedLibraryCore.Database
#endif
IEnumerable<string> directoryFiles = Directory.GetFiles(pluginDir).Where(f => f.EndsWith(".dll"));
foreach (string dllPath in directoryFiles)
{
Assembly library;