Bot Event

This commit is contained in:
2022-07-30 18:22:49 +02:00
parent bfcca7132c
commit c0d469eac6
18 changed files with 2884 additions and 190 deletions

View File

@@ -1,6 +1,6 @@
using LaDOSE.Entity.Challonge;
using LaDOSE.Entity.Wordpress;
using LaDOSE.Entity.BotEvent;
using Microsoft.EntityFrameworkCore;
namespace LaDOSE.Entity.Context
@@ -32,6 +32,10 @@ namespace LaDOSE.Entity.Context
public DbSet<ChallongeParticipent> ChallongeParticipent { get; set; }
public DbSet<ChallongeTournament> ChallongeTournament { get; set; }
#region BotEvents
public DbSet<BotEvent.BotEvent> BotEvent { get; set; }
public DbSet<BotEventResult> BotEventResult { get; set; }
#endregion
public LaDOSEDbContext(DbContextOptions options) : base(options)
{
}
@@ -69,7 +73,12 @@ namespace LaDOSE.Entity.Context
.HasOne(e => e.Tournament)
.WithMany(e => e.Results)
.HasForeignKey(pt => pt.TournamentId);
modelBuilder.Entity<BotEventResult>()
.HasOne(e => e.BotEvent)
.WithMany(e => e.Results)
.HasForeignKey(pt => pt.BotEventId);
//modelBuilder.Entity<Set>()