Updated migration
This commit is contained in:
		@@ -8,7 +8,7 @@ using NadekoBot.Services.Database.Impl;
 | 
			
		||||
namespace NadekoBot.Migrations
 | 
			
		||||
{
 | 
			
		||||
    [DbContext(typeof(NadekoSqliteContext))]
 | 
			
		||||
    [Migration("20160830011641_first")]
 | 
			
		||||
    [Migration("20160901001820_first")]
 | 
			
		||||
    partial class first
 | 
			
		||||
    {
 | 
			
		||||
        protected override void BuildTargetModel(ModelBuilder modelBuilder)
 | 
			
		||||
@@ -156,6 +156,30 @@ namespace NadekoBot.Migrations
 | 
			
		||||
                    b.ToTable("EightBallResponse");
 | 
			
		||||
                });
 | 
			
		||||
 | 
			
		||||
            modelBuilder.Entity("NadekoBot.Services.Database.Models.FollowedStream", b =>
 | 
			
		||||
                {
 | 
			
		||||
                    b.Property<int>("Id")
 | 
			
		||||
                        .ValueGeneratedOnAdd();
 | 
			
		||||
 | 
			
		||||
                    b.Property<ulong>("ChannelId");
 | 
			
		||||
 | 
			
		||||
                    b.Property<int?>("GuildConfigId");
 | 
			
		||||
 | 
			
		||||
                    b.Property<ulong>("GuildId");
 | 
			
		||||
 | 
			
		||||
                    b.Property<bool>("LastStatus");
 | 
			
		||||
 | 
			
		||||
                    b.Property<int>("Type");
 | 
			
		||||
 | 
			
		||||
                    b.Property<string>("Username");
 | 
			
		||||
 | 
			
		||||
                    b.HasKey("Id");
 | 
			
		||||
 | 
			
		||||
                    b.HasIndex("GuildConfigId");
 | 
			
		||||
 | 
			
		||||
                    b.ToTable("FollowedStream");
 | 
			
		||||
                });
 | 
			
		||||
 | 
			
		||||
            modelBuilder.Entity("NadekoBot.Services.Database.Models.GuildConfig", b =>
 | 
			
		||||
                {
 | 
			
		||||
                    b.Property<int>("Id")
 | 
			
		||||
@@ -195,6 +219,8 @@ namespace NadekoBot.Migrations
 | 
			
		||||
 | 
			
		||||
                    b.Property<bool>("SendDmGreetMessage");
 | 
			
		||||
 | 
			
		||||
                    b.Property<bool>("VoicePlusTextEnabled");
 | 
			
		||||
 | 
			
		||||
                    b.HasKey("Id");
 | 
			
		||||
 | 
			
		||||
                    b.HasIndex("GuildId")
 | 
			
		||||
@@ -360,6 +386,13 @@ namespace NadekoBot.Migrations
 | 
			
		||||
                        .HasForeignKey("BotConfigId");
 | 
			
		||||
                });
 | 
			
		||||
 | 
			
		||||
            modelBuilder.Entity("NadekoBot.Services.Database.Models.FollowedStream", b =>
 | 
			
		||||
                {
 | 
			
		||||
                    b.HasOne("NadekoBot.Services.Database.Models.GuildConfig")
 | 
			
		||||
                        .WithMany("FollowedStreams")
 | 
			
		||||
                        .HasForeignKey("GuildConfigId");
 | 
			
		||||
                });
 | 
			
		||||
 | 
			
		||||
            modelBuilder.Entity("NadekoBot.Services.Database.Models.ModulePrefix", b =>
 | 
			
		||||
                {
 | 
			
		||||
                    b.HasOne("NadekoBot.Services.Database.Models.BotConfig")
 | 
			
		||||
@@ -98,7 +98,8 @@ namespace NadekoBot.Migrations
 | 
			
		||||
                    GuildId = table.Column<ulong>(nullable: false),
 | 
			
		||||
                    SendChannelByeMessage = table.Column<bool>(nullable: false),
 | 
			
		||||
                    SendChannelGreetMessage = table.Column<bool>(nullable: false),
 | 
			
		||||
                    SendDmGreetMessage = table.Column<bool>(nullable: false)
 | 
			
		||||
                    SendDmGreetMessage = table.Column<bool>(nullable: false),
 | 
			
		||||
                    VoicePlusTextEnabled = table.Column<bool>(nullable: false)
 | 
			
		||||
                },
 | 
			
		||||
                constraints: table =>
 | 
			
		||||
                {
 | 
			
		||||
@@ -295,6 +296,30 @@ namespace NadekoBot.Migrations
 | 
			
		||||
                        onDelete: ReferentialAction.Cascade);
 | 
			
		||||
                });
 | 
			
		||||
 | 
			
		||||
            migrationBuilder.CreateTable(
 | 
			
		||||
                name: "FollowedStream",
 | 
			
		||||
                columns: table => new
 | 
			
		||||
                {
 | 
			
		||||
                    Id = table.Column<int>(nullable: false)
 | 
			
		||||
                        .Annotation("Autoincrement", true),
 | 
			
		||||
                    ChannelId = table.Column<ulong>(nullable: false),
 | 
			
		||||
                    GuildConfigId = table.Column<int>(nullable: true),
 | 
			
		||||
                    GuildId = table.Column<ulong>(nullable: false),
 | 
			
		||||
                    LastStatus = table.Column<bool>(nullable: false),
 | 
			
		||||
                    Type = table.Column<int>(nullable: false),
 | 
			
		||||
                    Username = table.Column<string>(nullable: true)
 | 
			
		||||
                },
 | 
			
		||||
                constraints: table =>
 | 
			
		||||
                {
 | 
			
		||||
                    table.PrimaryKey("PK_FollowedStream", x => x.Id);
 | 
			
		||||
                    table.ForeignKey(
 | 
			
		||||
                        name: "FK_FollowedStream_GuildConfigs_GuildConfigId",
 | 
			
		||||
                        column: x => x.GuildConfigId,
 | 
			
		||||
                        principalTable: "GuildConfigs",
 | 
			
		||||
                        principalColumn: "Id",
 | 
			
		||||
                        onDelete: ReferentialAction.Restrict);
 | 
			
		||||
                });
 | 
			
		||||
 | 
			
		||||
            migrationBuilder.CreateIndex(
 | 
			
		||||
                name: "IX_BlacklistItem_BotConfigId",
 | 
			
		||||
                table: "BlacklistItem",
 | 
			
		||||
@@ -322,6 +347,11 @@ namespace NadekoBot.Migrations
 | 
			
		||||
                table: "EightBallResponse",
 | 
			
		||||
                column: "BotConfigId");
 | 
			
		||||
 | 
			
		||||
            migrationBuilder.CreateIndex(
 | 
			
		||||
                name: "IX_FollowedStream_GuildConfigId",
 | 
			
		||||
                table: "FollowedStream",
 | 
			
		||||
                column: "GuildConfigId");
 | 
			
		||||
 | 
			
		||||
            migrationBuilder.CreateIndex(
 | 
			
		||||
                name: "IX_GuildConfigs_GuildId",
 | 
			
		||||
                table: "GuildConfigs",
 | 
			
		||||
@@ -374,7 +404,7 @@ namespace NadekoBot.Migrations
 | 
			
		||||
                name: "EightBallResponse");
 | 
			
		||||
 | 
			
		||||
            migrationBuilder.DropTable(
 | 
			
		||||
                name: "GuildConfigs");
 | 
			
		||||
                name: "FollowedStream");
 | 
			
		||||
 | 
			
		||||
            migrationBuilder.DropTable(
 | 
			
		||||
                name: "ModulePrefix");
 | 
			
		||||
@@ -400,6 +430,9 @@ namespace NadekoBot.Migrations
 | 
			
		||||
            migrationBuilder.DropTable(
 | 
			
		||||
                name: "ClashOfClans");
 | 
			
		||||
 | 
			
		||||
            migrationBuilder.DropTable(
 | 
			
		||||
                name: "GuildConfigs");
 | 
			
		||||
 | 
			
		||||
            migrationBuilder.DropTable(
 | 
			
		||||
                name: "BotConfig");
 | 
			
		||||
        }
 | 
			
		||||
@@ -155,6 +155,30 @@ namespace NadekoBot.Migrations
 | 
			
		||||
                    b.ToTable("EightBallResponse");
 | 
			
		||||
                });
 | 
			
		||||
 | 
			
		||||
            modelBuilder.Entity("NadekoBot.Services.Database.Models.FollowedStream", b =>
 | 
			
		||||
                {
 | 
			
		||||
                    b.Property<int>("Id")
 | 
			
		||||
                        .ValueGeneratedOnAdd();
 | 
			
		||||
 | 
			
		||||
                    b.Property<ulong>("ChannelId");
 | 
			
		||||
 | 
			
		||||
                    b.Property<int?>("GuildConfigId");
 | 
			
		||||
 | 
			
		||||
                    b.Property<ulong>("GuildId");
 | 
			
		||||
 | 
			
		||||
                    b.Property<bool>("LastStatus");
 | 
			
		||||
 | 
			
		||||
                    b.Property<int>("Type");
 | 
			
		||||
 | 
			
		||||
                    b.Property<string>("Username");
 | 
			
		||||
 | 
			
		||||
                    b.HasKey("Id");
 | 
			
		||||
 | 
			
		||||
                    b.HasIndex("GuildConfigId");
 | 
			
		||||
 | 
			
		||||
                    b.ToTable("FollowedStream");
 | 
			
		||||
                });
 | 
			
		||||
 | 
			
		||||
            modelBuilder.Entity("NadekoBot.Services.Database.Models.GuildConfig", b =>
 | 
			
		||||
                {
 | 
			
		||||
                    b.Property<int>("Id")
 | 
			
		||||
@@ -194,6 +218,8 @@ namespace NadekoBot.Migrations
 | 
			
		||||
 | 
			
		||||
                    b.Property<bool>("SendDmGreetMessage");
 | 
			
		||||
 | 
			
		||||
                    b.Property<bool>("VoicePlusTextEnabled");
 | 
			
		||||
 | 
			
		||||
                    b.HasKey("Id");
 | 
			
		||||
 | 
			
		||||
                    b.HasIndex("GuildId")
 | 
			
		||||
@@ -359,6 +385,13 @@ namespace NadekoBot.Migrations
 | 
			
		||||
                        .HasForeignKey("BotConfigId");
 | 
			
		||||
                });
 | 
			
		||||
 | 
			
		||||
            modelBuilder.Entity("NadekoBot.Services.Database.Models.FollowedStream", b =>
 | 
			
		||||
                {
 | 
			
		||||
                    b.HasOne("NadekoBot.Services.Database.Models.GuildConfig")
 | 
			
		||||
                        .WithMany("FollowedStreams")
 | 
			
		||||
                        .HasForeignKey("GuildConfigId");
 | 
			
		||||
                });
 | 
			
		||||
 | 
			
		||||
            modelBuilder.Entity("NadekoBot.Services.Database.Models.ModulePrefix", b =>
 | 
			
		||||
                {
 | 
			
		||||
                    b.HasOne("NadekoBot.Services.Database.Models.BotConfig")
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user