feat(bp): wire 4 new entities into DbContext + AddBattlePass migration
Adds DbSets and OnModelCreating config for BattlePassSeasonEntry, BattlePassRewardEntry, ViewerBattlePassProgressEntry, and ViewerBattlePassClaimEntry; generates migration 20260527021011_AddBattlePass with DDL-only CreateTable + CreateIndex calls and no InsertData. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -516,6 +516,87 @@ namespace SVSim.Database.Migrations
|
||||
b.ToTable("BattlePassLevels");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("SVSim.Database.Models.BattlePassRewardEntry", b =>
|
||||
{
|
||||
b.Property<long>("Id")
|
||||
.HasColumnType("bigint");
|
||||
|
||||
b.Property<DateTime>("DateCreated")
|
||||
.HasColumnType("timestamp with time zone");
|
||||
|
||||
b.Property<DateTime?>("DateUpdated")
|
||||
.HasColumnType("timestamp with time zone");
|
||||
|
||||
b.Property<bool>("IsAppealExclusion")
|
||||
.HasColumnType("boolean");
|
||||
|
||||
b.Property<int>("Level")
|
||||
.HasColumnType("integer");
|
||||
|
||||
b.Property<long>("RewardDetailId")
|
||||
.HasColumnType("bigint");
|
||||
|
||||
b.Property<int>("RewardNumber")
|
||||
.HasColumnType("integer");
|
||||
|
||||
b.Property<int>("RewardType")
|
||||
.HasColumnType("integer");
|
||||
|
||||
b.Property<int>("SeasonId")
|
||||
.HasColumnType("integer");
|
||||
|
||||
b.Property<int>("Track")
|
||||
.HasColumnType("integer");
|
||||
|
||||
b.HasKey("Id");
|
||||
|
||||
b.HasIndex("SeasonId", "Track", "Level")
|
||||
.IsUnique();
|
||||
|
||||
b.ToTable("BattlePassRewards");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("SVSim.Database.Models.BattlePassSeasonEntry", b =>
|
||||
{
|
||||
b.Property<int>("Id")
|
||||
.HasColumnType("integer");
|
||||
|
||||
b.Property<bool>("CanPurchase")
|
||||
.HasColumnType("boolean");
|
||||
|
||||
b.Property<DateTime>("DateCreated")
|
||||
.HasColumnType("timestamp with time zone");
|
||||
|
||||
b.Property<DateTime?>("DateUpdated")
|
||||
.HasColumnType("timestamp with time zone");
|
||||
|
||||
b.Property<string>("Description")
|
||||
.IsRequired()
|
||||
.HasColumnType("text");
|
||||
|
||||
b.Property<DateTimeOffset>("EndDate")
|
||||
.HasColumnType("timestamp with time zone");
|
||||
|
||||
b.Property<int>("MaxLevel")
|
||||
.HasColumnType("integer");
|
||||
|
||||
b.Property<string>("Name")
|
||||
.IsRequired()
|
||||
.HasColumnType("text");
|
||||
|
||||
b.Property<int>("PriceCrystal")
|
||||
.HasColumnType("integer");
|
||||
|
||||
b.Property<DateTimeOffset>("StartDate")
|
||||
.HasColumnType("timestamp with time zone");
|
||||
|
||||
b.HasKey("Id");
|
||||
|
||||
b.HasIndex("StartDate", "EndDate");
|
||||
|
||||
b.ToTable("BattlePassSeasons");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("SVSim.Database.Models.BattlefieldEntry", b =>
|
||||
{
|
||||
b.Property<int>("Id")
|
||||
@@ -1821,6 +1902,79 @@ namespace SVSim.Database.Migrations
|
||||
b.ToTable("Viewers");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("SVSim.Database.Models.ViewerBattlePassClaimEntry", b =>
|
||||
{
|
||||
b.Property<long>("Id")
|
||||
.HasColumnType("bigint");
|
||||
|
||||
b.Property<DateTimeOffset>("ClaimedAt")
|
||||
.HasColumnType("timestamp with time zone");
|
||||
|
||||
b.Property<DateTime>("DateCreated")
|
||||
.HasColumnType("timestamp with time zone");
|
||||
|
||||
b.Property<DateTime?>("DateUpdated")
|
||||
.HasColumnType("timestamp with time zone");
|
||||
|
||||
b.Property<int>("Level")
|
||||
.HasColumnType("integer");
|
||||
|
||||
b.Property<int>("SeasonId")
|
||||
.HasColumnType("integer");
|
||||
|
||||
b.Property<int>("Track")
|
||||
.HasColumnType("integer");
|
||||
|
||||
b.Property<long>("ViewerId")
|
||||
.HasColumnType("bigint");
|
||||
|
||||
b.HasKey("Id");
|
||||
|
||||
b.HasIndex("ViewerId", "SeasonId");
|
||||
|
||||
b.HasIndex("ViewerId", "SeasonId", "Track", "Level")
|
||||
.IsUnique();
|
||||
|
||||
b.ToTable("ViewerBattlePassClaims");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("SVSim.Database.Models.ViewerBattlePassProgressEntry", b =>
|
||||
{
|
||||
b.Property<long>("Id")
|
||||
.HasColumnType("bigint");
|
||||
|
||||
b.Property<int>("CurrentPoint")
|
||||
.HasColumnType("integer");
|
||||
|
||||
b.Property<DateTime>("DateCreated")
|
||||
.HasColumnType("timestamp with time zone");
|
||||
|
||||
b.Property<DateTime?>("DateUpdated")
|
||||
.HasColumnType("timestamp with time zone");
|
||||
|
||||
b.Property<bool>("IsPremium")
|
||||
.HasColumnType("boolean");
|
||||
|
||||
b.Property<int>("SeasonId")
|
||||
.HasColumnType("integer");
|
||||
|
||||
b.Property<long>("ViewerId")
|
||||
.HasColumnType("bigint");
|
||||
|
||||
b.Property<DateTimeOffset?>("WeeklyPeriodStart")
|
||||
.HasColumnType("timestamp with time zone");
|
||||
|
||||
b.Property<int>("WeeklyPoints")
|
||||
.HasColumnType("integer");
|
||||
|
||||
b.HasKey("Id");
|
||||
|
||||
b.HasIndex("ViewerId", "SeasonId")
|
||||
.IsUnique();
|
||||
|
||||
b.ToTable("ViewerBattlePassProgress");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("SVSim.Database.Models.ViewerPuzzleClear", b =>
|
||||
{
|
||||
b.Property<long>("ViewerId")
|
||||
@@ -2043,6 +2197,17 @@ namespace SVSim.Database.Migrations
|
||||
b.Navigation("World");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("SVSim.Database.Models.BattlePassRewardEntry", b =>
|
||||
{
|
||||
b.HasOne("SVSim.Database.Models.BattlePassSeasonEntry", "Season")
|
||||
.WithMany("Rewards")
|
||||
.HasForeignKey("SeasonId")
|
||||
.OnDelete(DeleteBehavior.Cascade)
|
||||
.IsRequired();
|
||||
|
||||
b.Navigation("Season");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("SVSim.Database.Models.BuildDeckProductEntry", b =>
|
||||
{
|
||||
b.HasOne("SVSim.Database.Models.BuildDeckSeriesEntry", "Series")
|
||||
@@ -2775,6 +2940,11 @@ namespace SVSim.Database.Migrations
|
||||
.IsRequired();
|
||||
});
|
||||
|
||||
modelBuilder.Entity("SVSim.Database.Models.BattlePassSeasonEntry", b =>
|
||||
{
|
||||
b.Navigation("Rewards");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("SVSim.Database.Models.BuildDeckSeriesEntry", b =>
|
||||
{
|
||||
b.Navigation("Products");
|
||||
|
||||
Reference in New Issue
Block a user