//
using System;
using BLHX.Server.Common.Database;
using Microsoft.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore.Infrastructure;
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
#nullable disable
namespace BLHX.Server.Common.Migrations.Player
{
[DbContext(typeof(PlayerContext))]
[Migration("20240405053357_Players_AddParams")]
partial class Players_AddParams
{
///
protected override void BuildTargetModel(ModelBuilder modelBuilder)
{
#pragma warning disable 612, 618
modelBuilder
.HasAnnotation("ProductVersion", "8.0.2")
.HasAnnotation("Proxies:ChangeTracking", false)
.HasAnnotation("Proxies:CheckEquality", false)
.HasAnnotation("Proxies:LazyLoading", true);
modelBuilder.Entity("BLHX.Server.Common.Database.ChapterInfo", b =>
{
b.Property("Id")
.HasColumnType("INTEGER");
b.Property("PlayerUid")
.HasColumnType("INTEGER");
b.Property("AiLists")
.IsRequired()
.HasColumnType("jsonb");
b.Property("BattleStatistics")
.IsRequired()
.HasColumnType("jsonb");
b.Property("BuffLists")
.IsRequired()
.HasColumnType("jsonb");
b.Property("CellFlagLists")
.IsRequired()
.HasColumnType("jsonb");
b.Property("CellLists")
.IsRequired()
.HasColumnType("jsonb");
b.Property("ChapterHp")
.HasColumnType("INTEGER");
b.Property("ChapterStrategyLists")
.IsRequired()
.HasColumnType("jsonb");
b.Property("ContinuousKillCount")
.HasColumnType("INTEGER");
b.Property("EscortLists")
.IsRequired()
.HasColumnType("jsonb");
b.Property("ExtraFlagLists")
.IsRequired()
.HasColumnType("jsonb");
b.Property("FleetDuties")
.IsRequired()
.HasColumnType("jsonb");
b.Property("GroupLists")
.IsRequired()
.HasColumnType("jsonb");
b.Property("InitShipCount")
.HasColumnType("INTEGER");
b.Property("IsSubmarineAutoAttack")
.HasColumnType("INTEGER");
b.Property("KillCount")
.HasColumnType("INTEGER");
b.Property("LoopFlag")
.HasColumnType("INTEGER");
b.Property("ModelActCount")
.HasColumnType("INTEGER");
b.Property("MoveStepCount")
.HasColumnType("INTEGER");
b.Property("OperationBuffs")
.IsRequired()
.HasColumnType("jsonb");
b.Property("Round")
.HasColumnType("INTEGER");
b.Property("Time")
.HasColumnType("TEXT");
b.HasKey("Id", "PlayerUid");
b.HasIndex("PlayerUid");
b.ToTable("ChapterInfoes");
});
modelBuilder.Entity("BLHX.Server.Common.Database.Player", b =>
{
b.Property("Uid")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property("AccPayLv")
.HasColumnType("INTEGER");
b.Property("Adv")
.IsRequired()
.ValueGeneratedOnAdd()
.HasColumnType("TEXT")
.HasDefaultValue("");
b.Property("Appreciation")
.IsRequired()
.HasColumnType("jsonb");
b.Property("AttackCount")
.HasColumnType("INTEGER");
b.Property("BuyOilCount")
.HasColumnType("INTEGER");
b.Property("CartoonCollectMarks")
.IsRequired()
.HasColumnType("TEXT");
b.Property("CartoonReadMarks")
.IsRequired()
.HasColumnType("TEXT");
b.Property("Characters")
.IsRequired()
.HasColumnType("TEXT");
b.Property("ChatMsgBanTime")
.HasColumnType("INTEGER");
b.Property("ChatRoomId")
.HasColumnType("INTEGER");
b.Property("ChildDisplay")
.HasColumnType("INTEGER");
b.Property("CollectAttackCount")
.HasColumnType("INTEGER");
b.Property("CommanderBagMax")
.HasColumnType("INTEGER");
b.Property("CreatedAt")
.HasColumnType("TEXT");
b.Property("CurrentChapter")
.HasColumnType("INTEGER");
b.Property("DisplayInfo")
.IsRequired()
.HasColumnType("jsonb");
b.Property("EquipBagMax")
.HasColumnType("INTEGER");
b.Property("Exp")
.HasColumnType("INTEGER");
b.Property("FlagLists")
.IsRequired()
.HasColumnType("TEXT");
b.Property("Fleets")
.IsRequired()
.ValueGeneratedOnAdd()
.HasColumnType("jsonb")
.HasDefaultValue("[{\"Id\":1,\"Name\":null,\"ShipLists\":[1,2],\"Commanders\":[]},{\"Id\":2,\"Name\":null,\"ShipLists\":[],\"Commanders\":[]},{\"Id\":11,\"Name\":null,\"ShipLists\":[],\"Commanders\":[]},{\"Id\":12,\"Name\":null,\"ShipLists\":[],\"Commanders\":[]}]");
b.Property("GmFlag")
.HasColumnType("INTEGER");
b.Property("GuideIndex")
.HasColumnType("INTEGER");
b.Property("GuildWaitTime")
.HasColumnType("INTEGER");
b.Property("Level")
.HasColumnType("INTEGER");
b.Property("MarryShip")
.HasColumnType("INTEGER");
b.Property("MaxRank")
.HasColumnType("INTEGER");
b.Property("MedalIds")
.IsRequired()
.HasColumnType("TEXT");
b.Property("Name")
.IsRequired()
.HasColumnType("TEXT");
b.Property("PvpAttackCount")
.HasColumnType("INTEGER");
b.Property("PvpWinCount")
.HasColumnType("INTEGER");
b.Property("RandomShipLists")
.IsRequired()
.HasColumnType("TEXT");
b.Property("RandomShipMode")
.HasColumnType("INTEGER");
b.Property("Rank")
.HasColumnType("INTEGER");
b.Property("Rmb")
.HasColumnType("INTEGER");
b.Property("ShipBagMax")
.HasColumnType("INTEGER");
b.Property("ShipSkins")
.IsRequired()
.ValueGeneratedOnAdd()
.HasColumnType("jsonb")
.HasDefaultValue("[]");
b.Property("Soundstories")
.IsRequired()
.HasColumnType("TEXT");
b.Property("StoryLists")
.IsRequired()
.HasColumnType("TEXT");
b.Property("ThemeUploadNotAllowedTime")
.HasColumnType("INTEGER");
b.Property("Token")
.IsRequired()
.HasColumnType("TEXT");
b.Property("WinCount")
.HasColumnType("INTEGER");
b.HasKey("Uid");
b.HasIndex("Token")
.IsUnique();
b.ToTable("Players");
});
modelBuilder.Entity("BLHX.Server.Common.Database.PlayerResource", b =>
{
b.Property("Id")
.HasColumnType("INTEGER");
b.Property("PlayerUid")
.HasColumnType("INTEGER");
b.Property("Num")
.HasColumnType("INTEGER");
b.HasKey("Id", "PlayerUid");
b.HasIndex("PlayerUid");
b.ToTable("Resources");
});
modelBuilder.Entity("BLHX.Server.Common.Database.PlayerShip", b =>
{
b.Property("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property("ActivityNpc")
.HasColumnType("INTEGER");
b.Property("BluePrintFlag")
.HasColumnType("INTEGER");
b.Property("CommanderId")
.HasColumnType("INTEGER");
b.Property("CommonFlag")
.HasColumnType("INTEGER");
b.Property("CoreLists")
.IsRequired()
.HasColumnType("jsonb");
b.Property("CreatedAt")
.HasColumnType("TEXT");
b.Property("Energy")
.HasColumnType("INTEGER");
b.Property("EquipInfoLists")
.IsRequired()
.HasColumnType("jsonb");
b.Property("Exp")
.HasColumnType("INTEGER");
b.Property("Intimacy")
.HasColumnType("INTEGER");
b.Property("IsLocked")
.HasColumnType("INTEGER");
b.Property("LastChangeName")
.HasColumnType("TEXT");
b.Property("Level")
.HasColumnType("INTEGER");
b.Property("MetaRepairLists")
.IsRequired()
.HasColumnType("jsonb");
b.Property("Name")
.HasColumnType("TEXT");
b.Property("PlayerUid")
.HasColumnType("INTEGER");
b.Property("Proficiency")
.HasColumnType("INTEGER");
b.Property("Propose")
.HasColumnType("INTEGER");
b.Property("SkillIdLists")
.IsRequired()
.HasColumnType("jsonb");
b.Property("SkinId")
.HasColumnType("INTEGER");
b.Property("State")
.IsRequired()
.HasColumnType("jsonb");
b.Property("StrengthLists")
.IsRequired()
.HasColumnType("jsonb");
b.Property("TemplateId")
.HasColumnType("INTEGER");
b.Property("TransformLists")
.IsRequired()
.HasColumnType("jsonb");
b.HasKey("Id");
b.HasIndex("PlayerUid");
b.ToTable("Ships");
});
modelBuilder.Entity("BLHX.Server.Common.Database.ResourceField", b =>
{
b.Property("Type")
.HasColumnType("INTEGER");
b.Property("PlayerUid")
.HasColumnType("INTEGER");
b.Property("LastHarvestTime")
.HasColumnType("TEXT");
b.Property("Level")
.HasColumnType("INTEGER");
b.Property("UpgradeTime")
.HasColumnType("TEXT");
b.HasKey("Type", "PlayerUid");
b.HasIndex("PlayerUid");
b.ToTable("ResourceFields");
});
modelBuilder.Entity("BLHX.Server.Common.Proto.common.Idtimeinfo", b =>
{
b.Property("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property("PlayerUid")
.HasColumnType("INTEGER");
b.Property("PlayerUid1")
.HasColumnType("INTEGER");
b.Property("Time")
.HasColumnType("INTEGER");
b.HasKey("Id");
b.HasIndex("PlayerUid");
b.HasIndex("PlayerUid1");
b.ToTable("Idtimeinfo");
});
modelBuilder.Entity("BLHX.Server.Common.Database.ChapterInfo", b =>
{
b.HasOne("BLHX.Server.Common.Database.Player", "Player")
.WithMany("ChapterInfoes")
.HasForeignKey("PlayerUid")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.Navigation("Player");
});
modelBuilder.Entity("BLHX.Server.Common.Database.Player", b =>
{
b.OwnsOne("System.Collections.Generic.List", "RefundShopInfoLists", b1 =>
{
b1.Property("PlayerUid")
.HasColumnType("INTEGER");
b1.Property("Capacity")
.HasColumnType("INTEGER");
b1.HasKey("PlayerUid");
b1.ToTable("Players");
b1.WithOwner()
.HasForeignKey("PlayerUid");
});
b.OwnsOne("System.Collections.Generic.List", "CardLists", b1 =>
{
b1.Property("PlayerUid")
.HasColumnType("INTEGER");
b1.Property("Capacity")
.HasColumnType("INTEGER");
b1.HasKey("PlayerUid");
b1.ToTable("Players");
b1.WithOwner()
.HasForeignKey("PlayerUid");
});
b.OwnsOne("System.Collections.Generic.List", "CdLists", b1 =>
{
b1.Property("PlayerUid")
.HasColumnType("INTEGER");
b1.Property("Capacity")
.HasColumnType("INTEGER");
b1.HasKey("PlayerUid");
b1.ToTable("Players");
b1.WithOwner()
.HasForeignKey("PlayerUid");
});
b.OwnsOne("System.Collections.Generic.List", "TakingShipLists", b1 =>
{
b1.Property("PlayerUid")
.HasColumnType("INTEGER");
b1.Property("Capacity")
.HasColumnType("INTEGER");
b1.HasKey("PlayerUid");
b1.ToTable("Players");
b1.WithOwner()
.HasForeignKey("PlayerUid");
});
b.Navigation("CardLists")
.IsRequired();
b.Navigation("CdLists")
.IsRequired();
b.Navigation("RefundShopInfoLists")
.IsRequired();
b.Navigation("TakingShipLists")
.IsRequired();
});
modelBuilder.Entity("BLHX.Server.Common.Database.PlayerResource", b =>
{
b.HasOne("BLHX.Server.Common.Database.Player", "Player")
.WithMany("Resources")
.HasForeignKey("PlayerUid")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.Navigation("Player");
});
modelBuilder.Entity("BLHX.Server.Common.Database.PlayerShip", b =>
{
b.HasOne("BLHX.Server.Common.Database.Player", "Player")
.WithMany("Ships")
.HasForeignKey("PlayerUid")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.Navigation("Player");
});
modelBuilder.Entity("BLHX.Server.Common.Database.ResourceField", b =>
{
b.HasOne("BLHX.Server.Common.Database.Player", "Player")
.WithMany("ResourceFields")
.HasForeignKey("PlayerUid")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.Navigation("Player");
});
modelBuilder.Entity("BLHX.Server.Common.Proto.common.Idtimeinfo", b =>
{
b.HasOne("BLHX.Server.Common.Database.Player", null)
.WithMany("ChatFrameLists")
.HasForeignKey("PlayerUid");
b.HasOne("BLHX.Server.Common.Database.Player", null)
.WithMany("IconFrameLists")
.HasForeignKey("PlayerUid1");
});
modelBuilder.Entity("BLHX.Server.Common.Database.Player", b =>
{
b.Navigation("ChapterInfoes");
b.Navigation("ChatFrameLists");
b.Navigation("IconFrameLists");
b.Navigation("ResourceFields");
b.Navigation("Resources");
b.Navigation("Ships");
});
#pragma warning restore 612, 618
}
}
}