//
using System;
using Microsoft.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore.Infrastructure;
using Microsoft.EntityFrameworkCore.Metadata;
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
using SCHALE.Common.Database;
#nullable disable
namespace SCHALE.Common.Migrations.SqlServerMigrations
{
[DbContext(typeof(SCHALEContext))]
[Migration("20240501053823_Init")]
partial class Init
{
///
protected override void BuildTargetModel(ModelBuilder modelBuilder)
{
#pragma warning disable 612, 618
modelBuilder
.HasAnnotation("ProductVersion", "8.0.2")
.HasAnnotation("Relational:MaxIdentifierLength", 128);
SqlServerModelBuilderExtensions.UseIdentityColumns(modelBuilder);
modelBuilder.Entity("SCHALE.Common.Database.AccountDB", b =>
{
b.Property("ServerId")
.ValueGeneratedOnAdd()
.HasColumnType("bigint");
SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("ServerId"));
b.Property("BirthDay")
.HasColumnType("datetime2");
b.Property("CallName")
.HasColumnType("nvarchar(max)");
b.Property("CallNameUpdateTime")
.HasColumnType("datetime2");
b.Property("Comment")
.HasColumnType("nvarchar(max)");
b.Property("CreateDate")
.HasColumnType("datetime2");
b.Property("DevId")
.HasColumnType("nvarchar(max)");
b.Property("Exp")
.HasColumnType("bigint");
b.Property("LastConnectTime")
.HasColumnType("datetime2");
b.Property("Level")
.HasColumnType("int");
b.Property("LinkRewardDate")
.HasColumnType("datetime2");
b.Property("LobbyMode")
.HasColumnType("int");
b.Property("MemoryLobbyUniqueId")
.HasColumnType("bigint");
b.Property("Nickname")
.HasColumnType("nvarchar(max)");
b.Property("PublisherAccountId")
.HasColumnType("bigint");
b.Property("RepresentCharacterServerId")
.HasColumnType("int");
b.Property("RetentionDays")
.HasColumnType("int");
b.Property("State")
.HasColumnType("int");
b.Property("UnReadMailCount")
.HasColumnType("int");
b.Property("VIPLevel")
.HasColumnType("int");
b.HasKey("ServerId");
b.ToTable("Accounts");
});
modelBuilder.Entity("SCHALE.Common.Database.ItemDB", b =>
{
b.Property("ServerId")
.ValueGeneratedOnAdd()
.HasColumnType("bigint");
SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("ServerId"));
b.Property("AccountServerId")
.HasColumnType("bigint");
b.Property("IsLocked")
.HasColumnType("bit");
b.Property("StackCount")
.HasColumnType("bigint");
b.Property("UniqueId")
.HasColumnType("bigint");
b.HasKey("ServerId");
b.ToTable("Items");
});
modelBuilder.Entity("SCHALE.Common.Database.MissionProgressDB", b =>
{
b.Property("ServerId")
.ValueGeneratedOnAdd()
.HasColumnType("bigint");
SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("ServerId"));
b.Property("AccountServerId")
.HasColumnType("bigint");
b.Property("Complete")
.HasColumnType("bit");
b.Property("MissionUniqueId")
.HasColumnType("bigint");
b.Property("ProgressParameters")
.IsRequired()
.HasColumnType("nvarchar(max)");
b.Property("StartTime")
.HasColumnType("datetime2");
b.HasKey("ServerId");
b.ToTable("MissionProgresses");
});
modelBuilder.Entity("SCHALE.Common.Database.Models.AccountTutorial", b =>
{
b.Property("AccountServerId")
.HasColumnType("bigint");
b.Property("TutorialIds")
.IsRequired()
.HasColumnType("nvarchar(max)");
b.HasKey("AccountServerId");
b.ToTable("AccountTutorials");
});
modelBuilder.Entity("SCHALE.Common.Database.Models.GuestAccount", b =>
{
b.Property("Uid")
.ValueGeneratedOnAdd()
.HasColumnType("bigint");
SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Uid"));
b.Property("DeviceId")
.IsRequired()
.HasColumnType("nvarchar(max)");
b.Property("Token")
.IsRequired()
.HasColumnType("nvarchar(max)");
b.HasKey("Uid");
b.ToTable("GuestAccounts");
});
#pragma warning restore 612, 618
}
}
}