// <auto-generated />
using System;
using HackSystem.WebAPI.Infrastructure.DBContexts;
using Microsoft.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore.Infrastructure;
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Storage.ValueConversion;

#nullable disable

namespace HackSystem.WebAPI.Infrastructure.Migrations
{
    [DbContext(typeof(HackSystemDbContext))]
    [Migration("20221210101430_InitialMigration")]
    partial class InitialMigration
    {
        protected override void BuildTargetModel(ModelBuilder modelBuilder)
        {
#pragma warning disable 612, 618
            modelBuilder.HasAnnotation("ProductVersion", "6.0.7");

            modelBuilder.Entity("HackSystem.WebAPI.Domain.Entity.GenericOption", b =>
                {
                    b.Property<int>("OptionID")
                        .ValueGeneratedOnAdd()
                        .HasColumnType("INTEGER");

                    b.Property<string>("Category")
                        .HasColumnType("TEXT")
                        .UseCollation("NOCASE");

                    b.Property<DateTime>("CreateTime")
                        .HasColumnType("TEXT");

                    b.Property<DateTime>("ModifyTime")
                        .HasColumnType("TEXT");

                    b.Property<string>("OptionName")
                        .IsRequired()
                        .HasColumnType("TEXT")
                        .UseCollation("NOCASE");

                    b.Property<string>("OptionValue")
                        .IsRequired()
                        .HasColumnType("TEXT");

                    b.Property<string>("OwnerLevel")
                        .HasColumnType("TEXT")
                        .UseCollation("NOCASE");

                    b.HasKey("OptionID");

                    b.HasIndex("OptionName", "Category", "OwnerLevel")
                        .IsUnique();

                    b.ToTable("GenericOptions");
                });

            modelBuilder.Entity("HackSystem.WebAPI.Domain.Entity.Identity.HackSystemRole", b =>
                {
                    b.Property<string>("Id")
                        .HasColumnType("TEXT");

                    b.Property<string>("ConcurrencyStamp")
                        .IsConcurrencyToken()
                        .HasColumnType("TEXT");

                    b.Property<string>("Name")
                        .HasMaxLength(256)
                        .HasColumnType("TEXT");

                    b.Property<string>("NormalizedName")
                        .HasMaxLength(256)
                        .HasColumnType("TEXT");

                    b.HasKey("Id");

                    b.HasIndex("NormalizedName")
                        .IsUnique()
                        .HasDatabaseName("RoleNameIndex");

                    b.ToTable("AspNetRoles", (string)null);

                    b.HasData(
                        new
                        {
                            Id = "msaspnet-core-role-hack-system000001",
                            ConcurrencyStamp = "8ef3768d-cdd3-43a4-9338-c549cec56942",
                            Name = "Hacker",
                            NormalizedName = "HACKER"
                        },
                        new
                        {
                            Id = "msaspnet-core-role-hack-system000002",
                            ConcurrencyStamp = "43daf209-df6b-499c-83e5-94ea05cf8997",
                            Name = "Commander",
                            NormalizedName = "COMMANDER"
                        });
                });

            modelBuilder.Entity("HackSystem.WebAPI.Domain.Entity.Identity.HackSystemUser", b =>
                {
                    b.Property<string>("Id")
                        .HasColumnType("TEXT");

                    b.Property<int>("AccessFailedCount")
                        .HasColumnType("INTEGER");

                    b.Property<string>("ConcurrencyStamp")
                        .IsConcurrencyToken()
                        .HasColumnType("TEXT");

                    b.Property<string>("Email")
                        .HasMaxLength(256)
                        .HasColumnType("TEXT");

                    b.Property<bool>("EmailConfirmed")
                        .HasColumnType("INTEGER");

                    b.Property<int>("ExperienceLevel")
                        .HasColumnType("INTEGER");

                    b.Property<int>("ExperiencePoints")
                        .HasColumnType("INTEGER");

                    b.Property<bool>("LockoutEnabled")
                        .HasColumnType("INTEGER");

                    b.Property<DateTimeOffset?>("LockoutEnd")
                        .HasColumnType("TEXT");

                    b.Property<string>("NormalizedEmail")
                        .HasMaxLength(256)
                        .HasColumnType("TEXT");

                    b.Property<string>("NormalizedUserName")
                        .HasMaxLength(256)
                        .HasColumnType("TEXT");

                    b.Property<string>("PasswordHash")
                        .HasColumnType("TEXT");

                    b.Property<string>("PhoneNumber")
                        .HasColumnType("TEXT");

                    b.Property<bool>("PhoneNumberConfirmed")
                        .HasColumnType("INTEGER");

                    b.Property<string>("SecurityStamp")
                        .HasColumnType("TEXT");

                    b.Property<bool>("TwoFactorEnabled")
                        .HasColumnType("INTEGER");

                    b.Property<string>("UserName")
                        .HasMaxLength(256)
                        .HasColumnType("TEXT");

                    b.HasKey("Id");

                    b.HasIndex("NormalizedEmail")
                        .HasDatabaseName("EmailIndex");

                    b.HasIndex("NormalizedUserName")
                        .IsUnique()
                        .HasDatabaseName("UserNameIndex");

                    b.ToTable("AspNetUsers", (string)null);

                    b.HasData(
                        new
                        {
                            Id = "msaspnet-core-user-hack-system000001",
                            AccessFailedCount = 0,
                            ConcurrencyStamp = "baeb86b5-116c-43ae-ade7-489dabd07012",
                            Email = "leon@hack.com",
                            EmailConfirmed = true,
                            ExperienceLevel = 0,
                            ExperiencePoints = 0,
                            LockoutEnabled = true,
                            NormalizedEmail = "LEON@HACK.COM",
                            NormalizedUserName = "LEON",
                            PasswordHash = "AQAAAAEAACcQAAAAEBpsyxgzjSNJvSIm6y3I1jqvKN4iV/IkvwmMrrYR5X8a6pEXza2RwA9xxSXidOiGkQ==",
                            PhoneNumberConfirmed = false,
                            SecurityStamp = "SU6NODNYTSGYJ5NXXYIA7I2M542MLV2V",
                            TwoFactorEnabled = false,
                            UserName = "Leon"
                        },
                        new
                        {
                            Id = "msaspnet-core-user-hack-system000002",
                            AccessFailedCount = 0,
                            ConcurrencyStamp = "a3e94fcc-39cf-4a2f-8b23-f08424042cb8",
                            Email = "commander@hack.com",
                            EmailConfirmed = true,
                            ExperienceLevel = 0,
                            ExperiencePoints = 0,
                            LockoutEnabled = true,
                            NormalizedEmail = "COMMANDER@HACK.COM",
                            NormalizedUserName = "CMD",
                            PasswordHash = "AQAAAAEAACcQAAAAEBLD9HIQLb2pLRH1Vrv1PnOuab+diYEwtCoWFyIx/S+C2nynO4S9NMBUjdQUcVWFrg==",
                            PhoneNumberConfirmed = false,
                            SecurityStamp = "GMGJIR7MWWVSLB2IYMAP445FXWPKZQE5",
                            TwoFactorEnabled = false,
                            UserName = "CMD"
                        },
                        new
                        {
                            Id = "msaspnet-core-user-hack-system000003",
                            AccessFailedCount = 0,
                            ConcurrencyStamp = "93cdc1b8-0c84-4f52-9245-d6ae4bbe5f59",
                            Email = "mathilda@hack.com",
                            EmailConfirmed = true,
                            ExperienceLevel = 0,
                            ExperiencePoints = 0,
                            LockoutEnabled = true,
                            NormalizedEmail = "MATHILDA@HACK.COM",
                            NormalizedUserName = "MATHILDA",
                            PasswordHash = "AQAAAAEAACcQAAAAEDjIsjVamUxv4OQ06Ur/7YnsqddYfO2eQP7UK/Adjs38RIkmBpgTldrfCXZ5QHP1vQ==",
                            PhoneNumberConfirmed = false,
                            SecurityStamp = "2NGFUDFGMLPCBN5U67CHXJEYIDBWQPO3",
                            TwoFactorEnabled = false,
                            UserName = "Mathilda"
                        });
                });

            modelBuilder.Entity("HackSystem.WebAPI.Domain.Entity.WebAPILog", b =>
                {
                    b.Property<int>("WebAPILogID")
                        .ValueGeneratedOnAdd()
                        .HasColumnType("INTEGER");

                    b.Property<long>("ElapsedTime")
                        .HasColumnType("INTEGER");

                    b.Property<string>("Exception")
                        .HasColumnType("TEXT");

                    b.Property<DateTime>("FinishDateTime")
                        .HasColumnType("TEXT");

                    b.Property<string>("IdentityName")
                        .HasColumnType("TEXT");

                    b.Property<bool>("IsAuthenticated")
                        .HasColumnType("INTEGER");

                    b.Property<string>("Method")
                        .IsRequired()
                        .HasColumnType("TEXT");

                    b.Property<string>("QueryString")
                        .IsRequired()
                        .HasColumnType("TEXT");

                    b.Property<string>("RequestBody")
                        .HasColumnType("TEXT");

                    b.Property<string>("RequestURI")
                        .IsRequired()
                        .HasColumnType("TEXT");

                    b.Property<string>("ResponseBody")
                        .HasColumnType("TEXT");

                    b.Property<string>("SourceHost")
                        .IsRequired()
                        .HasColumnType("TEXT");

                    b.Property<DateTime>("StartDateTime")
                        .HasColumnType("TEXT");

                    b.Property<int>("StatusCode")
                        .HasColumnType("INTEGER");

                    b.Property<string>("TraceIdentifier")
                        .IsRequired()
                        .HasColumnType("TEXT");

                    b.Property<string>("UserAgent")
                        .IsRequired()
                        .HasColumnType("TEXT");

                    b.HasKey("WebAPILogID");

                    b.HasIndex("RequestURI", "SourceHost", "IdentityName", "StartDateTime");

                    b.ToTable("WebAPILogs");
                });

            modelBuilder.Entity("HackSystem.WebAPI.MockServer.Domain.Entity.MockRouteDetail", b =>
                {
                    b.Property<int>("RouteID")
                        .ValueGeneratedOnAdd()
                        .HasColumnType("INTEGER");

                    b.Property<int>("DelayDuration")
                        .HasColumnType("INTEGER");

                    b.Property<bool>("Enabled")
                        .HasColumnType("INTEGER");

                    b.Property<string>("ForwardAddress")
                        .HasColumnType("TEXT");

                    b.Property<string>("ForwardMethod")
                        .HasColumnType("TEXT");

                    b.Property<int?>("ForwardMockType")
                        .HasColumnType("INTEGER");

                    b.Property<string>("ForwardRequestBodyTemplate")
                        .HasColumnType("TEXT");

                    b.Property<string>("MockMethod")
                        .HasColumnType("TEXT")
                        .UseCollation("NOCASE");

                    b.Property<string>("MockSourceHost")
                        .HasColumnType("TEXT")
                        .UseCollation("NOCASE");

                    b.Property<int>("MockType")
                        .HasColumnType("INTEGER");

                    b.Property<string>("MockURI")
                        .IsRequired()
                        .HasColumnType("TEXT")
                        .UseCollation("NOCASE");

                    b.Property<string>("ResponseBodyTemplate")
                        .IsRequired()
                        .HasColumnType("TEXT");

                    b.Property<string>("RouteName")
                        .IsRequired()
                        .HasColumnType("TEXT");

                    b.Property<int>("StatusCode")
                        .HasColumnType("INTEGER");

                    b.HasKey("RouteID");

                    b.HasIndex("Enabled");

                    b.HasIndex("MockURI", "MockMethod", "MockSourceHost")
                        .IsUnique();

                    b.ToTable("MockRouteDetails");
                });

            modelBuilder.Entity("HackSystem.WebAPI.MockServer.Domain.Entity.MockRouteLogDetail", b =>
                {
                    b.Property<int>("RouteLogID")
                        .ValueGeneratedOnAdd()
                        .HasColumnType("INTEGER");

                    b.Property<string>("ConnectionID")
                        .IsRequired()
                        .HasColumnType("TEXT");

                    b.Property<string>("Exception")
                        .HasColumnType("TEXT");

                    b.Property<DateTime>("FinishDateTime")
                        .HasColumnType("TEXT");

                    b.Property<string>("ForwardAddress")
                        .HasColumnType("TEXT");

                    b.Property<DateTime?>("ForwardDateTime")
                        .HasColumnType("TEXT");

                    b.Property<string>("ForwardMethod")
                        .HasColumnType("TEXT");

                    b.Property<int?>("ForwardMockType")
                        .HasColumnType("INTEGER");

                    b.Property<string>("ForwardResponseBody")
                        .HasColumnType("TEXT");

                    b.Property<int>("ForwardResponseStatusCode")
                        .HasColumnType("INTEGER");

                    b.Property<string>("Method")
                        .IsRequired()
                        .HasColumnType("TEXT");

                    b.Property<int>("MockRouteLogStatus")
                        .HasColumnType("INTEGER");

                    b.Property<int>("MockType")
                        .HasColumnType("INTEGER");

                    b.Property<string>("RequestBody")
                        .IsRequired()
                        .HasColumnType("TEXT");

                    b.Property<string>("ResponseBody")
                        .IsRequired()
                        .HasColumnType("TEXT");

                    b.Property<int>("RouteID")
                        .HasColumnType("INTEGER");

                    b.Property<string>("SourceHost")
                        .IsRequired()
                        .HasColumnType("TEXT");

                    b.Property<DateTime>("StartDateTime")
                        .HasColumnType("TEXT");

                    b.Property<int>("StatusCode")
                        .HasColumnType("INTEGER");

                    b.Property<string>("URI")
                        .IsRequired()
                        .HasColumnType("TEXT");

                    b.HasKey("RouteLogID");

                    b.HasIndex("RouteID");

                    b.HasIndex("URI", "Method", "SourceHost", "MockType");

                    b.ToTable("MockRouteLogDetails");
                });

            modelBuilder.Entity("HackSystem.WebAPI.ProgramServer.Domain.Entity.Maps.UserProgramMap", b =>
                {
                    b.Property<string>("UserId")
                        .HasColumnType("TEXT");

                    b.Property<string>("ProgramId")
                        .HasColumnType("TEXT");

                    b.Property<bool>("PinToDesktop")
                        .HasColumnType("INTEGER");

                    b.Property<bool>("PinToDock")
                        .HasColumnType("INTEGER");

                    b.Property<bool>("PinToTop")
                        .HasColumnType("INTEGER");

                    b.Property<string>("Rename")
                        .HasColumnType("TEXT");

                    b.HasKey("UserId", "ProgramId");

                    b.HasIndex("ProgramId");

                    b.HasIndex("UserId");

                    b.HasIndex("UserId", "ProgramId")
                        .IsUnique();

                    b.ToTable("UserProgramMaps");

                    b.HasData(
                        new
                        {
                            UserId = "msaspnet-core-user-hack-system000001",
                            ProgramId = "program0-icon-0828-hack-system000001",
                            PinToDesktop = true,
                            PinToDock = true,
                            PinToTop = false
                        },
                        new
                        {
                            UserId = "msaspnet-core-user-hack-system000001",
                            ProgramId = "program0-icon-0828-hack-system000002",
                            PinToDesktop = true,
                            PinToDock = true,
                            PinToTop = false
                        },
                        new
                        {
                            UserId = "msaspnet-core-user-hack-system000001",
                            ProgramId = "program0-icon-0828-hack-system000003",
                            PinToDesktop = true,
                            PinToDock = false,
                            PinToTop = false
                        },
                        new
                        {
                            UserId = "msaspnet-core-user-hack-system000001",
                            ProgramId = "program0-icon-0828-hack-system000004",
                            PinToDesktop = true,
                            PinToDock = true,
                            PinToTop = false
                        },
                        new
                        {
                            UserId = "msaspnet-core-user-hack-system000001",
                            ProgramId = "program0-icon-0828-hack-system000005",
                            PinToDesktop = true,
                            PinToDock = true,
                            PinToTop = false
                        },
                        new
                        {
                            UserId = "msaspnet-core-user-hack-system000001",
                            ProgramId = "program0-icon-0828-hack-system000006",
                            PinToDesktop = true,
                            PinToDock = false,
                            PinToTop = false
                        },
                        new
                        {
                            UserId = "msaspnet-core-user-hack-system000001",
                            ProgramId = "program0-icon-0828-hack-system000007",
                            PinToDesktop = true,
                            PinToDock = false,
                            PinToTop = false
                        },
                        new
                        {
                            UserId = "msaspnet-core-user-hack-system000002",
                            ProgramId = "program0-icon-0828-hack-system000001",
                            PinToDesktop = true,
                            PinToDock = true,
                            PinToTop = false
                        },
                        new
                        {
                            UserId = "msaspnet-core-user-hack-system000002",
                            ProgramId = "program0-icon-0828-hack-system000002",
                            PinToDesktop = true,
                            PinToDock = true,
                            PinToTop = false
                        },
                        new
                        {
                            UserId = "msaspnet-core-user-hack-system000002",
                            ProgramId = "program0-icon-0828-hack-system000003",
                            PinToDesktop = true,
                            PinToDock = false,
                            PinToTop = false
                        },
                        new
                        {
                            UserId = "msaspnet-core-user-hack-system000002",
                            ProgramId = "program0-icon-0828-hack-system000004",
                            PinToDesktop = true,
                            PinToDock = true,
                            PinToTop = false
                        },
                        new
                        {
                            UserId = "msaspnet-core-user-hack-system000002",
                            ProgramId = "program0-icon-0828-hack-system000005",
                            PinToDesktop = true,
                            PinToDock = true,
                            PinToTop = false
                        },
                        new
                        {
                            UserId = "msaspnet-core-user-hack-system000002",
                            ProgramId = "program0-icon-0828-hack-system000006",
                            PinToDesktop = true,
                            PinToDock = false,
                            PinToTop = false
                        },
                        new
                        {
                            UserId = "msaspnet-core-user-hack-system000002",
                            ProgramId = "program0-icon-0828-hack-system000007",
                            PinToDesktop = true,
                            PinToDock = false,
                            PinToTop = false
                        },
                        new
                        {
                            UserId = "msaspnet-core-user-hack-system000003",
                            ProgramId = "program0-icon-0828-hack-system000001",
                            PinToDesktop = true,
                            PinToDock = true,
                            PinToTop = false
                        },
                        new
                        {
                            UserId = "msaspnet-core-user-hack-system000003",
                            ProgramId = "program0-icon-0828-hack-system000002",
                            PinToDesktop = true,
                            PinToDock = true,
                            PinToTop = false
                        },
                        new
                        {
                            UserId = "msaspnet-core-user-hack-system000003",
                            ProgramId = "program0-icon-0828-hack-system000003",
                            PinToDesktop = true,
                            PinToDock = false,
                            PinToTop = false
                        },
                        new
                        {
                            UserId = "msaspnet-core-user-hack-system000003",
                            ProgramId = "program0-icon-0828-hack-system000004",
                            PinToDesktop = true,
                            PinToDock = true,
                            PinToTop = false
                        },
                        new
                        {
                            UserId = "msaspnet-core-user-hack-system000003",
                            ProgramId = "program0-icon-0828-hack-system000005",
                            PinToDesktop = true,
                            PinToDock = true,
                            PinToTop = false
                        },
                        new
                        {
                            UserId = "msaspnet-core-user-hack-system000003",
                            ProgramId = "program0-icon-0828-hack-system000006",
                            PinToDesktop = true,
                            PinToDock = false,
                            PinToTop = false
                        },
                        new
                        {
                            UserId = "msaspnet-core-user-hack-system000003",
                            ProgramId = "program0-icon-0828-hack-system000007",
                            PinToDesktop = true,
                            PinToDock = false,
                            PinToTop = false
                        });
                });

            modelBuilder.Entity("HackSystem.WebAPI.ProgramServer.Domain.Entity.Programs.ProgramDetail", b =>
                {
                    b.Property<string>("Id")
                        .ValueGeneratedOnAdd()
                        .HasColumnType("TEXT");

                    b.Property<bool>("Enabled")
                        .HasColumnType("INTEGER");

                    b.Property<string>("EntryAssemblyName")
                        .IsRequired()
                        .HasColumnType("TEXT");

                    b.Property<string>("EntryParameter")
                        .HasColumnType("TEXT");

                    b.Property<string>("EntryTypeName")
                        .IsRequired()
                        .HasColumnType("TEXT");

                    b.Property<bool>("Mandatory")
                        .HasColumnType("INTEGER");

                    b.Property<string>("Name")
                        .IsRequired()
                        .HasColumnType("TEXT");

                    b.Property<bool>("SingleInstance")
                        .HasColumnType("INTEGER");

                    b.HasKey("Id");

                    b.HasIndex("Id", "Name");

                    b.ToTable("ProgramDetails");

                    b.HasData(
                        new
                        {
                            Id = "program0-icon-0828-hack-system000001",
                            Enabled = true,
                            EntryAssemblyName = "HackSystem.Web.Home",
                            EntryTypeName = "HackSystem.Web.Home.Launcher",
                            Mandatory = true,
                            Name = "Home",
                            SingleInstance = true
                        },
                        new
                        {
                            Id = "program0-icon-0828-hack-system000002",
                            Enabled = true,
                            EntryAssemblyName = "HackSystem.Web.Explorer",
                            EntryTypeName = "HackSystem.Web.Explorer.Launcher",
                            Mandatory = true,
                            Name = "Explorer",
                            SingleInstance = false
                        },
                        new
                        {
                            Id = "program0-icon-0828-hack-system000003",
                            Enabled = true,
                            EntryAssemblyName = "HackSystem.Web.Profile",
                            EntryTypeName = "HackSystem.Web.Profile.Launcher",
                            Mandatory = true,
                            Name = "Profile",
                            SingleInstance = true
                        },
                        new
                        {
                            Id = "program0-icon-0828-hack-system000004",
                            Enabled = true,
                            EntryAssemblyName = "HackSystem.Web.Setting",
                            EntryTypeName = "HackSystem.Web.Setting.Launcher",
                            Mandatory = true,
                            Name = "Setting",
                            SingleInstance = true
                        },
                        new
                        {
                            Id = "program0-icon-0828-hack-system000005",
                            Enabled = true,
                            EntryAssemblyName = "HackSystem.Web.AppStore",
                            EntryTypeName = "HackSystem.Web.AppStore.Launcher",
                            Mandatory = true,
                            Name = "AppStore",
                            SingleInstance = true
                        },
                        new
                        {
                            Id = "program0-icon-0828-hack-system000006",
                            Enabled = true,
                            EntryAssemblyName = "HackSystem.Web.TaskSchedule",
                            EntryParameter = "{ \"Developer\": \"Leon\" }",
                            EntryTypeName = "HackSystem.Web.TaskSchedule.Launcher",
                            Mandatory = true,
                            Name = "TaskServer",
                            SingleInstance = true
                        },
                        new
                        {
                            Id = "program0-icon-0828-hack-system000007",
                            Enabled = true,
                            EntryAssemblyName = "HackSystem.Web.MockServer",
                            EntryTypeName = "HackSystem.Web.MockServer.Launcher",
                            Mandatory = true,
                            Name = "MockServer",
                            SingleInstance = true
                        });
                });

            modelBuilder.Entity("HackSystem.WebAPI.ProgramServer.Domain.Entity.ProgramUser", b =>
                {
                    b.Property<string>("Id")
                        .HasColumnType("TEXT");

                    b.HasKey("Id");

                    b.ToTable("ProgramUsers");

                    b.HasData(
                        new
                        {
                            Id = "msaspnet-core-user-hack-system000001"
                        },
                        new
                        {
                            Id = "msaspnet-core-user-hack-system000002"
                        },
                        new
                        {
                            Id = "msaspnet-core-user-hack-system000003"
                        });
                });

            modelBuilder.Entity("HackSystem.WebAPI.TaskServer.Domain.Entity.TaskDetail", b =>
                {
                    b.Property<int>("TaskID")
                        .ValueGeneratedOnAdd()
                        .HasColumnType("INTEGER");

                    b.Property<string>("AssemblyName")
                        .IsRequired()
                        .HasColumnType("TEXT");

                    b.Property<TimeSpan>("AutomaticInterval")
                        .HasColumnType("TEXT");

                    b.Property<string>("Category")
                        .HasColumnType("TEXT");

                    b.Property<string>("ClassName")
                        .IsRequired()
                        .HasColumnType("TEXT");

                    b.Property<DateTime>("CreateTime")
                        .HasColumnType("TEXT");

                    b.Property<bool>("Enabled")
                        .HasColumnType("INTEGER");

                    b.Property<DateTime>("ExecuteDateTime")
                        .HasColumnType("TEXT");

                    b.Property<TimeSpan>("FirstInterval")
                        .HasColumnType("TEXT");

                    b.Property<string>("Parameters")
                        .HasColumnType("TEXT");

                    b.Property<string>("ProcedureName")
                        .IsRequired()
                        .HasColumnType("TEXT");

                    b.Property<bool>("Reentrant")
                        .HasColumnType("INTEGER");

                    b.Property<int>("TaskFrequency")
                        .HasColumnType("INTEGER");

                    b.Property<string>("TaskName")
                        .IsRequired()
                        .HasColumnType("TEXT");

                    b.HasKey("TaskID");

                    b.HasIndex("Enabled");

                    b.HasIndex("TaskName")
                        .IsUnique();

                    b.HasIndex("TaskName", "ExecuteDateTime");

                    b.ToTable("TaskDetails");

                    b.HasData(
                        new
                        {
                            TaskID = 1,
                            AssemblyName = "HackSystem.WebAPI.Tasks",
                            AutomaticInterval = new TimeSpan(0, 0, 0, 0, 0),
                            Category = "HackSystem",
                            ClassName = "HackSystem.WebAPI.Tasks.DatabaseBackup.IDatabaseBackupTask",
                            CreateTime = new DateTime(2021, 7, 24, 14, 3, 30, 0, DateTimeKind.Unspecified),
                            Enabled = true,
                            ExecuteDateTime = new DateTime(2021, 7, 24, 5, 0, 0, 0, DateTimeKind.Unspecified),
                            FirstInterval = new TimeSpan(0, 0, 0, 0, 0),
                            Parameters = "OriginDB=DATA SOURCE=.\\HackSystem.db|BackupDB=DATA SOURCE=.\\HackSystem_backup_{0}.db",
                            ProcedureName = "Execute",
                            Reentrant = false,
                            TaskFrequency = 3,
                            TaskName = "Database Auto Backup"
                        });
                });

            modelBuilder.Entity("HackSystem.WebAPI.TaskServer.Domain.Entity.TaskLogDetail", b =>
                {
                    b.Property<int>("TaskLogID")
                        .ValueGeneratedOnAdd()
                        .HasColumnType("INTEGER");

                    b.Property<string>("Exception")
                        .HasColumnType("TEXT");

                    b.Property<DateTime>("FinishDateTime")
                        .HasColumnType("TEXT");

                    b.Property<string>("Parameters")
                        .HasColumnType("TEXT");

                    b.Property<DateTime>("StartDateTime")
                        .HasColumnType("TEXT");

                    b.Property<int>("TaskID")
                        .HasColumnType("INTEGER");

                    b.Property<int>("TaskLogStatus")
                        .HasColumnType("INTEGER");

                    b.Property<string>("Trigger")
                        .IsRequired()
                        .HasColumnType("TEXT");

                    b.Property<DateTime>("TriggerDateTime")
                        .HasColumnType("TEXT");

                    b.HasKey("TaskLogID");

                    b.HasIndex("TaskID");

                    b.HasIndex("TaskID", "TaskLogStatus");

                    b.ToTable("TaskLogDetails");
                });

            modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityRoleClaim<string>", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd()
                        .HasColumnType("INTEGER");

                    b.Property<string>("ClaimType")
                        .HasColumnType("TEXT");

                    b.Property<string>("ClaimValue")
                        .HasColumnType("TEXT");

                    b.Property<string>("RoleId")
                        .IsRequired()
                        .HasColumnType("TEXT");

                    b.HasKey("Id");

                    b.HasIndex("RoleId");

                    b.ToTable("AspNetRoleClaims", (string)null);
                });

            modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserClaim<string>", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd()
                        .HasColumnType("INTEGER");

                    b.Property<string>("ClaimType")
                        .HasColumnType("TEXT");

                    b.Property<string>("ClaimValue")
                        .HasColumnType("TEXT");

                    b.Property<string>("UserId")
                        .IsRequired()
                        .HasColumnType("TEXT");

                    b.HasKey("Id");

                    b.HasIndex("UserId");

                    b.ToTable("AspNetUserClaims", (string)null);

                    b.HasData(
                        new
                        {
                            Id = 1,
                            ClaimType = "Professional",
                            ClaimValue = "true",
                            UserId = "msaspnet-core-user-hack-system000001"
                        });
                });

            modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserLogin<string>", b =>
                {
                    b.Property<string>("LoginProvider")
                        .HasColumnType("TEXT");

                    b.Property<string>("ProviderKey")
                        .HasColumnType("TEXT");

                    b.Property<string>("ProviderDisplayName")
                        .HasColumnType("TEXT");

                    b.Property<string>("UserId")
                        .IsRequired()
                        .HasColumnType("TEXT");

                    b.HasKey("LoginProvider", "ProviderKey");

                    b.HasIndex("UserId");

                    b.ToTable("AspNetUserLogins", (string)null);
                });

            modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserRole<string>", b =>
                {
                    b.Property<string>("UserId")
                        .HasColumnType("TEXT");

                    b.Property<string>("RoleId")
                        .HasColumnType("TEXT");

                    b.HasKey("UserId", "RoleId");

                    b.HasIndex("RoleId");

                    b.ToTable("AspNetUserRoles", (string)null);

                    b.HasData(
                        new
                        {
                            UserId = "msaspnet-core-user-hack-system000001",
                            RoleId = "msaspnet-core-role-hack-system000001"
                        },
                        new
                        {
                            UserId = "msaspnet-core-user-hack-system000001",
                            RoleId = "msaspnet-core-role-hack-system000002"
                        },
                        new
                        {
                            UserId = "msaspnet-core-user-hack-system000002",
                            RoleId = "msaspnet-core-role-hack-system000002"
                        },
                        new
                        {
                            UserId = "msaspnet-core-user-hack-system000003",
                            RoleId = "msaspnet-core-role-hack-system000001"
                        });
                });

            modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserToken<string>", b =>
                {
                    b.Property<string>("UserId")
                        .HasColumnType("TEXT");

                    b.Property<string>("LoginProvider")
                        .HasColumnType("TEXT");

                    b.Property<string>("Name")
                        .HasColumnType("TEXT");

                    b.Property<string>("Value")
                        .HasColumnType("TEXT");

                    b.HasKey("UserId", "LoginProvider", "Name");

                    b.ToTable("AspNetUserTokens", (string)null);
                });

            modelBuilder.Entity("HackSystem.WebAPI.MockServer.Domain.Entity.MockRouteLogDetail", b =>
                {
                    b.HasOne("HackSystem.WebAPI.MockServer.Domain.Entity.MockRouteDetail", null)
                        .WithMany()
                        .HasForeignKey("RouteID")
                        .OnDelete(DeleteBehavior.Cascade)
                        .IsRequired();
                });

            modelBuilder.Entity("HackSystem.WebAPI.ProgramServer.Domain.Entity.Maps.UserProgramMap", b =>
                {
                    b.HasOne("HackSystem.WebAPI.ProgramServer.Domain.Entity.Programs.ProgramDetail", "Program")
                        .WithMany("UserProgramMaps")
                        .HasForeignKey("ProgramId")
                        .OnDelete(DeleteBehavior.Cascade)
                        .IsRequired();

                    b.HasOne("HackSystem.WebAPI.ProgramServer.Domain.Entity.ProgramUser", "ProgramUser")
                        .WithMany("UserProgramMaps")
                        .HasForeignKey("UserId")
                        .OnDelete(DeleteBehavior.Cascade)
                        .IsRequired();

                    b.Navigation("Program");

                    b.Navigation("ProgramUser");
                });

            modelBuilder.Entity("HackSystem.WebAPI.ProgramServer.Domain.Entity.ProgramUser", b =>
                {
                    b.HasOne("HackSystem.WebAPI.Domain.Entity.Identity.HackSystemUser", null)
                        .WithOne()
                        .HasForeignKey("HackSystem.WebAPI.ProgramServer.Domain.Entity.ProgramUser", "Id")
                        .OnDelete(DeleteBehavior.Cascade)
                        .IsRequired();
                });

            modelBuilder.Entity("HackSystem.WebAPI.TaskServer.Domain.Entity.TaskLogDetail", b =>
                {
                    b.HasOne("HackSystem.WebAPI.TaskServer.Domain.Entity.TaskDetail", null)
                        .WithMany()
                        .HasForeignKey("TaskID")
                        .OnDelete(DeleteBehavior.Cascade)
                        .IsRequired();
                });

            modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityRoleClaim<string>", b =>
                {
                    b.HasOne("HackSystem.WebAPI.Domain.Entity.Identity.HackSystemRole", null)
                        .WithMany()
                        .HasForeignKey("RoleId")
                        .OnDelete(DeleteBehavior.Cascade)
                        .IsRequired();
                });

            modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserClaim<string>", b =>
                {
                    b.HasOne("HackSystem.WebAPI.Domain.Entity.Identity.HackSystemUser", null)
                        .WithMany()
                        .HasForeignKey("UserId")
                        .OnDelete(DeleteBehavior.Cascade)
                        .IsRequired();
                });

            modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserLogin<string>", b =>
                {
                    b.HasOne("HackSystem.WebAPI.Domain.Entity.Identity.HackSystemUser", null)
                        .WithMany()
                        .HasForeignKey("UserId")
                        .OnDelete(DeleteBehavior.Cascade)
                        .IsRequired();
                });

            modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserRole<string>", b =>
                {
                    b.HasOne("HackSystem.WebAPI.Domain.Entity.Identity.HackSystemRole", null)
                        .WithMany()
                        .HasForeignKey("RoleId")
                        .OnDelete(DeleteBehavior.Cascade)
                        .IsRequired();

                    b.HasOne("HackSystem.WebAPI.Domain.Entity.Identity.HackSystemUser", null)
                        .WithMany()
                        .HasForeignKey("UserId")
                        .OnDelete(DeleteBehavior.Cascade)
                        .IsRequired();
                });

            modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserToken<string>", b =>
                {
                    b.HasOne("HackSystem.WebAPI.Domain.Entity.Identity.HackSystemUser", null)
                        .WithMany()
                        .HasForeignKey("UserId")
                        .OnDelete(DeleteBehavior.Cascade)
                        .IsRequired();
                });

            modelBuilder.Entity("HackSystem.WebAPI.ProgramServer.Domain.Entity.Programs.ProgramDetail", b =>
                {
                    b.Navigation("UserProgramMaps");
                });

            modelBuilder.Entity("HackSystem.WebAPI.ProgramServer.Domain.Entity.ProgramUser", b =>
                {
                    b.Navigation("UserProgramMaps");
                });
#pragma warning restore 612, 618
        }
    }
}
